[FieldTrip] gradiometer definitions after ft_megplanar
Eelke Spaak
eelke.spaak at donders.ru.nl
Mon Dec 9 09:16:11 CET 2013
Hi Ana,
Are you by any chance doing ICA followed by ft_rejectcomponent at some
point before ft_megplanar? After rejecting a component, grad.chanpos
and grad.chanori will contain only NaNs (as of some months ago
indeed), as the channel positions are ill-defined at that point (i.e.
each 'data'-channel is in fact a weighted mixture of the original,
physical, MEG channels). Since ft_megplanar needs the channel
positions, it can no longer operate on data after ft_rejectcomponent.
However, there is an easy workaround: the original channel positions
should quite nicely approximate the positions after
ft_rejectcomponent. So, what I do is simply store the original
data.grad somewhere, and then make sure to stick in the data just
before ft_megplanar.
Note that the reason why ft_rejectcomponent updates the grad is that
creating an accurate forward model (for source reconstruction)
requires accurate sensor information. Therefore it fills grad.chanpos
with NaNs, while updating grad.coilpos etc. to reflect the new
projection. So you should *not* use the original grad for source
analysis after ft_rejectcomponent, in that case just use the updated
one with the NaNs inside.
Best,
Eelke
On 8 December 2013 22:44, Todorovic, A. <a.todorovic at fcdonders.ru.nl> wrote:
> Dear 'trippers,
>
> I am attempting to do a TFR on planar gradient data. I first preprocess, then do ft_megplanar, then ft_freqanalysis, followed by ft_combineplanar. However, upon doing ft_megplanar, the grad.chanori field consists only of NaNs. I see that some changes were made a few months ago on how gradiometers are described, so I am wondering whether there are some changes I should now make to the cfg structure when doing the planar gradient transformation.
>
> This is how I normally do it:
>
> cfg = [];
> cfg.planarmethod = 'sincos';
> cfg.channel = {'MEG'};
> cfg.trials = 'all';
> cfg.neighbours = neighbours; % neighbours=ft_prepare_neighbours(cfg,data)
> data_planar = ft_megplanar(cfg,data);
>
>
> Alternatively, is there some workaround I could now implement to fix my already calculated TFR structures?
>
>
> Cheers,
> Ana
> _______________________________________________
> fieldtrip mailing list
> fieldtrip at donders.ru.nl
> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip
More information about the fieldtrip
mailing list