[FieldTrip] Question on Cluster-based permutation tests on time-frequency data

Nithin Krishna nkrishna at mprc.umaryland.edu
Wed Apr 2 18:28:08 CEST 2014


Thanks a lot Joram,
Actually this helps a lot and the layout does have my system.
Cheers
Nithin

>>> Joram van Driel <joramvandriel at gmail.com> 4/2/2014 11:25 AM >>>

Dear Nithin,


I use Fieldtrip's permutation testing routines quite often on non-fieldtrip analyzed data. It is quite straightforward as long as you have your channel/neighbour layout the way Fieldtrip needs it. Try playing around with the ft_read_sens([EEG file with readable channel locations]), or simply choose a layout file from the folder /template/layout/ inside your fieldtrip folder; from this you need to use ft_prepare_neighbours; or more simple, choose a predefined neighbour structure from /template/neighbours. This covers quite a lot of systems; of course yours may not be in there; then I think ft_read_sens is your only option. I use EEGLAB for example, and I could import a .set file with a field EEG.chanlocs using ft_read_sens.


Then, I do the following for time-frequency data (but in principle this should be very similar for time-domain ERP data):


- I first configure the cfg as described in the cluster permutation testing tutorial
- Then I manually put my own analyzed data into a "freqs" structure; name is of course arbitrary, but should have the same fields as the output from ft_freqanalysis:


freq1.freq = [the values of the different frequencies];
freq1.time = [the different time points];
freq1.dimord = 'subj_chan_freq_time';
freq1.grad = [the result from ft_read_sense];
freq1.label = [the labels from the result of ft_read_sense];
freq1.powspctrm = [the result of your own custom/EEGLAB/whatever non-fieldtrip analysis, provided this has the dimensions of freqs.dimord];


Then I do this for example for two different conditions, make my design matrix in cfg.design, and put it into ft_freqstatistics(cfg,freq1,freq2)


Hope this helps.
- Joram





On Wed, Apr 2, 2014 at 4:39 PM, Lam, Nietzsche <n.lam at fcdonders.ru.nl> wrote:

Dear Nithin,

FieldTrip was primarily set up for MEG data but we definitely have several tutorials discussing similar procedures for EEG data.  Perhaps these tutorials can help you out.

http://fieldtrip.fcdonders.nl/tutorial/eeg_preprocessing_erp

http://fieldtrip.fcdonders.nl/tutorial/cluster_permutation_timelock
http://fieldtrip.fcdonders.nl/tutorial/eventrelatedstatistics
Although these later two links are performed on MEG data, I think they are useful to you because functions used to calculate ERFs are also used for ERPs. For example, in FieldTrip you can use ft_timelockanalysis and ft_timelockstatistics for both EEG and MEG data.

Regarding the use of non-FieldTrip data for cluster-permutations. Theoretically, I think it is possible, but probably more experienced users can answer this. Nevertheless, you could look into this FAQ about how to import your data so that it ca be used by FieldTrip here:
http://fieldtrip.fcdonders.nl/faq/how_can_i_import_my_own_dataformat?s[]=import&s[]=data

best,
Nietzsche



----- Original Message -----
> From: "Nithin Krishna" <nkrishna at mprc.umaryland.edu>
> To: "FieldTrip discussion list" <fieldtrip at science.ru.nl>
> Sent: Wednesday, 2 April, 2014 4:23:01 PM
> Subject: [FieldTrip] Question on Cluster-based permutation tests on time-frequency data
> Dear All,
> I read the tutorial section on Cluster-based permutation tests on
> time-frequency data as well as the Maris and Oostenveld, Journal of
> Neuroscience Methods, 2007 report. I am interested in setting up a ERP
> experiment on EEG data in this regard I like the procedure and
> processing section of the tutorial, however I would like to know if
> there is any section for EEG, I understand that megplanar is specific
> for MEG.
> Also is it possible to use 3D matrix (TFR) (time, Freq channels ) non
> feild trip output to run the cluster based permutation tests.
> Looking forward
> Nithin
>
>
> >>> "Jörn M. Horschig"<jm.horschig at donders.ru.nl> 4/2/2014 6:39 AM >>>
>
> Hi Marco,
>
> could you be more specific, in the style of e.g.
> http://fieldtrip.fcdonders.nl/faq/how_to_ask_good_questions_to_the_community#how_to_ask_a_questio
> ?
>
> Best,
> Jörn
>
> On 4/2/2014 12:31 PM, Marco Rotonda wrote:
> > Hi all,
> > I would like to compute a simple alpha-theta ratio and do some
> > statistics on it.
> > I had my data from freqanalysis.
> > Then I averaged with selectdata_new to have the mean for a band.
> > Then the simple ratio for each channel.
> > If now I call freqstatistics I have an error.
> > Any suggestion?
> >
> > Thanks
> >
> > Marco
> >
> >
> > _______________________________________________
> > fieldtrip mailing list
> > fieldtrip at donders.ru.nl
> > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip
>
>
> --
> Jörn M. Horschig
> PhD Student
> Donders Institute for Brain, Cognition and Behaviour
> Centre for Cognitive Neuroimaging
> Radboud University Nijmegen
> Neuronal Oscillations Group
> FieldTrip Development Team
>
> P.O. Box 9101
> NL-6500 HB Nijmegen
> The Netherlands
>
> Contact:
> E-Mail: jm.horschig at donders.ru.nl
> Tel: +31-(0)24-36-68493
> Web: http://www.ru.nl/donders
>
> Visiting address:
> Trigon, room 2.30
> Kapittelweg 29
> NL-6525 EN Nijmegen
> The Netherlands
>
> _______________________________________________
> fieldtrip mailing list
> fieldtrip at donders.ru.nl
> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip
>
> _______________________________________________
> fieldtrip mailing list
> fieldtrip at donders.ru.nl
> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip

--
Nietzsche H.L. Lam, MSc
PhD Candidate

Max Planck Institute for Psycholinguistics
Wundtlaan 1, 6525 XD Nijmegen, The Netherlands

Donders Institute for Brain, Cognition and Behaviour,
Centre for Cognitive Neuroimaging,
Kapittelweg 29, 6525EN Nijmegen, The Netherlands

n.lam at fcdonders.ru.nl
+31-24-3668219


neurobiologyoflanguage.com

_______________________________________________
fieldtrip mailing list
fieldtrip at donders.ru.nl
http://mailman.science.ru.nl/mailman/listinfo/fieldtrip





-- 

Joram van Driel, MSc.
PhD student @ University of Amsterdam
Brain & Cognition @ Department of Psychology
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20140402/a0d56cf7/attachment-0001.html>


More information about the fieldtrip mailing list