<html><head><style>body{font-family:Helvetica,Arial;font-size:13px}</style></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;"><div id="bloop_customfont" style="font-family:Helvetica,Arial;font-size:13px; color: rgba(0,0,0,1.0); margin: 0px; line-height: auto;">Dear Fieldtrippers,</div><div id="bloop_customfont" style="font-family:Helvetica,Arial;font-size:13px; color: rgba(0,0,0,1.0); margin: 0px; line-height: auto;"><br></div><div id="bloop_customfont" style="font-family:Helvetica,Arial;font-size:13px; color: rgba(0,0,0,1.0); margin: 0px; line-height: auto;">tl;dr</div><div id="bloop_customfont" style="font-family:Helvetica,Arial;font-size:13px; color: rgba(0,0,0,1.0); margin: 0px; line-height: auto;">1. I'm looking for a gradiometer structure that includes coils (so a subject or dummy measurement) with *all* squids present. </div><div id="bloop_customfont" style="font-family:Helvetica,Arial;font-size:13px; color: rgba(0,0,0,1.0); margin: 0px; line-height: auto;">2. Can I rename the CTF HLC0011 etc... to {'nasX';'nasY';'nasZ';'lpaX';'lpaY';'lpaZ';'rpaX';'rpaY';'rpaZ'}?</div><div id="bloop_customfont" style="font-family:Helvetica,Arial;font-size:13px; color: rgba(0,0,0,1.0); margin: 0px; line-height: auto;"><br></div><div id="bloop_customfont" style="font-family:Helvetica,Arial;font-size:13px; color: rgba(0,0,0,1.0); margin: 0px; line-height: auto;">---------</div><div id="bloop_customfont" style="font-family:Helvetica,Arial;font-size:13px; color: rgba(0,0,0,1.0); margin: 0px; line-height: auto;"><br></div><div id="bloop_customfont" style="font-family:Helvetica,Arial;font-size:13px; color: rgba(0,0,0,1.0); margin: 0px; line-height: auto;">First, I'm using ft_megrealign after timelocking my data for each participant and recording, and before appending these different recording sessions (and subsequently taking grand averages over subjects). Since the experiment consisted of different sessions a few weeks apart, I'd like to minimise noise due to differences in head position (we used online head localisation, but this did not work very well for all participants when coming back a few weeks later. </div><div id="bloop_customfont" style="font-family:Helvetica,Arial;font-size:13px; color: rgba(0,0,0,1.0); margin: 0px; line-height: auto;"><br></div><div id="bloop_customfont" style="font-family:Helvetica,Arial;font-size:13px; color: rgba(0,0,0,1.0); margin: 0px; line-height: auto;">After making the headmodel (and ensuring it's aligned with the gradiometers), this works quite well:</div><div id="bloop_customfont" style="font-family:Helvetica,Arial;font-size:13px; color: rgba(0,0,0,1.0); margin: 0px; line-height: auto;"><br></div><div id="bloop_customfont" style="font-family:Helvetica,Arial;font-size:13px; color: rgba(0,0,0,1.0); margin: 0px; line-height: auto;">
<p style="margin: 0px; font-size: 10px; line-height: normal; font-family: Courier; color: rgb(37, 153, 45);">% realign to template sensor positions</p><p style="margin: 0px; font-size: 10px; line-height: normal; font-family: Courier;">cfg             = [];</p><p style="margin: 0px; font-size: 10px; line-height: normal; font-family: Courier; color: rgb(37, 153, 45);"><span style="color: #000000">cfg.template    = {</span><span style="color: #b245f3">'ctf275.mat'</span><span style="color: #000000">}; </span></p><p style="margin: 0px; font-size: 10px; line-height: normal; font-family: Courier;">cfg.headmodel   = headmodel;</p><p style="margin: 0px; font-size: 10px; line-height: normal; font-family: Courier; min-height: 12px;"> </p><p style="margin: 0px; font-size: 10px; line-height: normal; font-family: Courier; color: rgb(37, 153, 45);">% For a realistic single-shell volume conduction model based on the brain surface, you</p><p style="margin: 0px; font-size: 10px; line-height: normal; font-family: Courier; color: rgb(37, 153, 45);">% should probably use an inward shift of about 1 cm.</p><p style="margin: 0px; font-size: 10px; line-height: normal; font-family: Courier;">cfg.inwardshift  = 1;</p><p style="margin: 0px; font-size: 10px; line-height: normal; font-family: Courier;">cfg.feedback     = <span style="color: #b245f3">'no'</span>;</p><p style="margin: 0px; font-size: 12px; line-height: normal; font-family: Courier; min-height: 14px;"><span style="font-size: 10px;">data2</span><span style="font-size: 10px;">            </span><span style="font-size: 10px;">= ft_megrealign(cfg, data);</span></p><div><br></div></div>However, I don't have a perfect template for a full grad structure (including coils) to use in this step. The file 'ctf275.mat' I'm using now comes from <a href="ftp://ftp.fieldtriptoolbox.org/pub/fieldtrip/example/megrealign">ftp://ftp.fieldtriptoolbox.org/pub/fieldtrip/example/megrealign</a>, but misses the MLT37 squid. I have several squids missing in my own data as well (and worse, different sensors missing between different subjects), which is another reason I'd like to use ft_megrealign.<div><br></div><div>So, my question is whether anyone has a full gradiometer structure, with all squids and coils present, that they're willing to share as a template? I can get the channel information from ft_fetch_sens based on the CTF275 layout, but that has no information about the coils.</div><div><br></div><div>Second, when looking into the ft_megrealign function I found that there is the option of doing this per trial based on the CTF coil positions (rather than once based on the gradiometer definition at the beginning of the run). This seems sensible for participants who moved quite a bit during a recording. However, CTF does not originally output the {'nasX';'nasY';'nasZ';'lpaX';'lpaY';'lpaZ';'rpaX';'rpaY';'rpaZ'} that the function looks for. </div><div><br></div><div>In ft_headmovement (and also buried somewhere in the CTF documentation), I could find</div><div><div>% HLC0011 HLC0012 HLC0013 x, y, z coordinates of nasion-coil in m.</div><div>% HLC0021 HLC0022 HLC0023 x, y, z coordinates of lpa-coil in m.</div><div>% HLC0031 HLC0032 HLC0033 x, y, z coordinates of rpa-coil in m.</div></div><div><br></div><div>So it seems reasonable to simply rename these to the channel names that ft_megrealign is looking for. When doing this, realignment indeed happens at the single trial level. However, I wanted to check if there is a reason for using the nasX nasY... channel names rather than the original HLC0011.. ones? Can I rename them while keeping the rest of the HLC channels (of which there are 24) the same? I can't think of a reason why this would cause any issues, but since I could not find the 'per-trial' option documented I thought I'd check what the rationale behind using per-trial or per-run is. </div><div><br></div><div>Thanks!</div><div><br><div id="bloop_sign_1461132020306371072" class="bloop_sign"><div style="font-family:helvetica,arial;font-size:13px"><div>— </div><div><span style="font-family: 'helvetica Neue', helvetica;">Anne E. Urai, MSc</span></div><div><span style="font-family: 'helvetica Neue', helvetica;">PhD student | Institut für Neurophysiologie und Pathophysiologie </span></div><div><span style="font-family: 'helvetica Neue', helvetica;">Universitätsklinikum Hamburg-Eppendorf | </span><span style="font-family: 'helvetica Neue', helvetica;">Martinistrasse 52, 20246 | Hamburg, Germany </span></div><div><span style="font-family: 'helvetica Neue', helvetica;"><a href="http://www.anneurai.net">www.anneurai.net</a> / </span><a href="https://twitter.com/AnneEUrai"><span style="font-family: 'helvetica Neue', helvetica;">@AnneEUrai</span></a></div></div></div></div></body></html>