<html><head><style type='text/css'>p { margin: 0; }</style></head><body><div style='font-family: Times New Roman; font-size: 12pt; color: #000000'><div>Hi all,</div><div><br></div>A follow-up question on the implementation of 3rd-order gradiometer correction in FT: <div><br></div><div>I am puzzling how one can do both 3-order grad. correction and dft-filtering properly using FT. the logical sequency would be to do ft_denoise_synthetic first, and subsequently dft-filtering using ft_preprocessing. However, in that case it is no longer possible to pad the data when calling ft_preprocessing, because it now processes trial-data (output from ft_denoise_synthetic), and doesn't read in the original dataset anymore. or am I mistaken here?</div><div><br></div><div>I could see 3 alternatives, which seem to be more like (computationally) suboptimal workarounds:</div><div>- Apply ft_denoise_synthetic on the entire dataset, then dft-filter the entire dataset, and then run ft_redefinetrial to cut the data into actual trials</div><div>- Adjust the trial definition such that longer data segments are read in, equivalent to your padding size. Then apply ft_denoise_synthetic on these trials, then dft-filter them, and then run ft_redefinetrial to cut the data into actual trials</div><div>- Doing the 3-rd order grad. correction first using the DataEditor, and then process it further using FT.</div><div><br></div><div>Any thoughts?</div><div><br></div><div>Best, Stan</div><div><br></div><div><br><hr id="zwchr"><blockquote style="border-left:2px solid rgb(16, 16, 255);margin-left:5px;padding-left:5px;"><b>Van: </b>"Michael Wibral" <michael.wibral@web.de><br><b>Aan: </b>"Email discussion list for the FieldTrip project" <fieldtrip@donders.ru.nl><br><b>Verzonden: </b>Donderdag 19 april 2012 10:24:57<br><b>Onderwerp: </b>Re: [FieldTrip] ft_denoise_synthetic 3rd order grad<br><br><div style="font-family: Verdana;font-size: 12.0px;"><div>Hey there,<br></div><div><br></div><div>sorry for not thinking about it any earlier, indeed I can confirm that ft_denoise.. needs the reference channels to function properly. I remember having to preprocess in a funny order in old ft versions, to do artefcat rejection without the refs and denoising with the refs.
<br></div><div><br></div><div>Personally, I think the code should check whether the refs are there and otherwise throw an error. Since ft_denoise.. only concerns CTF (and bti??) systems, where the refs have fixed names this could be easily implemented, or am I mistaken?<br></div><div><br></div><div>Best,<br></div><div>Michael<br></div><div style="margin:10px 5px 5px 10px; padding: 10px 0 10px 10px; border-left:2px solid #C3D9E5; word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;">
<div style="margin:0 0 10px 0;">
<b>Gesendet:</b> Donnerstag, 19. April 2012 um 08:59 Uhr<br>
<b>Von:</b> "Barbara Haendel" <B.Haendel@gmx.net><br>
<b>An:</b> "Email discussion list for the FieldTrip project" <fieldtrip@donders.ru.nl>, fieldtrip@donders.ru.nl<br>
<b>Betreff:</b> Re: [FieldTrip] ft_denoise_synthetic 3rd order grad
</div>
<div>
<br>
<br>
Hey there, thanks a lot for the replies!<br>
<br>
Panagiotis hit the mark. Indeed the reference channels were excluded in the first round of preprocessing. May be one could include a short note on that in the ft_denoise m-file description since only including relevant channels is the normal way to treat data in preprocessing. <br>
<br>
Thanks again,<br>
Barbara<br>
<br>
<br>
<br>
<br>
-------- Original-Nachricht --------<br>
> Datum: Mon, 16 Apr 2012 17:53:56 +0200<br>
> Von: Panagiotis Tsiatsis <Panagiotis.Tsiatsis@Tuebingen.MPG.de><br>
> An: Email discussion list for the FieldTrip project <fieldtrip@donders.ru.nl><br>
> Betreff: Re: [FieldTrip] ft_denoise_synthetic 3rd order grad<br>
<br>
> Hello girls and guys,<br>
> <br>
> It is working for my CTF MEG data - the version that I have is v4692 <br>
> 2011-11-07.<br>
> <br>
> The other thing that might cause a problem could be ommiting the <br>
> reference channels definition before the ft_ preprocessing command that <br>
> gave you your "dataprepro"<br>
> <br>
> i.e maybe you might need something like this<br>
> <br>
> cfg = [];<br>
> <br>
> ...<br>
> //various preprocessing parameters<br>
> ...<br>
> <br>
> cfg.channel = {'MEG', 'MEGREF', 'REFGRAD' , 'REFMAG'};<br>
> <br>
> dataprepro = ft_preprocessing(cfg);<br>
> <br>
> <br>
> Hope you are lucky :)<br>
> <br>
> Best,<br>
> Panagiotis<br>
> <br>
> <br>
> On 4/16/2012 4:59 PM, Stan van Pelt wrote:<br>
> > Hi Barbara,<br>
> ><br>
> > I can replicate your finding, but am unsure what is causing it. Maybe <br>
> > the difference/correction is lower than the Matlab or CTF precision? <br>
> > In any case, if the 3rd order gradients were on, ft_denoise_synthetic <br>
> > would undo the G3BR-balancing, ergo it toggles.<br>
> ><br>
> > Best,<br>
> > Stan<br>
> ><br>
> ><br>
> > ------------------------------------------------------------------------<br>
> ><br>
> > *Van: *"Michael Wibral" <michael.wibral@web.de><br>
> > *Aan: *"Email discussion list for the FieldTrip project"<br>
> > <fieldtrip@donders.ru.nl><br>
> > *Verzonden: *Maandag 16 april 2012 16:46:27<br>
> > *Onderwerp: *Re: [FieldTrip] ft_denoise_synthetic 3rd order grad<br>
> ><br>
> > Hi Barbara,<br>
> ><br>
> > are you certain that the original data do not have 3rd gradients<br>
> > enabled? - looking at them once in dataEditor, switching to 3rd<br>
> > grads and accidentally forgetting to unclick 'save parameters with<br>
> > dataset' will make them have 3rd grads...<br>
> ><br>
> > When I last used ft_denoise_synthetic it worked pretty much as<br>
> > described (??).<br>
> ><br>
> > Michael<br>
> ><br>
> > *Gesendet:* Montag, 16. April 2012 um 15:56 Uhr<br>
> > *Von:* "Barbara Haendel" <B.Haendel@gmx.net><br>
> > *An:* fieldtrip@donders.ru.nl<br>
> > *Betreff:* [FieldTrip] ft_denoise_synthetic 3rd order grad<br>
> ><br>
> > Dear fieldtrip users,<br>
> ><br>
> > has anyone experience in using ft_denoise_synthetic? If I try to<br>
> > calculate 3rd order grads in the below specified way the data does<br>
> > not change with respect to the input data (which has no synthetic<br>
> > gradiometer applied). Is there some obvious misunderstanding on my<br>
> > side of how to use this function or is our environment truly<br>
> > noiseless :)<br>
> ><br>
> > Cheers,<br>
> > Barbara<br>
> ><br>
> > cfg=[];<br>
> > cfg.gradient ='G3BR';<br>
> > cfg.trials = 'all';<br>
> > data_3rdorder = ft_denoise_synthetic(cfg, dataprepro);<br>
> ><br>
> ><br>
> > >> data_3rdorder.grad.balance<br>
> ><br>
> > ans =<br>
> ><br>
> > G1BR: [1x1 struct]<br>
> > G2BR: [1x1 struct]<br>
> > G3BR: [1x1 struct]<br>
> > current: 'G3BR'<br>
> > previous: {'none'}<br>
> ><br>
> > >> sum(dataprepro.trial{8}(30,:)-data_3rdorder.trial{8}(30,:))<br>
> ><br>
> > ans = 0<br>
> ><br>
> > -- <br>
> > NEU: FreePhone 3-fach-Flat mit kostenlosem Smartphone!<br>
> > Jetzt informieren:<br>
> <a href="http://mobile.1und1.de/?ac=OM.PW.PW003K20328T7073a" target="_blank">http://mobile.1und1.de/?ac=OM.PW.PW003K20328T7073a</a><br>
> > _______________________________________________<br>
> > fieldtrip mailing list<br>
> > fieldtrip@donders.ru.nl<br>
> > <a href="http://mailman.science.ru.nl/mailman/listinfo/fieldtrip" target="_blank">http://mailman.science.ru.nl/mailman/listinfo/fieldtrip</a><br>
> ><br>
> ><br>
> > _______________________________________________<br>
> > fieldtrip mailing list<br>
> > fieldtrip@donders.ru.nl<br>
> > <a href="http://mailman.science.ru.nl/mailman/listinfo/fieldtrip" target="_blank">http://mailman.science.ru.nl/mailman/listinfo/fieldtrip</a><br>
> ><br>
> ><br>
> ><br>
> ><br>
> > -- <br>
> > Stan van Pelt<br>
> ><br>
> > Donders Institute for Brain, Cognition and Behaviour, Radboud <br>
> > University Nijmegen<br>
> > Kapittelweg 29, 6525 EN Nijmegen, Netherlands<br>
> > E-mail: stan.vanpelt@donders.ru.nl<br>
> > Website: <a href="http://www.ru.nl/donders/" target="_blank">www.ru.nl/donders/</a><br>
> > Phone: (+31) (0)24 36 10981<br>
> > Fax: (+31) (0)24 36 10989<br>
> ><br>
> ><br>
> > _______________________________________________<br>
> > fieldtrip mailing list<br>
> > fieldtrip@donders.ru.nl<br>
> > <a href="http://mailman.science.ru.nl/mailman/listinfo/fieldtrip" target="_blank">http://mailman.science.ru.nl/mailman/listinfo/fieldtrip</a><br>
> <br>
> <br>
> -- <br>
> Panagiotis S. Tsiatsis<br>
> Max Planck Institute for Biological Cybernetics<br>
> Cognitive NeuroImaging Group<br>
> Tuebingen, Germany<br>
> <br>
<br>
-- <br>
NEU: FreePhone 3-fach-Flat mit kostenlosem Smartphone! <br>
Jetzt informieren: <a href="http://mobile.1und1.de/?ac=OM.PW.PW003K20328T7073a" target="_blank">http://mobile.1und1.de/?ac=OM.PW.PW003K20328T7073a</a><br>
_______________________________________________<br>
fieldtrip mailing list<br>
fieldtrip@donders.ru.nl<br>
<a href="http://mailman.science.ru.nl/mailman/listinfo/fieldtrip" target="_blank">http://mailman.science.ru.nl/mailman/listinfo/fieldtrip</a><br>
</div>
</div><div><br><br></div></div>
<br>_______________________________________________<br>fieldtrip mailing list<br>fieldtrip@donders.ru.nl<br>http://mailman.science.ru.nl/mailman/listinfo/fieldtrip</blockquote><br><br><br>-- <br><div><span name="x"></span>Stan van Pelt<br><br>Donders Institute for Brain, Cognition and Behaviour, Radboud University Nijmegen<br>Kapittelweg 29, 6525 EN Nijmegen, Netherlands<br>E-mail: stan.vanpelt@donders.ru.nl<br>Website: www.ru.nl/donders/<br>Phone: (+31) (0)24 36 10981<br>Fax: (+31) (0)24 36 10989<span name="x"></span><br></div></div></div></body></html>