From tineke.snijders at donders.ru.nl Fri Apr 1 12:03:30 2016 From: tineke.snijders at donders.ru.nl (Snijders, T.M. (Tineke)) Date: Fri, 1 Apr 2016 10:03:30 +0000 Subject: [FieldTrip] Question about coherence statistics In-Reply-To: References: <2595287eebb0aeacfe5761a9de10de24@inserm.fr> <68a5ba763224075e6d9ec9aa7684221a@inserm.fr>, <815A9820E75FBC4F96B7CD3A8089D11C378AE3E0@exprd04.hosting.ru.nl>, Message-ID: <815A9820E75FBC4F96B7CD3A8089D11C378AE4DA@exprd04.hosting.ru.nl> Hi Laetitia, Indeed, as 'coh' doesn't have the trial information anymore after ft_connectivityanalysis, you can't use it as input for ft_freqstatistics if you only have one subject. Indeed, giving 'cohspctrm' as parameter with your freq data doesn't work as 'cohspctrm' is not in your freq data. The cfg.parameter specifies what data to use for the randomization, so that parameter should be in the data you give as input. You can use the freq data as input for freq_statistics, but then you have to change your cfg.statistic. This is the statistical function that is called after shuffling your trials - in your case after shuffling your trials the coherence has to be computed and the difference between conditions calculated. As far as I know, if you set your cfg.statistic to 'diff_itc', it will compute the difference in the inter-trial coherence between two conditions (looking at the phase consistency over trials). Best, Tineke ________________________________ From: laetitia.lalla at inserm.fr [laetitia.lalla at inserm.fr] Sent: Thursday, March 31, 2016 3:22 PM To: FieldTrip discussion list Cc: Snijders, T.M. (Tineke) Subject: Re: [FieldTrip] Question about coherence statistics Dear Tineke, thank you very much for your fast answer ! I'm not sure I understand what you mean though... Maybe i did not express myself correctly. I do have individual trial data : I have 26 observations for condition 1 and 26 observations for condition 2. They appear : - In my structure "data" (output of ft_preprocessing) : data.trial is a cell {1 x nbtrials} (in my case : {1, 26}) - in my structure "freq" (output of ft_freqanalysis) : freq.powspctrm is a matrix of dimension : nbtrials X nbchannel X nbfreq (in my case 26x2x25) But I don't have this information anymore in the structure "coh" (output of ft_connectivityanalysis) : coh.cospctrm is a matrix of dimension nbchannelcmb x nbfreq (in my case 1x25) since the coherence is calculated by averaging over trials... You may mean I should give the "freq" structures as inputs to the fonction ft_freqstatistics ? I just tried that : I created a structure data_all by concatenated data1.trial and data2.trial (and every other appropriate attribute). I took the Time Frequency Representation with ft_freqanalysis (with keeptrials='yes') to obtain a structure TFR_all (following this tutorial : http://www.fieldtriptoolbox.org/tutorial/natmeg/statistics This is actually how I did the statistics for the Power). But then, if I give this as an input to ft_freqstatistics, like this : cfg = []; cfg.statistic = 'diff'; cfg.parameter='cohspctrm'; cfg.design= [ones(1,nbtrial)) 2*ones(1, nbtrial))]; %same nb of trials for both condition cfg.method = 'montecarlo'; cfg.numrandomization = 1000; cfg.ivar = 1; cfg.alpha=0.05; cfg.tail=0; cfg.correcttail='alpha'; >> stat=ft_freqstatistics(cfg, FR_alltrials); I have the following error : Error using getdimord (line 15) field "cohspctrm" not present in data which makes a lot of sense, since I did not gave coherence as an input... I gave Frequency representations.. I was hoping that maybe the function would calculate the coherence itself for the statistics ? ^^ But it's clearly not the way to go. Could you be a bit more explicit about what you meant ? Thanks a lot. Best, Laetitia Lalla PhD student in Neurosciences INMED, Marseille, France On 31-03-2016 13:47, Snijders, T.M. (Tineke) wrote: Hi Laetitia, If you only have one subject you do need individual trial data, otherwise you can't do statistics like this. You need multiple observations (either subjects or trials). Best, Tineke ________________________________ From: fieldtrip-bounces at science.ru.nl [fieldtrip-bounces at science.ru.nl] on behalf of laetitia.lalla at inserm.fr [laetitia.lalla at inserm.fr] Sent: Thursday, March 31, 2016 1:11 PM To: fieldtrip at science.ru.nl Subject: [FieldTrip] Question about coherence statistics Dear FielTrip community, Sorry to bother you again... I have a question about the statistical testing to assess coherence differences and the related paper by E Maris, JM Schoffelen and P Fries (Journal of Neuroscience Methods, 2007) I believe I am exactly in the framework described in this paper, but I guess there is still some crucial information that I don't understand... This is my story : - It's a single-subject study - I want to compare two sets of trials observed in different conditions. - The 2 sets of trials are exactly the same size, so my coherence estimate won't be biased by the "unequal sample size problem". - I just want to compare for 1 channel pair, for 1 frequency bin [6Hz 10Hz], so I guess the Multiple Comparison problem won't affect my analysis too much (either in the spatial or the spectral dimension). Based on the paper, I could refer myself to the point "2.7.1. A non parametric satistical test for a single signal pair and a single frequency bin". - Since my interest is in the coherence difference for a single signal pair, I can choose [|C1(f)|-|C2(f)|] as a test statistic. - And I can perform the montecarlo simulation. My question is the following : How can I implement the nonparametric test of the coherence difference between my 2 conditions with the fieldtrip functions ? This is what I did : 1) Extract and preprocess the signal from my condition 1. 2) freq1= ft_freqanalysis(cfg, signal1) (with cfg.method='mtmfft', cfg.output='powandcsd') → 3) coh1= ft_connectivityanalysis(cfg, freq1) I did the same thing for the other condition → coh2. And then for the statistics : cfg = []; cfg.statistic = 'diff'; (% because the statistic test than I chose is the difference [|C1(f)|-|C2(f)|]) cfg.parameter='cohspctrm'; cfg.method = 'montecarlo'; cfg.numrandomization = 1000; cfg.ivar = 1; cfg.alpha=0.05; cfg.tail=0; cfg.correcttail='alpha'; stat=ft_freqstatistics(cfg, coh1, coh2); And it gives me the following error : Error using ft_checkconfig (line 153) The field cfg.design is required. Here, I really don't understand why I'm asked for the design matrix... When doing the statistics for the Power, I understood that the design matrix was telling which trial belonged to the condition 1 and which trial belonged to the condition 2. But here, it doesn't make any sense because my coherence was calculated by averaging on the trials... Does the design matrix mean something differently here ? Or maybe I forgot one parameter to put in the cfg ? Any help will be appreciated ! Thanks a lot for your time, Laetitia Lalla PhD student in Neurosciences INMED, Marseille, France _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From hibafouani123 at hotmail.com Fri Apr 1 12:15:53 2016 From: hibafouani123 at hotmail.com (hiba fouani) Date: Fri, 1 Apr 2016 10:15:53 +0000 Subject: [FieldTrip] Bidomain model instead of dipoles In-Reply-To: References: Message-ID: Dear fieldtripper, I want to study source localization for ecg but with bidomain model for sources not dipoles, is it possible with fieldtrip or openmeeg? and thank you for suggestion for any tool. Thank you Hiba > From: fieldtrip-request at science.ru.nl > Subject: fieldtrip Digest, Vol 65, Issue 1 > To: fieldtrip at science.ru.nl > Date: Fri, 1 Apr 2016 12:00:02 +0200 > > Send fieldtrip mailing list submissions to > fieldtrip at science.ru.nl > > To subscribe or unsubscribe via the World Wide Web, visit > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > or, via email, send a message with subject or body 'help' to > fieldtrip-request at science.ru.nl > > You can reach the person managing the list at > fieldtrip-owner at science.ru.nl > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of fieldtrip digest..." > > > Today's Topics: > > 1. Question about coherence statistics (laetitia.lalla at inserm.fr) > 2. Re: Question about coherence statistics (Snijders, T.M. (Tineke)) > 3. Re: Question about coherence statistics (laetitia.lalla at inserm.fr) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Thu, 31 Mar 2016 13:11:31 +0200 > From: laetitia.lalla at inserm.fr > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Question about coherence statistics > Message-ID: > Content-Type: text/plain; charset="utf-8" > > > > Dear FielTrip community, > > Sorry to bother you again... > > I have a question about the statistical testing to assess coherence > differences and the related paper by E Maris, JM Schoffelen and P Fries > (Journal of Neuroscience Methods, 2007) > > I believe I am exactly in the framework described in this paper, but I > guess there is still some crucial information that I don't understand... > > > This is my story : > > - It's a single-subject study > > - I want to compare two sets of trials observed in different conditions. > > > - The 2 sets of trials are exactly the same size, so my coherence > estimate won't be biased by the "unequal sample size problem". > > - I just want to compare for 1 channel pair, for 1 frequency bin [6Hz > 10Hz], so I guess the Multiple Comparison problem won't affect my > analysis too much (either in the spatial or the spectral dimension). > > Based on the paper, I could refer myself to the point "2.7.1. A non > parametric satistical test for a single signal pair and a single > frequency bin". > > - Since my interest is in the coherence difference for a single signal > pair, I can choose [|C1(f)|-|C2(f)|] as a test statistic. > > - And I can perform the montecarlo simulation. > > My question is the following : How can I implement the nonparametric > test of the coherence difference between my 2 conditions with the > fieldtrip functions ? > > This is what I did : > > 1) Extract and preprocess the signal from my condition 1. > > 2) freq1= ft_freqanalysis(cfg, signal1) (with cfg.method='mtmfft', > cfg.output='powandcsd') ? > > 3) coh1= ft_connectivityanalysis(cfg, freq1) > > I did the same thing for the other condition ? coh2. > > And then for the statistics : > > cfg = []; > > cfg.statistic = 'diff'; (% because the statistic test than I chose is > the difference [|C1(f)|-|C2(f)|]) > > cfg.parameter='cohspctrm'; > > cfg.method = 'montecarlo'; > > cfg.numrandomization = 1000; > > cfg.ivar = 1; > > cfg.alpha=0.05; > > cfg.tail=0; > > cfg.correcttail='alpha'; > > stat=ft_freqstatistics(cfg, coh1, coh2); > > And it gives me the following error : > > Error using ft_checkconfig (line 153) > > The field cfg.design is required. > > Here, I really don't understand why I'm asked for the design matrix... > When doing the statistics for the Power, I understood that the design > matrix was telling which trial belonged to the condition 1 and which > trial belonged to the condition 2. But here, it doesn't make any sense > because my coherence was calculated by averaging on the trials... > > Does the design matrix mean something differently here ? Or maybe I > forgot one parameter to put in the cfg ? > > Any help will be appreciated ! > > Thanks a lot for your time, > > Laetitia Lalla > > PhD student in Neurosciences > > INMED, Marseille, France > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > Message: 2 > Date: Thu, 31 Mar 2016 11:47:19 +0000 > From: "Snijders, T.M. (Tineke)" > To: FieldTrip discussion list > Subject: Re: [FieldTrip] Question about coherence statistics > Message-ID: > <815A9820E75FBC4F96B7CD3A8089D11C378AE3E0 at exprd04.hosting.ru.nl> > Content-Type: text/plain; charset="iso-2022-jp" > > Hi Laetitia, > > If you only have one subject you do need individual trial data, otherwise you can't do statistics like this. > You need multiple observations (either subjects or trials). > > Best, > Tineke > > ________________________________ > From: fieldtrip-bounces at science.ru.nl [fieldtrip-bounces at science.ru.nl] on behalf of laetitia.lalla at inserm.fr [laetitia.lalla at inserm.fr] > Sent: Thursday, March 31, 2016 1:11 PM > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Question about coherence statistics > > > Dear FielTrip community, > > Sorry to bother you again... > > I have a question about the statistical testing to assess coherence differences and the related paper by E Maris, JM Schoffelen and P Fries (Journal of Neuroscience Methods, 2007) > > I believe I am exactly in the framework described in this paper, but I guess there is still some crucial information that I don't understand... > > > > This is my story : > > - It's a single-subject study > > - I want to compare two sets of trials observed in different conditions. > > - The 2 sets of trials are exactly the same size, so my coherence estimate won't be biased by the ?unequal sample size problem?. > > - I just want to compare for 1 channel pair, for 1 frequency bin [6Hz 10Hz], so I guess the Multiple Comparison problem won't affect my analysis too much (either in the spatial or the spectral dimension). > > > > Based on the paper, I could refer myself to the point ?2.7.1. A non parametric satistical test for a single signal pair and a single frequency bin?. > > - Since my interest is in the coherence difference for a single signal pair, I can choose [|C1(f)|-|C2(f)|] as a test statistic. > > - And I can perform the montecarlo simulation. > > > > My question is the following : How can I implement the nonparametric test of the coherence difference between my 2 conditions with the fieldtrip functions ? > > > > This is what I did : > > 1) Extract and preprocess the signal from my condition 1. > > 2) freq1= ft_freqanalysis(cfg, signal1) (with cfg.method='mtmfft', cfg.output='powandcsd') ? > > 3) coh1= ft_connectivityanalysis(cfg, freq1) > > > > I did the same thing for the other condition ? coh2. > > > > And then for the statistics : > > cfg = []; > > cfg.statistic = 'diff'; (% because the statistic test than I chose is the difference [|C1(f)|-|C2(f)|]) > > cfg.parameter='cohspctrm'; > > cfg.method = 'montecarlo'; > > cfg.numrandomization = 1000; > > cfg.ivar = 1; > > cfg.alpha=0.05; > > cfg.tail=0; > > cfg.correcttail='alpha'; > > stat=ft_freqstatistics(cfg, coh1, coh2); > > > > And it gives me the following error : > > Error using ft_checkconfig (line 153) > > The field cfg.design is required. > > > > Here, I really don't understand why I'm asked for the design matrix... When doing the statistics for the Power, I understood that the design matrix was telling which trial belonged to the condition 1 and which trial belonged to the condition 2. But here, it doesn't make any sense because my coherence was calculated by averaging on the trials... > > Does the design matrix mean something differently here ? Or maybe I forgot one parameter to put in the cfg ? > > > > Any help will be appreciated ! > > > > Thanks a lot for your time, > > > > Laetitia Lalla > > PhD student in Neurosciences > > INMED, Marseille, France > > > > > > > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > Message: 3 > Date: Thu, 31 Mar 2016 15:22:31 +0200 > From: laetitia.lalla at inserm.fr > To: FieldTrip discussion list > Subject: Re: [FieldTrip] Question about coherence statistics > Message-ID: > Content-Type: text/plain; charset="utf-8" > > > > Dear Tineke, > > thank you very much for your fast answer ! I'm not sure I understand > what you mean though... Maybe i did not express myself correctly. I do > have individual trial data : I have 26 observations for condition 1 and > 26 observations for condition 2. > > They appear : > > - In my structure "data" (output of ft_preprocessing) : data.trial is a > cell {1 x nbtrials} (in my case : {1, 26}) > > - in my structure "freq" (output of ft_freqanalysis) : freq.powspctrm is > a matrix of dimension : nbtrials X nbchannel X nbfreq (in my case > 26x2x25) > > But I don't have this information anymore in the structure "coh" (output > of ft_connectivityanalysis) : coh.cospctrm is a matrix of dimension > nbchannelcmb x nbfreq (in my case 1x25) since the coherence is > calculated by averaging over trials... > > You may mean I should give the "freq" structures as inputs to the > fonction ft_freqstatistics ? > > I just tried that : I created a structure data_all by concatenated > data1.trial and data2.trial (and every other appropriate attribute). I > took the Time Frequency Representation with ft_freqanalysis (with > keeptrials='yes') to obtain a structure TFR_all (following this tutorial > : http://www.fieldtriptoolbox.org/tutorial/natmeg/statistics This is > actually how I did the statistics for the Power). > > But then, if I give this as an input to ft_freqstatistics, like this : > > cfg = []; > cfg.statistic = 'diff'; > cfg.parameter='cohspctrm'; > cfg.design= [ones(1,nbtrial)) 2*ones(1, nbtrial))]; %same nb of trials > for both condition > cfg.method = 'montecarlo'; > cfg.numrandomization = 1000; > cfg.ivar = 1; > cfg.alpha=0.05; > cfg.tail=0; > cfg.correcttail='alpha'; > >> stat=ft_freqstatistics(cfg, FR_alltrials); > > I have the following error : > > Error using getdimord (line 15) > field "cohspctrm" not present in data > > which makes a lot of sense, since I did not gave coherence as an > input... I gave Frequency representations.. I was hoping that maybe the > function would calculate the coherence itself for the statistics ? ^^ > But it's clearly not the way to go. > > Could you be a bit more explicit about what you meant ? > > Thanks a lot. > > Best, > > Laetitia Lalla > > PhD student in Neurosciences > > INMED, Marseille, France > > On 31-03-2016 13:47, Snijders, T.M. (Tineke) wrote: > > > Hi Laetitia, > > > > If you only have one subject you do need individual trial data, otherwise you can't do statistics like this. > > You need multiple observations (either subjects or trials). > > > > Best, > > Tineke > > > > ------------------------- > > > > FROM: fieldtrip-bounces at science.ru.nl [fieldtrip-bounces at science.ru.nl] on behalf of laetitia.lalla at inserm.fr [laetitia.lalla at inserm.fr] > > SENT: Thursday, March 31, 2016 1:11 PM > > TO: fieldtrip at science.ru.nl > > SUBJECT: [FieldTrip] Question about coherence statistics > > > > Dear FielTrip community, > > > > Sorry to bother you again... > > > > I have a question about the statistical testing to assess coherence differences and the related paper by E Maris, JM Schoffelen and P Fries (Journal of Neuroscience Methods, 2007) > > > > I believe I am exactly in the framework described in this paper, but I guess there is still some crucial information that I don't understand... > > > > This is my story : > > > > - It's a single-subject study > > > > - I want to compare two sets of trials observed in different conditions. > > > > - The 2 sets of trials are exactly the same size, so my coherence estimate won't be biased by the "unequal sample size problem". > > > > - I just want to compare for 1 channel pair, for 1 frequency bin [6Hz 10Hz], so I guess the Multiple Comparison problem won't affect my analysis too much (either in the spatial or the spectral dimension). > > > > Based on the paper, I could refer myself to the point "2.7.1. A non parametric satistical test for a single signal pair and a single frequency bin". > > > > - Since my interest is in the coherence difference for a single signal pair, I can choose [|C1(f)|-|C2(f)|] as a test statistic. > > > > - And I can perform the montecarlo simulation. > > > > My question is the following : How can I implement the nonparametric test of the coherence difference between my 2 conditions with the fieldtrip functions ? > > > > This is what I did : > > > > 1) Extract and preprocess the signal from my condition 1. > > > > 2) freq1= ft_freqanalysis(cfg, signal1) (with cfg.method='mtmfft', cfg.output='powandcsd') ? > > > > 3) coh1= ft_connectivityanalysis(cfg, freq1) > > > > I did the same thing for the other condition ? coh2. > > > > And then for the statistics : > > > > cfg = []; > > > > cfg.statistic = 'diff'; (% because the statistic test than I chose is the difference [|C1(f)|-|C2(f)|]) > > > > cfg.parameter='cohspctrm'; > > > > cfg.method = 'montecarlo'; > > > > cfg.numrandomization = 1000; > > > > cfg.ivar = 1; > > > > cfg.alpha=0.05; > > > > cfg.tail=0; > > > > cfg.correcttail='alpha'; > > > > stat=ft_freqstatistics(cfg, coh1, coh2); > > > > And it gives me the following error : > > > > Error using ft_checkconfig (line 153) > > > > The field cfg.design is required. > > > > Here, I really don't understand why I'm asked for the design matrix... When doing the statistics for the Power, I understood that the design matrix was telling which trial belonged to the condition 1 and which trial belonged to the condition 2. But here, it doesn't make any sense because my coherence was calculated by averaging on the trials... > > > > Does the design matrix mean something differently here ? Or maybe I forgot one parameter to put in the cfg ? > > > > Any help will be appreciated ! > > > > Thanks a lot for your time, > > > > Laetitia Lalla > > > > PhD student in Neurosciences > > > > INMED, Marseille, France > > > > _______________________________________________ > > fieldtrip mailing list > > fieldtrip at donders.ru.nl > > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > End of fieldtrip Digest, Vol 65, Issue 1 > **************************************** -------------- next part -------------- An HTML attachment was scrubbed... URL: From juangpc at gmail.com Fri Apr 1 22:38:54 2016 From: juangpc at gmail.com (Juan) Date: Fri, 1 Apr 2016 22:38:54 +0200 Subject: [FieldTrip] tutorial on preprocessing ERP activity in combined MEG/EEG data Message-ID: Hi, Following the tutorial on preprocessing combined MEG/EEG data, I've noticed that in order to reproduce ft_multiplotER figures (i.e. ) some changes must be made to the code. ​ I c ​ould do the changes these myself but ​as this implies quite a few within the tutorial, ​ I'm wondering if this is ok or not. For instance, cfg.xlim and cfg.ylim must be changed to cfg.vlim and cfg.hlim. Also ERF_diff = ft_math(cfg, ERF_oddball, ERF_standard); must be changed to ERF_diff = ft_math(cfg, ERF_standard, ERF_oddball); ​ Juan -------------- next part -------------- An HTML attachment was scrubbed... URL: From laetitia.lalla at inserm.fr Mon Apr 4 11:45:49 2016 From: laetitia.lalla at inserm.fr (laetitia.lalla at inserm.fr) Date: Mon, 04 Apr 2016 11:45:49 +0200 Subject: [FieldTrip] Question about coherence statistics In-Reply-To: <815A9820E75FBC4F96B7CD3A8089D11C378AE4DA@exprd04.hosting.ru.nl> References: <2595287eebb0aeacfe5761a9de10de24@inserm.fr> <68a5ba763224075e6d9ec9aa7684221a@inserm.fr>, <815A9820E75FBC4F96B7CD3A8089D11C378AE3E0@exprd04.hosting.ru.nl>, <815A9820E75FBC4F96B7CD3A8089D11C378AE4DA@exprd04.hosting.ru.nl> Message-ID: <17c319aeab6f35a621fb193e8b051792@inserm.fr> Hey Tineke, Thank you very much ! It's all clear now. I was stuck with the list of statistics described in the "help" of freqstatistics and I did not even though of browsing the ft_statfun_XXX functions. I'm gonna try this right away. Have a nice day, Laetitia Lalla PhD student in Neurosciences INMED, Marseille, France On 01-04-2016 12:03, Snijders, T.M. (Tineke) wrote: > Hi Laetitia, > > Indeed, as 'coh' doesn't have the trial information anymore after ft_connectivityanalysis, you can't use it as input for ft_freqstatistics if you only have one subject. > > Indeed, giving 'cohspctrm' as parameter with your freq data doesn't work as 'cohspctrm' is not in your freq data. The cfg.parameter specifies what data to use for the randomization, so that parameter should be in the data you give as input. > > You can use the freq data as input for freq_statistics, but then you have to change your cfg.statistic. This is the statistical function that is called after shuffling your trials - in your case after shuffling your trials the coherence has to be computed and the difference between conditions calculated. As far as I know, if you set your cfg.statistic to 'diff_itc', it will compute the difference in the inter-trial coherence between two conditions (looking at the phase consistency over trials). > > Best, > Tineke > > ------------------------- > > FROM: laetitia.lalla at inserm.fr [laetitia.lalla at inserm.fr] > SENT: Thursday, March 31, 2016 3:22 PM > TO: FieldTrip discussion list > CC: Snijders, T.M. (Tineke) > SUBJECT: Re: [FieldTrip] Question about coherence statistics > > Dear Tineke, > > thank you very much for your fast answer ! I'm not sure I understand what you mean though... Maybe i did not express myself correctly. I do have individual trial data : I have 26 observations for condition 1 and 26 observations for condition 2. > > They appear : > > - In my structure "data" (output of ft_preprocessing) : data.trial is a cell {1 x nbtrials} (in my case : {1, 26}) > > - in my structure "freq" (output of ft_freqanalysis) : freq.powspctrm is a matrix of dimension : nbtrials X nbchannel X nbfreq (in my case 26x2x25) > > But I don't have this information anymore in the structure "coh" (output of ft_connectivityanalysis) : coh.cospctrm is a matrix of dimension nbchannelcmb x nbfreq (in my case 1x25) since the coherence is calculated by averaging over trials... > > You may mean I should give the "freq" structures as inputs to the fonction ft_freqstatistics ? > > I just tried that : I created a structure data_all by concatenated data1.trial and data2.trial (and every other appropriate attribute). I took the Time Frequency Representation with ft_freqanalysis (with keeptrials='yes') to obtain a structure TFR_all (following this tutorial : http://www.fieldtriptoolbox.org/tutorial/natmeg/statistics This is actually how I did the statistics for the Power). > > But then, if I give this as an input to ft_freqstatistics, like this : > > cfg = []; > cfg.statistic = 'diff'; > cfg.parameter='cohspctrm'; > cfg.design= [ones(1,nbtrial)) 2*ones(1, nbtrial))]; %same nb of trials for both condition > cfg.method = 'montecarlo'; > cfg.numrandomization = 1000; > cfg.ivar = 1; > cfg.alpha=0.05; > cfg.tail=0; > cfg.correcttail='alpha'; >>> stat=ft_freqstatistics(cfg, FR_alltrials); > > I have the following error : > > Error using getdimord (line 15) > field "cohspctrm" not present in data > > which makes a lot of sense, since I did not gave coherence as an input... I gave Frequency representations.. I was hoping that maybe the function would calculate the coherence itself for the statistics ? ^^ But it's clearly not the way to go. > > Could you be a bit more explicit about what you meant ? > > Thanks a lot. > > Best, > > Laetitia Lalla > > PhD student in Neurosciences > > INMED, Marseille, France > > On 31-03-2016 13:47, Snijders, T.M. (Tineke) wrote: > >> Hi Laetitia, >> >> If you only have one subject you do need individual trial data, otherwise you can't do statistics like this. >> You need multiple observations (either subjects or trials). >> >> Best, >> Tineke >> >> ------------------------- >> >> FROM: fieldtrip-bounces at science.ru.nl [fieldtrip-bounces at science.ru.nl] on behalf of laetitia.lalla at inserm.fr [laetitia.lalla at inserm.fr] >> SENT: Thursday, March 31, 2016 1:11 PM >> TO: fieldtrip at science.ru.nl >> SUBJECT: [FieldTrip] Question about coherence statistics >> >> Dear FielTrip community, >> >> Sorry to bother you again... >> >> I have a question about the statistical testing to assess coherence differences and the related paper by E Maris, JM Schoffelen and P Fries (Journal of Neuroscience Methods, 2007) >> >> I believe I am exactly in the framework described in this paper, but I guess there is still some crucial information that I don't understand... >> >> This is my story : >> >> - It's a single-subject study >> >> - I want to compare two sets of trials observed in different conditions. >> >> - The 2 sets of trials are exactly the same size, so my coherence estimate won't be biased by the "unequal sample size problem". >> >> - I just want to compare for 1 channel pair, for 1 frequency bin [6Hz 10Hz], so I guess the Multiple Comparison problem won't affect my analysis too much (either in the spatial or the spectral dimension). >> >> Based on the paper, I could refer myself to the point "2.7.1. A non parametric satistical test for a single signal pair and a single frequency bin". >> >> - Since my interest is in the coherence difference for a single signal pair, I can choose [|C1(f)|-|C2(f)|] as a test statistic. >> >> - And I can perform the montecarlo simulation. >> >> My question is the following : How can I implement the nonparametric test of the coherence difference between my 2 conditions with the fieldtrip functions ? >> >> This is what I did : >> >> 1) Extract and preprocess the signal from my condition 1. >> >> 2) freq1= ft_freqanalysis(cfg, signal1) (with cfg.method='mtmfft', cfg.output='powandcsd') → >> >> 3) coh1= ft_connectivityanalysis(cfg, freq1) >> >> I did the same thing for the other condition → coh2. >> >> And then for the statistics : >> >> cfg = []; >> >> cfg.statistic = 'diff'; (% because the statistic test than I chose is the difference [|C1(f)|-|C2(f)|]) >> >> cfg.parameter='cohspctrm'; >> >> cfg.method = 'montecarlo'; >> >> cfg.numrandomization = 1000; >> >> cfg.ivar = 1; >> >> cfg.alpha=0.05; >> >> cfg.tail=0; >> >> cfg.correcttail='alpha'; >> >> stat=ft_freqstatistics(cfg, coh1, coh2); >> >> And it gives me the following error : >> >> Error using ft_checkconfig (line 153) >> >> The field cfg.design is required. >> >> Here, I really don't understand why I'm asked for the design matrix... When doing the statistics for the Power, I understood that the design matrix was telling which trial belonged to the condition 1 and which trial belonged to the condition 2. But here, it doesn't make any sense because my coherence was calculated by averaging on the trials... >> >> Does the design matrix mean something differently here ? Or maybe I forgot one parameter to put in the cfg ? >> >> Any help will be appreciated ! >> >> Thanks a lot for your time, >> >> Laetitia Lalla >> >> PhD student in Neurosciences >> >> INMED, Marseille, France >> >> _______________________________________________ >> 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 -------------- next part -------------- An HTML attachment was scrubbed... URL: From rmontefusco at med.uchile.cl Mon Apr 4 14:17:12 2016 From: rmontefusco at med.uchile.cl (Rodrigo Montefusco) Date: Mon, 4 Apr 2016 09:17:12 -0300 Subject: [FieldTrip] Question about coherence statistics In-Reply-To: <17c319aeab6f35a621fb193e8b051792@inserm.fr> References: <2595287eebb0aeacfe5761a9de10de24@inserm.fr> <68a5ba763224075e6d9ec9aa7684221a@inserm.fr> <815A9820E75FBC4F96B7CD3A8089D11C378AE3E0@exprd04.hosting.ru.nl> <815A9820E75FBC4F96B7CD3A8089D11C378AE4DA@exprd04.hosting.ru.nl> <17c319aeab6f35a621fb193e8b051792@inserm.fr> Message-ID: Hi Laetitia, What you may try is to perform a "manual" permutation of your conditions before calculation of the coherence, and subtract the values of both randomized conditions... do that many....many many many times (1000 or above depending on your alpha...but as you have not many trials, do the math on how many you will need)...and you will end up with a distribution of difference coherence values. Then,based on your hypothesis, you can set a percentile threshold. Then subtract your original coherence values and check if they are under or over the threshold. If somebody find this is not correct, please let me know with an explanation! :) Best regards. YOGUI ps: best mail list ever! On Mon, Apr 4, 2016 at 6:45 AM, wrote: > Hey Tineke, > > Thank you very much ! It's all clear now. I was stuck with the list of > statistics described in the "help" of freqstatistics and I did not even > though of browsing the ft_statfun_XXX functions. I'm gonna try this right > away. > > Have a nice day, > > > > Laetitia Lalla > > PhD student in Neurosciences > > INMED, Marseille, France > > > > On 01-04-2016 12:03, Snijders, T.M. (Tineke) wrote: > > Hi Laetitia, > > Indeed, as 'coh' doesn't have the trial information anymore after > ft_connectivityanalysis, you can't use it as input for ft_freqstatistics if > you only have one subject. > > Indeed, giving 'cohspctrm' as parameter with your freq data doesn't work > as 'cohspctrm' is not in your freq data. The cfg.parameter specifies what > data to use for the randomization, so that parameter should be in the data > you give as input. > > You can use the freq data as input for freq_statistics, but then you have > to change your cfg.statistic. This is the statistical function that is > called after shuffling your trials - in your case after shuffling your > trials the coherence has to be computed and the difference between > conditions calculated. As far as I know, if you set your cfg.statistic to > 'diff_itc', it will compute the difference in the inter-trial coherence > between two conditions (looking at the phase consistency over trials). > > Best, > Tineke > > ------------------------------ > *From:* laetitia.lalla at inserm.fr [laetitia.lalla at inserm.fr] > *Sent:* Thursday, March 31, 2016 3:22 PM > *To:* FieldTrip discussion list > *Cc:* Snijders, T.M. (Tineke) > *Subject:* Re: [FieldTrip] Question about coherence statistics > > > Dear Tineke, > > thank you very much for your fast answer ! I'm not sure I understand what > you mean though... Maybe i did not express myself correctly. I do have > individual trial data : I have 26 observations for condition 1 and 26 > observations for condition 2. > > They appear : > > - In my structure "data" (output of ft_preprocessing) : data.trial is a > cell {1 x nbtrials} (in my case : {1, 26}) > > - in my structure "freq" (output of ft_freqanalysis) : freq.powspctrm is a > matrix of dimension : nbtrials X nbchannel X nbfreq (in my case 26x2x25) > > But I don't have this information anymore in the structure "coh" (output > of ft_connectivityanalysis) : coh.cospctrm is a matrix of dimension > nbchannelcmb x nbfreq (in my case 1x25) since the coherence is calculated > by averaging over trials... > > > > You may mean I should give the "freq" structures as inputs to the fonction > ft_freqstatistics ? > > I just tried that : I created a structure data_all by concatenated > data1.trial and data2.trial (and every other appropriate attribute). I took > the Time Frequency Representation with ft_freqanalysis (with > keeptrials='yes') to obtain a structure TFR_all (following this tutorial : > http://www.fieldtriptoolbox.org/tutorial/natmeg/statistics This is > actually how I did the statistics for the Power). > > But then, if I give this as an input to ft_freqstatistics, like this : > > cfg = []; > cfg.statistic = 'diff'; > cfg.parameter='cohspctrm'; > cfg.design= [ones(1,nbtrial)) 2*ones(1, nbtrial))]; %same nb of trials for > both condition > cfg.method = 'montecarlo'; > cfg.numrandomization = 1000; > cfg.ivar = 1; > cfg.alpha=0.05; > cfg.tail=0; > cfg.correcttail='alpha'; > >> stat=ft_freqstatistics(cfg, FR_alltrials); > > I have the following error : > > Error using getdimord (line 15) > field "cohspctrm" not present in data > > which makes a lot of sense, since I did not gave coherence as an input... > I gave Frequency representations.. I was hoping that maybe the function > would calculate the coherence itself for the statistics ? ^^ But it's > clearly not the way to go. > > > > Could you be a bit more explicit about what you meant ? > > > > Thanks a lot. > > Best, > > Laetitia Lalla > > PhD student in Neurosciences > > INMED, Marseille, France > > > > > > On 31-03-2016 13:47, Snijders, T.M. (Tineke) wrote: > > Hi Laetitia, > > If you only have one subject you do need individual trial data, otherwise > you can't do statistics like this. > You need multiple observations (either subjects or trials). > > Best, > Tineke > > ------------------------------ > *From:* fieldtrip-bounces at science.ru.nl [fieldtrip-bounces at science.ru.nl] > on behalf of laetitia.lalla at inserm.fr [laetitia.lalla at inserm.fr] > *Sent:* Thursday, March 31, 2016 1:11 PM > *To:* fieldtrip at science.ru.nl > *Subject:* [FieldTrip] Question about coherence statistics > > > Dear FielTrip community, > > Sorry to bother you again... > > I have a question about the statistical testing to assess coherence > differences and the related paper by E Maris, JM Schoffelen and P Fries > (Journal of Neuroscience Methods, 2007) > > I believe I am exactly in the framework described in this paper, but I > guess there is still some crucial information that I don't understand... > > > > This is my story : > > - It's a single-subject study > > - I want to compare two sets of trials observed in different conditions. > > - The 2 sets of trials are exactly the same size, so my coherence estimate > won't be biased by the "unequal sample size problem". > > - I just want to compare for 1 channel pair, for 1 frequency bin [6Hz > 10Hz], so I guess the Multiple Comparison problem won't affect my analysis > too much (either in the spatial or the spectral dimension). > > > > Based on the paper, I could refer myself to the point "2.7.1. A non > parametric satistical test for a single signal pair and a single frequency > bin". > > - Since my interest is in the coherence difference for a single signal > pair, I can choose [|C1(f)|-|C2(f)|] as a test statistic. > > - And I can perform the montecarlo simulation. > > > > My question is the following : How can I implement the nonparametric test > of the coherence difference between my 2 conditions with the fieldtrip > functions ? > > > > This is what I did : > > 1) Extract and preprocess the signal from my condition 1. > > 2) freq1= ft_freqanalysis(cfg, signal1) (with cfg.method='mtmfft', > cfg.output='powandcsd') → > > 3) coh1= ft_connectivityanalysis(cfg, freq1) > > > > I did the same thing for the other condition → coh2. > > > > And then for the statistics : > > cfg = []; > > cfg.statistic = 'diff'; (% because the statistic test than I chose is the > difference [|C1(f)|-|C2(f)|]) > > cfg.parameter='cohspctrm'; > > cfg.method = 'montecarlo'; > > cfg.numrandomization = 1000; > > cfg.ivar = 1; > > cfg.alpha=0.05; > > cfg.tail=0; > > cfg.correcttail='alpha'; > > stat=ft_freqstatistics(cfg, coh1, coh2); > > > > And it gives me the following error : > > Error using ft_checkconfig (line 153) > > The field cfg.design is required. > > > > Here, I really don't understand why I'm asked for the design matrix... > When doing the statistics for the Power, I understood that the design > matrix was telling which trial belonged to the condition 1 and which trial > belonged to the condition 2. But here, it doesn't make any sense because my > coherence was calculated by averaging on the trials... > > Does the design matrix mean something differently here ? Or maybe I forgot > one parameter to put in the cfg ? > > > > Any help will be appreciated ! > > > > Thanks a lot for your time, > > > > Laetitia Lalla > > PhD student in Neurosciences > > INMED, Marseille, France > > > > > > > > > _______________________________________________ > 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 > > > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From wanyu at gazzaleylab.ucsf.edu Mon Apr 4 20:15:12 2016 From: wanyu at gazzaleylab.ucsf.edu (WanYu Hsu) Date: Mon, 4 Apr 2016 11:15:12 -0700 Subject: [FieldTrip] questions about power spectrum analysis and bootstrp Message-ID: Hi community, I am recently running EEG power spectrum analysis. For some reason, I wanted to run the analysis with bootstrapped trials. Is there anyway to apply bootstrap with ft_freqanalysis? I tried adding bootstrap option in ft_sourceanalysis to ft_freqanalysis, but it doesn't work. cfg = []; cfg.foi = 2:30; cfg.method = 'mtmconvol'; cfg.taper = 'hanning'; cfg.keeptrials = 'no'; cfg.t_ftimwin = 3.2 ./ cfg.foi; cfg.toi = -0.5:0.01:0.6; cfg.output = 'powandcsd'; cfg.bootstrap = 'yes'; cfg.numbootstrap = 25; % cfg.trials = 'all'; freq2{s} = ft_freqanalysis(cfg, data_concat_TFR(s)); Any help would be appreciated. Best, WanYu Hsu -------------- next part -------------- An HTML attachment was scrubbed... URL: From gina.joue at univr.it Tue Apr 5 10:51:53 2016 From: gina.joue at univr.it (gj) Date: Tue, 5 Apr 2016 10:51:53 +0200 Subject: [FieldTrip] Error with interpn when calling, ft_sourceinterpolate In-Reply-To: References: Message-ID: <57037CA9.1030602@univr.it> Hi, I just noticed that I had messed up the message threading (no easy way to keep threading as I only receive a daily digest), and I wanted to leave feedback for future reference that the problem was indeed, as you pointed out Jan-Mathijs, because of the incompatible resolution of the template grid I was using -- once I loaded one with a different resolution (standard_sourcemodel3d10mm.mat instead of standard_sourcemodel3d5mm.mat in my case), I didn't get the error anymore. Thanks a lot, Jan-Mathijs!!! g > Message: 4 > Date: Tue, 29 Mar 2016 07:50:05 +0000 > From: "Schoffelen, J.M. (Jan Mathijs)" > To: FieldTrip discussion list > Subject: Re: [FieldTrip] fieldtrip Digest, Vol 64, Issue 32 > Message-ID: > Content-Type: text/plain; charset="utf-8" > > Hi Gina, > > That?s what I was afraid of. By replacing the .pos and .dim you made the data structure inconsistent. The number of source positions should be kept constant, i.e. you need to use a ?template grid? that is defined at the same approximate spatial resolution as your individual grids. The reason for this is that the numeric data (e.g. in source.avg.pow) should have the same number of elements as the size(source.pos,1). > > Best, > Jan-Mathijs > > ------------------------------ > > Message: 3 > Date: Tue, 29 Mar 2016 09:16:29 +0200 > From: gj > To: fieldtrip at science.ru.nl > Subject: Re: [FieldTrip] fieldtrip Digest, Vol 64, Issue 32 > Message-ID: <56FA2BCD.7010201 at univr.it> > Content-Type: text/plain; charset=windows-1252; format=flowed > > Hi Jan-Mathijs, > > Before replacing them with the values from the template grid, > source_proj.dim is 1-row matrix = [15,18,13] > and > source_proj.pos a 3510x3 matrix of doubles > > > After, it's > source_proj.dim is a 1-row matrix = [32,39,34] > and > source_proj.pos is a 42432x3 matrix of doubles > > Thanks! > Gina From maity_winky at yahoo.es Tue Apr 5 14:13:43 2016 From: maity_winky at yahoo.es (=?UTF-8?Q?Mait=C3=A9_Crespo_Garc=C3=ADa?=) Date: Tue, 5 Apr 2016 12:13:43 +0000 (UTC) Subject: [FieldTrip] questions about power spectrum analysis and bootstrp In-Reply-To: References: Message-ID: <25792913.5051433.1459858423045.JavaMail.yahoo@mail.yahoo.com> Dear WanYu Hsu, For frequency analysis, it seems to be implemented differently. You can first compute power and csd values with ft_freqanalysis and then access the bootstrap option with ft_freqstatistics calling the Montecarlo method. Would that way work for you? Best,Maite El Lunes 4 de abril de 2016 20:36, WanYu Hsu escribió: Hi community, I am recently running EEG power spectrum analysis. For some reason, I wanted to run the analysis with bootstrapped trials. Is there anyway to apply bootstrap with ft_freqanalysis? I tried adding bootstrap option in ft_sourceanalysis to ft_freqanalysis, but it doesn't work. cfg = []; cfg.foi         = 2:30; cfg.method = 'mtmconvol'; cfg.taper     = 'hanning'; cfg.keeptrials = 'no'; cfg.t_ftimwin  = 3.2 ./ cfg.foi; cfg.toi            = -0.5:0.01:0.6; cfg.output      = 'powandcsd'; cfg.bootstrap = 'yes'; cfg.numbootstrap  =  25; % cfg.trials = 'all'; freq2{s} = ft_freqanalysis(cfg, data_concat_TFR(s)); Any help would be appreciated. Best, WanYu Hsu _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From r.thomas at nin.knaw.nl Wed Apr 6 15:10:10 2016 From: r.thomas at nin.knaw.nl (Rajat Thomas) Date: Wed, 6 Apr 2016 13:10:10 +0000 Subject: [FieldTrip] FEM using Simbio Message-ID: <1459948210999.59028@nin.knaw.nl> Dear all, Has anyone used the FEM approach to Headmodels using Simbio recently? If so, I get this error: "Elements have wrong orientation or are degenerated" Any ideas? cfg = []; cfg.method ='simbio'; cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows mesh.tissyelabel vol = ft_prepare_headmodel(cfg, mesh); And; ? disp(mesh) hex: [545883x8 double] pnt: [569722x3 double] labels: [545883x1 double] tissue: [545883x1 double] tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} unit: 'mm' cfg: [1x1 struct] Any help would be highly appreciated. Rajat Rajat Mani Thomas Social Brain Lab Netherlands Institute for Neuroscience Amsterdam -------------- next part -------------- An HTML attachment was scrubbed... URL: From carsten.wolters at uni-muenster.de Wed Apr 6 16:03:09 2016 From: carsten.wolters at uni-muenster.de (Carsten Wolters) Date: Wed, 6 Apr 2016 16:03:09 +0200 Subject: [FieldTrip] FEM using Simbio In-Reply-To: <1459948210999.59028@nin.knaw.nl> References: <1459948210999.59028@nin.knaw.nl> Message-ID: <5705171D.3050306@uni-muenster.de> Dear Rajat, the element-node cards of SimBio-NeuroFEM need to follow certain orientations (see www.simbio.de). If you do not want to struggle with meshing/ordering, use the SimBio-VGRID mesher http://vgrid.simbio.de/ that follows the required ordering of nodes. You might use this mesher to produce 1mm geometry-adapted FEM meshes that show good overall performance, see http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf and http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf (latter was just accepted by NeuroImage). Best regards Carsten Am 06.04.2016 um 15:10 schrieb Rajat Thomas: > > Dear all, > > > Has anyone used the FEM approach to Headmodels using Simbio recently? > > > If so, I get this error: > > "Elements have wrong orientation or are degenerated" > > Any ideas? > > cfg = []; > > cfg.method ='simbio'; > > cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows > mesh.tissyelabel > > vol = ft_prepare_headmodel(cfg, mesh); > > > And; > > ​ > > disp(mesh) > hex: [545883x8 double] > pnt: [569722x3 double] > labels: [545883x1 double] > tissue: [545883x1 double] > tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} > unit: 'mm' > cfg: [1x1 struct] > > > Any help would be highly appreciated. > > Rajat > > > > > > > Rajat Mani Thomas > Social Brain Lab > Netherlands Institute for Neuroscience > Amsterdam > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: carsten_wolters.vcf Type: text/x-vcard Size: 402 bytes Desc: not available URL: From s.homolle at donders.ru.nl Wed Apr 6 17:13:42 2016 From: s.homolle at donders.ru.nl (Simon Homolle) Date: Wed, 6 Apr 2016 17:13:42 +0200 Subject: [FieldTrip] FEM using Simbio In-Reply-To: <1459948210999.59028@nin.knaw.nl> References: <1459948210999.59028@nin.knaw.nl> Message-ID: <41AC91C9-638C-4B4E-B19F-933D96A76249@donders.ru.nl> Dear Rajat, could you please describe how you generated your mesh? Bests, Simon Homölle PhD Candidate Donders Institute for Brain, Cognition and Behaviour Centre for Cognitive Neuroimaging Radboud University Nijmegen Phone: +31-(0)24-36-65059 > On 06 Apr 2016, at 15:10, Rajat Thomas wrote: > > Dear all, > > Has anyone used the FEM approach to Headmodels using Simbio recently? > > If so, I get this error: > "Elements have wrong orientation or are degenerated" > > Any ideas? > > cfg = []; > cfg.method ='simbio'; > cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows mesh.tissyelabel > vol = ft_prepare_headmodel(cfg, mesh); > > And; > ​ > disp(mesh) > hex: [545883x8 double] > pnt: [569722x3 double] > labels: [545883x1 double] > tissue: [545883x1 double] > tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} > unit: 'mm' > cfg: [1x1 struct] > > Any help would be highly appreciated. > > Rajat > > > > > > > Rajat Mani Thomas > Social Brain Lab > Netherlands Institute for Neuroscience > Amsterdam > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From gina.joue at univr.it Wed Apr 6 17:42:47 2016 From: gina.joue at univr.it (gj) Date: Wed, 6 Apr 2016 17:42:47 +0200 Subject: [FieldTrip] ft_source2sparse usage for EEG data Message-ID: <57052E77.5070709@univr.it> Hi FieldTrip community, Sorry for the onslaught of newbie questions. I would like to run a whole-brain network analysis on source level on a 2-sec continuous recording of EEG data. Following the tutorials (for MEG), I first run ft_source2sparse to reduce the matrix to only voxels inside the skull: >> source_sparse = ft_source2sparse(source_proj); total number of dipoles : 6804 number of dipoles inside brain: 3294 number of dipoles outside brain: 3510 When I then try to run the connectivity analysis (ft_connectivityanalysis), regardless of which connectivity method, I get the error: ---- error --- Requested 92232x92232 (126.8GB) array exceeds maximum array size preference. Creation of arrays greater than this limit may take a long time and cause MATLAB to become unresponsive. See array size limit or preference panel for more information. Error in univariate2bivariate (line 314) data.crsspctrm = (transpose(mom)*conj(mom))./nrpt; Error in ft_connectivityanalysis (line 434) [data, powindx, hasrpt] = univariate2bivariate(data, 'mom', 'crsspctrm', dtype, 'cmb', cfg.refindx, 'keeprpt', 0); ----end error--- I guess it is related to how I might have created the sourcemodel (ft_freqanalysis run with method='mtmfft', output='fourier', keeptrials='yes')? I am using FieldTrip ver.20160309. Thank you very much in advance for any help! Gina From pmetzak at gmail.com Thu Apr 7 01:47:49 2016 From: pmetzak at gmail.com (Paul Metzak) Date: Wed, 6 Apr 2016 16:47:49 -0700 Subject: [FieldTrip] TFR plotting following ft_freqbaseline Message-ID: Hello Fieldtrippers, I have a quick question about the output from my ft_freqanalysis. I ran ft_freqbaseline but when I plot the TFR using TFRmultiplot, I still have activity in the baseline period. I have included the cfg for the ft_freqanalysis call as well as the cfg for the ft_freqbaseline call and a .png from one of the sensors with this message. I took a look at the TFR plots for the pre- and post- ft_freqbaseline call and they look different so it is doing it's job but I am just wondering if activity in the baseline period represents a problem with the way I have analyzed my data thus far, or whether it is a normal result in fairly rapid MEG designs. Thanks for any information you can offer! Paul %%% ft_freqanalysis cfg %%%% tstep: 0.0500 twindow: 0.5000 fLow: 2 fHigh: 160 fstep: 2 method: 'mtmconvol' taper: 'hanning' rmvbl: 'yes' bltype: 'absolute' baseline: [-0.5000 0] trlbegin: -1 trlend: 2 conditions: [1 2 3] output: 'powandcsd' runname: 'run1' foi: [1x80 double] t_ftimwin: [80x1 double] toi: [1x51 double] %%% ft_freqbaseline cfg %%%% baseline: [-0.5000 0] baselinetype: 'absolute' -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: baseline_corr_prob.png Type: image/png Size: 10004 bytes Desc: not available URL: From carsten.wolters at uni-muenster.de Thu Apr 7 09:22:10 2016 From: carsten.wolters at uni-muenster.de (Carsten Wolters) Date: Thu, 7 Apr 2016 09:22:10 +0200 Subject: [FieldTrip] FEM using Simbio In-Reply-To: <5705171D.3050306@uni-muenster.de> References: <1459948210999.59028@nin.knaw.nl> <5705171D.3050306@uni-muenster.de> Message-ID: <57060AA2.8040804@uni-muenster.de> Dear Rajat, if you want to use another meshing tool than VGRID, the element-node-ordering of SimBio-NeuroFEM can be downloaded here: http://www.sci.utah.edu/~wolters/SimBio/SimBioNeuroFEMElementNodeOrdering0001.pdf For regular cubic elements and geometry-adapted cubic elements, please see the ordering of x23. I hope this will finally fully answer your question. Best regards Carsten Am 06.04.2016 um 16:03 schrieb Carsten Wolters: > Dear Rajat, > > the element-node cards of SimBio-NeuroFEM need to follow certain > orientations (see www.simbio.de). > > If you do not want to struggle with meshing/ordering, use the > SimBio-VGRID mesher > http://vgrid.simbio.de/ > that follows the required ordering of nodes. You might use this mesher > to produce 1mm geometry-adapted FEM meshes > that show good overall performance, see > http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf > and > http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf > (latter was just accepted by NeuroImage). > > Best regards > Carsten > > Am 06.04.2016 um 15:10 schrieb Rajat Thomas: >> >> Dear all, >> >> >> Has anyone used the FEM approach to Headmodels using Simbio recently? >> >> >> If so, I get this error: >> >> "Elements have wrong orientation or are degenerated" >> >> Any ideas? >> >> cfg = []; >> >> cfg.method ='simbio'; >> >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows >> mesh.tissyelabel >> >> vol = ft_prepare_headmodel(cfg, mesh); >> >> >> And; >> >> ​ >> >> disp(mesh) >> hex: [545883x8 double] >> pnt: [569722x3 double] >> labels: [545883x1 double] >> tissue: [545883x1 double] >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >> unit: 'mm' >> cfg: [1x1 struct] >> >> >> Any help would be highly appreciated. >> >> Rajat >> >> >> >> >> >> >> Rajat Mani Thomas >> Social Brain Lab >> Netherlands Institute for Neuroscience >> Amsterdam >> >> >> _______________________________________________ >> 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 -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: carsten_wolters.vcf Type: text/x-vcard Size: 402 bytes Desc: not available URL: From j.herring at donders.ru.nl Thu Apr 7 10:35:41 2016 From: j.herring at donders.ru.nl (Herring, J.D. (Jim)) Date: Thu, 7 Apr 2016 08:35:41 +0000 Subject: [FieldTrip] TFR plotting following ft_freqbaseline In-Reply-To: References: Message-ID: <3D00B7615FB58D46A0B49B9AD67A33EB3D98D61D@exprd01.hosting.ru.nl> Dear Paul, You can check whether the baseline correction worked by seeing whether the mean in the baseline per frequency is zero. If your frequency data is contained in the structure ‘freq’ you could do something like the following: baseline = [-.5 0]; channel_idx = find(strcmp(freq.label,’MLO11’)); time_idx = find(freq.time>=baseline(1)&freq.time<=baseline(2)); mean_baseline = nanmean(freq.powspctrm(channel_idx,:,time_idx),3); ‘mean_baseline’ should be roughly around zero for all frequencies. I suspect that the positive activity at/slightly before zero cancels the negative activity around -500 to -400. Here it is important to realize that whenever you are calculating a time-frequency analysis you are moving a sliding time-window over your data. The value at time-point zero therefore represent the power at that particular frequency from minus to plus half of the chosen window length. Given that your time-window is 500ms, the data at time-point zero therefore reflects the power from [-250 – 250ms]. It is therefore very likely that it contains stimulus-related activity. If you want to be sure that your baseline data does not represent any stimulus-related activity you should choose a baseline period earlier than, or at -250 ms (ie. Half your sliding time window size). Best, Jim From: fieldtrip-bounces at science.ru.nl [mailto:fieldtrip-bounces at science.ru.nl] On Behalf Of Paul Metzak Sent: Thursday, April 07, 2016 1:48 AM To: fieldtrip at science.ru.nl Subject: [FieldTrip] TFR plotting following ft_freqbaseline Hello Fieldtrippers, I have a quick question about the output from my ft_freqanalysis. I ran ft_freqbaseline but when I plot the TFR using TFRmultiplot, I still have activity in the baseline period. I have included the cfg for the ft_freqanalysis call as well as the cfg for the ft_freqbaseline call and a .png from one of the sensors with this message. I took a look at the TFR plots for the pre- and post- ft_freqbaseline call and they look different so it is doing it's job but I am just wondering if activity in the baseline period represents a problem with the way I have analyzed my data thus far, or whether it is a normal result in fairly rapid MEG designs. Thanks for any information you can offer! Paul %%% ft_freqanalysis cfg %%%% tstep: 0.0500 twindow: 0.5000 fLow: 2 fHigh: 160 fstep: 2 method: 'mtmconvol' taper: 'hanning' rmvbl: 'yes' bltype: 'absolute' baseline: [-0.5000 0] trlbegin: -1 trlend: 2 conditions: [1 2 3] output: 'powandcsd' runname: 'run1' foi: [1x80 double] t_ftimwin: [80x1 double] toi: [1x51 double] %%% ft_freqbaseline cfg %%%% baseline: [-0.5000 0] baselinetype: 'absolute' -------------- next part -------------- An HTML attachment was scrubbed... URL: From j.vorwerk at uni-muenster.de Thu Apr 7 14:25:42 2016 From: j.vorwerk at uni-muenster.de (Johannes Vorwerk) Date: Thu, 7 Apr 2016 14:25:42 +0200 Subject: [FieldTrip] FEM using Simbio In-Reply-To: <5705171D.3050306@uni-muenster.de> References: <1459948210999.59028@nin.knaw.nl> <5705171D.3050306@uni-muenster.de> Message-ID: <435735E3-7D87-4DD6-A2C1-E2BBFBBF4B44@googlemail.com> Hi, this question was already answered in this thread http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html If ft_volumereslice is not applied before the mesh generation, the afterwards applied transformation might flip the directions of the mesh, leading to the described error. Best, Johannes > Am 06.04.2016 um 16:03 schrieb Carsten Wolters : > > Dear Rajat, > > the element-node cards of SimBio-NeuroFEM need to follow certain orientations (see www.simbio.de ). > > If you do not want to struggle with meshing/ordering, use the SimBio-VGRID mesher > http://vgrid.simbio.de/ > that follows the required ordering of nodes. You might use this mesher to produce 1mm geometry-adapted FEM meshes > that show good overall performance, see > http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf > and > http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf > (latter was just accepted by NeuroImage). > > Best regards > Carsten > > Am 06.04.2016 um 15:10 schrieb Rajat Thomas: >> Dear all, >> >> Has anyone used the FEM approach to Headmodels using Simbio recently? >> >> If so, I get this error: >> "Elements have wrong orientation or are degenerated" >> >> Any ideas? >> >> cfg = []; >> cfg.method ='simbio'; >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows mesh.tissyelabel >> vol = ft_prepare_headmodel(cfg, mesh); >> >> And; >> ​ >> disp(mesh) >> hex: [545883x8 double] >> pnt: [569722x3 double] >> labels: [545883x1 double] >> tissue: [545883x1 double] >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >> unit: 'mm' >> cfg: [1x1 struct] >> >> Any help would be highly appreciated. >> >> Rajat >> >> >> >> >> >> >> Rajat Mani Thomas >> Social Brain Lab >> Netherlands Institute for Neuroscience >> Amsterdam >> >> >> _______________________________________________ >> 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 -------------- next part -------------- An HTML attachment was scrubbed... URL: From michelic72 at gmail.com Thu Apr 7 17:36:37 2016 From: michelic72 at gmail.com (Cristiano Micheli) Date: Thu, 7 Apr 2016 17:36:37 +0200 Subject: [FieldTrip] FEM using Simbio In-Reply-To: <1459948210999.59028@nin.knaw.nl> References: <1459948210999.59028@nin.knaw.nl> Message-ID: Hi Rajat My guess is that the orientations of your hexahedrons are not correct. According to a low-level file's internal rules, elements' orientations have to abide strict rules (not sure what exactly the contraints are in this case though...). I had same problems when for example the triangular boundaries used to define the 3d hexahedral mesh were not topologically correct, to start with. Admittedly this approach requires a lot of technical expertise. Can I ask you what do you need a FEM model for? Regards Cris Micheli On Wed, Apr 6, 2016 at 3:10 PM, Rajat Thomas wrote: > Dear all, > > > Has anyone used the FEM approach to Headmodels using Simbio recently? > > > If so, I get this error: > "Elements have wrong orientation or are degenerated" > > Any ideas? > > cfg = []; > > cfg.method ='simbio'; > > cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows > mesh.tissyelabel > > vol = ft_prepare_headmodel(cfg, mesh); > > > And; > > ​ > disp(mesh) > hex: [545883x8 double] > pnt: [569722x3 double] > labels: [545883x1 double] > tissue: [545883x1 double] > tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} > unit: 'mm' > cfg: [1x1 struct] > > > Any help would be highly appreciated. > > Rajat > > > > > > > Rajat Mani Thomas > Social Brain Lab > Netherlands Institute for Neuroscience > Amsterdam > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From giovannipellegrino at gmail.com Thu Apr 7 21:02:05 2016 From: giovannipellegrino at gmail.com (Giovanni Pellegrino) Date: Thu, 7 Apr 2016 15:02:05 -0400 Subject: [FieldTrip] Dipole fitting Message-ID: Dear Fieldtrippers, Do you know if the FieldTrip Dipole Fitting has been compared to the CTF, Elekta, BESA or Curry? Are you aware of any study on this topic? Thanks in advance for your help Giovanni -- Giovanni Pellegrino, MD Multimodal Functional Imaging Laboratory Montreal Neurological Institute, McGill University Address: 332 Duff Medical Building, 3775 rue University, Montreal, QC, H3A 2B4, Canada Phone: (514) 398–1678 Fax: (514) 398–7461 Email: giovannipellegrino at gmail.com, giovanni.pellegrino2 at mcgill.ca Homepage: http://www.bic.mni.mcgill.ca/ResearchLabsMFIL/PeopleGiovanni -------------- next part -------------- An HTML attachment was scrubbed... URL: From ole.jensen at donders.ru.nl Fri Apr 8 09:23:46 2016 From: ole.jensen at donders.ru.nl (Ole Jensen) Date: Fri, 8 Apr 2016 09:23:46 +0200 Subject: [FieldTrip] Birmingham-Illinois BRIDGE Fellowships Message-ID: <57075C82.8030309@donders.ru.nl> Dear all, I would like to point you to a set of Birmingham-Illinois BRIDGE Fellowships providing some exciting research and career prospects: http://www.birminghamillinoisbridge.org/index.php/fellows/ In particular the areas 'Cognition and Ageing' and 'Brain Trauma' could be relevant for candidates with EEG/MEG expertise. All the best, Ole -- Prof. dr. Ole Jensen http://www.neuosc.com From laetitia.lalla at inserm.fr Fri Apr 8 10:27:58 2016 From: laetitia.lalla at inserm.fr (laetitia.lalla at inserm.fr) Date: Fri, 08 Apr 2016 10:27:58 +0200 Subject: [FieldTrip] Using FieldTrip to analyse LFP recordings in rat In-Reply-To: References: <2595287eebb0aeacfe5761a9de10de24@inserm.fr> <68a5ba763224075e6d9ec9aa7684221a@inserm.fr> <815A9820E75FBC4F96B7CD3A8089D11C378AE3E0@exprd04.hosting.ru.nl> <815A9820E75FBC4F96B7CD3A8089D11C378AE4DA@exprd04.hosting.ru.nl> <17c319aeab6f35a621fb193e8b051792@inserm.fr> Message-ID: <628babdc107aebd4cc7588ea87ce5ea6@inserm.fr> Hello everyone, my name is Laetitia and I'm a Phd student in Marseille (France). I'm doing in-vivo recording in freely-moving rats : I implant them with 2 electrodes deep into 2 different regions of the brain. I'm studying the Local Field Potentials and I want to use FieldTrip to analyse the data. To simplify : - I have 2 rats. - Each rat did 20 sessions of the task (on 20 different days). - Each session consists of 20 trials of condition 1 and 20 trials of condition 2. I have 2 questions. 1) I have the feeling it would be meaningless to do "source reconstruction" because my electrodes are already deep inside my "source" and the LFP I am recording is very local. (My electrodes have 32 channels separated by 20-200 µm. The LFP is very very similar across all the channels, so I averaged over the 32 channels to have one signal for each region.) However, I see that 2 different functions exist for the statistics : FT_FREQSTATISTICS AND FT_SOURCESTATISTICS. So far, I've been using ft_freqstatistics but I encounter some issues (for exemple, doing monte-carlo permutation test to assess the imaginary coherence). I thought of computing it manually, but I'm thinking that maybe more stuff are implemented in ft_sourcestatisctics ? → Are these 2 functions fundamentally different or do they call the same sub-fonctions (and my problem has actually nothing to do with that) ? 2) I'm a bit confused with the vocabulary from EEG and MEG studies (I'm not used to it yet...). From what I understood, in human studies, you can do comparison for a single subject (across trials) or across subjects. But I have 3 levels of comparisons in my design : - WITHIN A SESSION, I WANT TO COMPARE ACROSS TRIALS (the 20 trials of condition 1 VS the 20 trials of condition 2). - WITHIN A RAT, I WANT TO COMPARE ACROSS SESSIONS (between the 2 conditions) - then - in the very end - ACROSS RATS. But I have only 2 rats so far, so I will deal with this later. I'm a bit confused when reading the tutorials and the mailing list, especially when it comes to the statistics... For example : this is from an email from 2013 by Eric Maris about "Nonparametric statistical testing of phase coherence" (http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006401.html) "To compare coherence between conditions across subjects (instead of trials), you need a different statfun: depsamplesT (for a within-subjects design; subjects have participated in all conditions) or indepsamplesT (for a between-subjects design; subjects have participated in only one condition)." → If I want to compare across sessions (for a same rat), can I actually consider that my different sessions are "subjects"? And then compare coherence "across subjects" would be doing it "across sessions" ? And I would be in a "within-subject design" since my sessions involve the 2 conditions every time ? I realise that it may be very confusing... I hope you will understand my problem ! And if anyone already applied fieldtrip functions to do statistics on a different framework that the usual EEG/MEG, please let me know ! Thanks a lot, Laetitia Lalla PhD Student in Neuroscience INMED, Marseille, France -------------- next part -------------- An HTML attachment was scrubbed... URL: From anne.urai at gmail.com Fri Apr 8 21:40:12 2016 From: anne.urai at gmail.com (Anne Urai) Date: Fri, 8 Apr 2016 21:40:12 +0200 Subject: [FieldTrip] ft_channelrepair with channel absent from data In-Reply-To: <6B298E85-A270-4D51-9219-F74A1C4B4AEE@donders.ru.nl> References: <50B23369.5020105@fcdonders.ru.nl> <50B33A53.2000701@donders.ru.nl> <6B298E85-A270-4D51-9219-F74A1C4B4AEE@donders.ru.nl> Message-ID: Dear FieldTrippers, I head a similar problem with interpolating missing channels from a CTF275 system. Since I couldn't find a final answer on the mailing list, I thought I'd share my solution. Specifically, giving both a cfg.layout and a cfg.neighbours input into ft_channelrepair avoids ft_fetch_sens getting the grad structure from the data (from which the channels that were not recorded are missing). With this setting, the sensors that are needed are defined based on the layout from the fieldtrip/templates directory, which is complete. Happy interpolating!  cfg = [];  cfg.layout = 'CTF275';  cfg.method = 'template';  neighbours = ft_prepare_neighbours(cfg);    cfg = [];  cfg.neighbours = neighbours;  cfg.method = 'spline'; % spline can handle missing grad struct  cfg.layout = 'CTF275'; % use this rather than grad structure to find sens info    % find missing channels in this dataset  cfg.missingchannel = {neighbours((~ismember({neighbours(:).label}, data.label))).label};  data = ft_channelrepair(cfg,data);  assert(length(data.label) == 275, 'CTF275 not completely interpolated!'); —  Anne E. Urai, MSc PhD student | Institut für Neurophysiologie und Pathophysiologie  Universitätsklinikum Hamburg-Eppendorf | Martinistrasse 52, 20246 | Hamburg, Germany  www.anneurai.net / @AnneEUrai From: Linsey Roijendijk Reply: FieldTrip discussion list Date: 20 December 2012 at 18:44:31 To: FieldTrip discussion list Subject:  Re: [FieldTrip] ft_channelrepair with channel absent from data Correction: I made a mistake in my e-mail, I meant the spherical spline interpolation method, because that's the one Jorn said should work. On Dec 20, 2012, at 6:31 PM, Linsey Roijendijk wrote: Hi all, I have also been trying to reinterpolate MEG channels that were never recorded with the nearest neighbour interpolation method, however when calling the method (in the same way Tom also used it) the function seems to do something, however it did not interpolate the missing sensors.  There were still 273 sensors instead of 275.  Do I need to give along a special cfg.grad or do something else? Thanks in advance, Linsey On Nov 26, 2012, at 10:45 AM, Jörn M. Horschig wrote:q Hey Tom, I guess I have several questions all at once: 1) Is it actually possible to reinterpolate MEG channels that were never recorded - eg because the channels were deactivated when the acquisition took place? Should work, but only with the SSI (=spherical spline interpolation) method. For the nearest neighbour interpolation, the function constructs a list of neuighbouring and constructs a weighted average. The function, however, wants to weigh each sensor according to its distance from the sensor to be reconstructed. That information can only be found in the grad structure, but in the grad structure there are only sensors which were recorded, thus the distance from a missing sensor cannot be measured because its position is missing in the grad structure. SSI should work though, cause it relies on a different rationale. 2) What might be causing the error I'm seeing? Since you have 301 channels rather than 275, my suspicion is that you include reference gradiometers. This should not fail in principle, though... maybe I can drop by your office to check it out? Got some time right now? 3) Where is ft_fetch_sens? It's a private function, can be found in FieldTrip/private. You have to cd to that directory in order for Matlab to find it (the idea behind private function is that there are only visible for higher-level function and 'hidden' for all other functions). Best, Jörn Thanks for help with any of the above! Best, Tom -- Tom Marshall, MSc. Neuronal Oscillations Group, Donders Centre for Cognitive Neuroimaging tel: +31(0)243668487 email: t.marshall at fcdonders.ru.nl postal: PO Box 9101, 6500HB, Nijmegen, The Netherlands visiting: Kapittelweg 29, 6525EN, Nijmegen, The Netherlands _______________________________________________ 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 -- Linsey Roijendijk MSc. Donders Institute for Brain, Cognition and Behaviour Centre for Neuroscience dept. of Biophysics Radboud University Nijmegen Montessorilaan 3, Room B.02.34 P.O.Box 9104 6500 HE Nijmegen The Netherlands Tel: +31(0)24 3612616 L.Roijendijk at donders.ru.nl _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -- Linsey Roijendijk MSc. Donders Institute for Brain, Cognition and Behaviour Centre for Neuroscience dept. of Biophysics Radboud University Nijmegen Montessorilaan 3, Room B.02.34 P.O.Box 9104 6500 HE Nijmegen The Netherlands Tel: +31(0)24 3612616 L.Roijendijk at donders.ru.nl _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From Max.Cantor at Colorado.EDU Fri Apr 8 23:02:17 2016 From: Max.Cantor at Colorado.EDU (Max Cantor) Date: Fri, 8 Apr 2016 15:02:17 -0600 Subject: [FieldTrip] TFR mask stats question; Baselined vs unbaselined statistics question Message-ID: Hi fieldtrippers, I have two unrelated stats questions, but I figured I'd post them together: 1. I've run within subjects permutation statistics testing the difference between an anomaly and control condition for three different language conditions; preposition, morphosyntax, and semantics. The code is nearly identical for both my ERPs and TFRs, except that when I plot my ERPs with cfg.maskparameter = 'mask', cfg.parameter = 'stat', and cfg.maskalpha = 0.025, it seems to multiplot just fine, whereas when I try to do the same for the TFRs, my multiplotted plots are blank, but when I comment out the mask, the stat plots are fine. I'll attach the code, but is there something I'm doing obviously wrong? Also, am I correct that my maskalpha should correspond to my alpha, and not my cluster alpha? This is the TFR code, but the ERP code is the exact same except for with timelocked data as the input and ft_timelockstatistics as the function. cfg = []; cfg.method = 'montecarlo'; cfg.statistic = 'depsamplesT'; cfg.correctm = 'cluster'; cfg.clusteralpha = 0.05; cfg.clusterstatistic = 'maxsum'; cfg.minnbchan = 2; cfg.neighbours = neighbours; cfg.tail = 0; cfg.clustertail = 0; cfg.alpha = 0.025; cfg.numrandomization = 1000; nsubj = length(tot_tfr2_bl{1}); design = zeros(2,2*nsubj); for i = 1:nsubj design(1,i) = i; end for i = 1:nsubj design(1,nsubj+i) = i; end design(2,1:nsubj) = 1; design(2,nsubj+1:2*nsubj) = 2; cfg.design = design; cfg.uvar = 1; cfg.ivar = 2; % Anomaly vs Control stat_tfr{1} = ft_freqstatistics(cfg, tot_tfr2_bl{1}{:}, tot_tfr2_bl{2}{:}); % Preposition stat_tfr{2} = ft_freqstatistics(cfg, tot_tfr2_bl{3}{:}, tot_tfr2_bl{4}{:}); % Semantics stat_tfr{3} = ft_freqstatistics(cfg, tot_tfr2_bl{5}{:}, tot_tfr2_bl{6}{:}); % Morphosyntax This is the plotting code. Again, it is virtually the same for the ERPs except the non-stats configurations would be what makes sense for ERPs. % Anomaly vs Control TFR stats multiplot cfg = []; cfg.xlim = [-0.2 1]; cfg.zlim = [-3 3]; % proportion from baseline cfg.layout = [max_dir '/quickcap64.mat']; cfg.maskparameter = 'mask'; cfg.parameter = 'stat'; cfg.maskalpha = 0.025; ft_multiplotTFR(cfg, stat_tfr{1}); title('Preposition'); ft_multiplotTFR(cfg, stat_tfr{3}); title('Semantic'); ft_multiplotTFR(cfg, stat_tfr{5}); title('Morphosyntactic'); 2. The second question is about analyzing baselined vs unbaselined data. I've seen in the tutorials that there is a somewhat different method for analyzing trial vs baseline period. However, what I've done instead (for both ERP and TFR), is use the same within-subjects statistics as with anomaly vs control, except with the inputs being baselined vs unbaselined ERPs or TFRs, e.g. Baselined Preposition Anomaly vs Unbaselined Preposition Anomaly, etc. I understand that the proposed method and my method are not testing the same thing exactly, but is this a reasonable way of testing the effect of the baselining anyway? Thanks, Max -- Max Cantor Graduate Student Cognitive Neuroscience of Language Lab University of Colorado Boulder -------------- next part -------------- An HTML attachment was scrubbed... URL: From laetitia.lalla at inserm.fr Sun Apr 10 18:36:56 2016 From: laetitia.lalla at inserm.fr (laetitia.lalla at inserm.fr) Date: Sun, 10 Apr 2016 18:36:56 +0200 Subject: [FieldTrip] Implementation of statistical testing for imaginary coherence differences in FieldTrip In-Reply-To: <815A9820E75FBC4F96B7CD3A8089D11C378AE4DA@exprd04.hosting.ru.nl> References: <2595287eebb0aeacfe5761a9de10de24@inserm.fr> <68a5ba763224075e6d9ec9aa7684221a@inserm.fr>, <815A9820E75FBC4F96B7CD3A8089D11C378AE3E0@exprd04.hosting.ru.nl>, <815A9820E75FBC4F96B7CD3A8089D11C378AE4DA@exprd04.hosting.ru.nl> Message-ID: Dear FieldTrip community, I'm a PhD student in Marseille studying LFPs of freely-moving rats from 2 different regions of the brain. Right now, I'm looking at the imaginary part of the coherency, and I'm interested in the difference in iCoh between 2 conditions (trial and baseline). I searched the old FieldTrip emails and I found this conversation about the imaginary part of the coherency and its statistical testing : http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006402.html If I understood correctly, and based on what Jörn M. Horschig and Eric Maris wrote in April 2013, there was no straightforward implementation of the statistical testing of the differences in the imaginary coherence (between 2 conditions) in FieldTrip at that time. (Jörn wrote "You could have a look at Guido Nolte's paper on imaginary coherence and look it up in the methods section how he is computing it" and Eric wrote : "For a single-subject study, you would have to write your own statfun"). Is this still the case ? Or maybe this is more straightforward now (maybe with new Fieldtrip functions) ? if not, has anyone already tried some similar testing with Fieldtrip or just with Matlab ? Thank you very much for all the help you're providing! Best, Laetitia -------------- next part -------------- An HTML attachment was scrubbed... URL: From gina.joue at univr.it Mon Apr 11 14:37:54 2016 From: gina.joue at univr.it (gj) Date: Mon, 11 Apr 2016 14:37:54 +0200 Subject: [FieldTrip] ft_source2sparse usage for EEG data In-Reply-To: References: Message-ID: <570B9AA2.9050000@univr.it> Hi, Sorry for bumping this message about exceeding the max array size when trying to do a whole brain network analysis with ft_connectivityanalysis, but I am at a loss....Any help (even generally related to FieldTrip connectivity analysis tutorials/scripts specifically for EEG data) very much appreciated! Thanks! Gina From jan.schoffelen at donders.ru.nl Mon Apr 11 15:15:16 2016 From: jan.schoffelen at donders.ru.nl (Schoffelen, J.M. (Jan Mathijs)) Date: Mon, 11 Apr 2016 13:15:16 +0000 Subject: [FieldTrip] ft_source2sparse usage for EEG data References: Message-ID: <096A2A53-E33F-491C-B90F-FBF48172F10B@donders.ru.nl> Hi Gina, A dimensionality of 92232 ( ^ 2) suggests that you have 28 times the number of inside dipoles. I suspect a interaction between FieldTrip’s (perhaps occassionally sloppy) internal data bookkeeping and your specification of the input data/cfg. Where does this factor of 28 come from? Best, Jan-Mathijs > On 11 Apr 2016, at 14:37, gj wrote: > > Hi, > > Sorry for bumping this message about exceeding the max array size when trying to do a whole brain network analysis with ft_connectivityanalysis, but I am at a loss....Any help (even generally related to FieldTrip connectivity analysis tutorials/scripts specifically for EEG data) very much appreciated! > > Thanks! > Gina > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip From assaf.harel at wright.edu Mon Apr 11 15:31:32 2016 From: assaf.harel at wright.edu (Harel, Assaf) Date: Mon, 11 Apr 2016 13:31:32 +0000 Subject: [FieldTrip] Postdoc Position in Human Neuroscience and Visual Cognition Lab Wright State University Message-ID: Human Neuroscience and Visual Cognition Lab Department of Psychology Wright State University A post-doc position is now available at the Human Neuroscience and Visual Cognition Lab at the Department of Psychology, Wright State University. The lab is headed by Dr. Assaf Harel and investigates high-level vision and its neural substrates. We are particularly interested in how visual recognition occurs in real-world settings and adopt a neuroergonomic approach to study the applied aspects of high-level vision. For this purpose, we employ a diversity of cognitive neuroscience methods, including EEG, fMRI, psychophysics, and eye tracking. Research topics include, but are not limited to the following areas: visual expertise, object and scene recognition, categorization and perceptual learning. The position is fully funded for two years. The successful candidate will hold a PhD in Cognitive Neuroscience, Cognitive Psychology, Neurobiology, Computer Science, or any other related discipline by the start date of the position. Strong background and familiarity with fMRI or EEG research is required. Experience in computer programming, especially with Matlab is highly encouraged and will be considered a strong advantage. For more information on this position contact Dr. Assaf Harel: assaf.harel at wright.edu. Applicants should visit the following link to upload CV, statement of research, and three letters of reference: https://jobs.wright.edu/postings/8517 The Department of Psychology is housed in the College of Science and Mathematics, offers a Ph.D. in Human Factors and Industrial/ Organizational Psychology, and has 3 undergraduate concentration areas: (1) Cognition and Perception, (2) Industrial/ Organizational, and (3) Behavioral Neuroscience. Wright State University was recently ranked among the "Best in the Midwest" universities by The Princeton Review, listed among 260 Best National Universities in the annual "America's Best Colleges" rankings by U.S. News and World Report, and ranked fourth nationally among universities with limited numbers of doctoral programs in the Faculty Scholarly Productivity Index. Wright State University is an Equal Opportunity/Affirmative Action Employer. -------------- next part -------------- An HTML attachment was scrubbed... URL: From elinicolaisen at gmail.com Mon Apr 11 16:21:52 2016 From: elinicolaisen at gmail.com (Eliana Nicolaisen) Date: Mon, 11 Apr 2016 11:21:52 -0300 Subject: [FieldTrip] Grand average with deleted channels Message-ID: Dear all, I'm trying to make an ERP grand average using version 20150301. In some subjects I deleted bad channels. Those channels were replaced for NaNs. When I make the grand average using ft_timelockaverage, the grand average is composed only for the common channels across subjects. In other words, in channels deleated at least in one subject the grand average is NaN. This is because ft_timelockanalysis in this version calculates the average making a sum and dividng into degrees of freedom: *grandavg.avg = reshape(sum(avgmat, 1), datsiz)./ResultDOF; * (in line 187 of revision '$Id: ft_timelockgrandaverage.m 10194 2015-02-11 09:08:16Z roboos $') However, I tried version 20121014 that my colleague uses. In this version ft_timelockedanalysis makes a mean: *ResultGrandavg = mean(avgmat, 1);* (in line 183 of revision '$Id: ft_timelockgrandaverage.m 6750 2012-10-13 15:07:32Z roboos $') In the version 20121014 is easy to make a correction that calculates a grand average taking into account NaNs (just changing mean for nanmean). However, in version 20150301 making a similar correction seems more complicated. Question 1: Why version 20150301 calculates average using sum and division instead of using nanmean? Question 2: Do someone have a suggestion about how to change version 20150301? Any comment would be greatly appreciated. Kind regards, Eliana Nicolaisen -------------- next part -------------- An HTML attachment was scrubbed... URL: From gina.joue at univr.it Tue Apr 12 10:41:19 2016 From: gina.joue at univr.it (gj) Date: Tue, 12 Apr 2016 10:41:19 +0200 Subject: [FieldTrip] ft_source2sparse usage for EEG data In-Reply-To: <570B9AA2.9050000@univr.it> References: <570B9AA2.9050000@univr.it> Message-ID: <570CB4AF.6030401@univr.it> Thank you for your help, Jan Mathijs! These are all the related steps I did leading up to the ft_source2sparse call, in case. My input EEG data to FieldTrip are 2 seconds of passive visual stimulation, preprocessed and averaged across all trials per condition per subject in another software. Thank you! g ------------- begin snippet -------------- cfg = []; cfg.method = 'mtmfft'; cfg.output = 'fourier'; cfg.keeptrials = 'yes'; cfg.tapsmofrq = 2; cfg.foi = 12; fft = ft_freqanalysis(cfg, data); cfg = []; cfg.output = {'brain','skull','scalp'}; mri_seg = ft_volumesegment(cfg, mri); % mri from standard_mri.mat (mm) cfg=[]; cfg.tissue={'brain','skull','scalp'}; cfg.numvertices = [3000 1600 800]; mesh_hd=ft_prepare_mesh(cfg,mri_seg); cfg = []; cfg.method = 'bemcp'; headmodel = ft_prepare_headmodel(cfg, mesh_hd); cfg = []; cfg.grid.warpmni = 'yes'; cfg.grid.template = template_grid; % standard_sourcemodel3d10mm.mat cfg.grid.nonlinear = 'yes'; cfg.mri = mri; sourcemodel = ft_prepare_sourcemodel(cfg); cfg = []; cfg.elec = elecR; % elec realigned to standard_bem.mat cfg.headmodel = headmodel; % output from ft_prepare_headmodel cfg.grid = sourcemodel; % output from ft_prepare_sourcemodel lf = ft_prepare_leadfield(cfg); cfg = []; cfg.frequency = fft.freq; cfg.elec = elecR; cfg.method = 'eloreta'; cfg.grid = lf; cfg.vol = vol; % from standard_bem.mat cfg.keeptrials = 'yes'; %cfg.rawtrial = 'yes'; source = ft_sourceanalysis(cfg, fft); cfg = []; cfg.projectmom = 'yes'; source_proj = ft_sourcedescriptives(cfg,source); ------------- end snippet -------------- From ronny.ibrahim at mq.edu.au Tue Apr 12 11:44:44 2016 From: ronny.ibrahim at mq.edu.au (Ronny Ibrahim) Date: Tue, 12 Apr 2016 09:44:44 +0000 Subject: [FieldTrip] Averaging 4D spatio-temporospectral data (trials x channels x frequencies x time) Message-ID: Dear Fellow fieldtrip users, I was wondering whether there is any function which let's me to average my 4D (trials x channels x frequencies x time) time-frequency structure along the trials dimension. I have tried to look into ft_freqgrandaverage function but it won't let me do it. I had set the keeptrials configuration to 'yes' with the aim of representing my data in the relative percentage change format by using the ft_freqbaseline to represent my data in the 'relchange' (percent change format) in which I would like to average. Many thank's in advance for your kind help. Kind Regards, Ronny -------------- next part -------------- An HTML attachment was scrubbed... URL: From maity_winky at yahoo.es Tue Apr 12 13:43:45 2016 From: maity_winky at yahoo.es (=?UTF-8?Q?Mait=C3=A9_Crespo_Garc=C3=ADa?=) Date: Tue, 12 Apr 2016 11:43:45 +0000 (UTC) Subject: [FieldTrip] Averaging 4D spatio-temporospectral data (trials x channels x frequencies x time) In-Reply-To: References: Message-ID: <24058211.2420001.1460461425906.JavaMail.yahoo@mail.yahoo.com> Hi Ronny, try the ft_freqdescriptives. In this tutorial  (http://www.fieldtriptoolbox.org/tutorial/cluster_permutation_freq) it says you can do it. Best,Maite cfg = []; freqFIC_planar_cmb = ft_freqdescriptives(cfg, freqFIC_planar_cmb); El Martes 12 de abril de 2016 12:12, Ronny Ibrahim escribió: Dear Fellow fieldtrip users,I was wondering whether there is any function which let's me to average my  4D (trials x channels x frequencies x time) time-frequency structure along the trials dimension. I have tried to look into ft_freqgrandaverage function but it won't let me do it. I had set the keeptrials configuration to 'yes' with the aim of representing my data in the relative percentage change format by using the ft_freqbaseline to represent my data in the 'relchange' (percent change format) in which I would like to average. Many thank's in advance for your kind help. Kind Regards, Ronny   _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From zsuzsanna.nemecz at gmail.com Wed Apr 13 14:02:08 2016 From: zsuzsanna.nemecz at gmail.com (Zsuzsanna Nemecz) Date: Wed, 13 Apr 2016 14:02:08 +0200 Subject: [FieldTrip] FEM: Missing SIMBIO toolbox Message-ID: Hi, I think the Simbio toolbox is missing in fieldtrip-20160407 and -20160412. I tried generating a FEM volume conduction model and got the following error message in Matlab: Error using ft_hastoolbox (line 485) the SIMBIO toolbox is not installed, see https://www.mrt.uni-jena.de/simbio/index.php/Main_Page I checked in the filedtrip/external directory and the Simbio folder was indeed missing. I solved the problem by downloading an older version ( 2016 March 19th), but I thought it's worth posting anyway for your information. Best Zsuzsanna -------------- next part -------------- An HTML attachment was scrubbed... URL: From r.thomas at nin.knaw.nl Wed Apr 13 16:25:51 2016 From: r.thomas at nin.knaw.nl (Rajat Thomas) Date: Wed, 13 Apr 2016 14:25:51 +0000 Subject: [FieldTrip] Simbio works with ft_volumereslice but leadfield In-Reply-To: References: Message-ID: <1460557552027.85876@nin.knaw.nl> Dear all, Last week I asked for help with Simbio and after following the suggestion of volume reslicing magically the simbio based headmodel was created. But my leadfield calculations are taking way too long. It is a 128^3 grid and am running it on my desktop. (2.4 GHz, plenty of memory 32GB) Could anyone give me a rough ball park on how long it should take to create a leadfield? Thank you. Rajat Rajat Mani Thomas Social Brain Lab Netherlands Institute for Neuroscience Amsterdam ________________________________________ From: fieldtrip-bounces at science.ru.nl on behalf of fieldtrip-request at science.ru.nl Sent: 08 April 2016 12:00 To: fieldtrip at science.ru.nl Subject: fieldtrip Digest, Vol 65, Issue 7 Send fieldtrip mailing list submissions to fieldtrip at science.ru.nl To subscribe or unsubscribe via the World Wide Web, visit http://mailman.science.ru.nl/mailman/listinfo/fieldtrip or, via email, send a message with subject or body 'help' to fieldtrip-request at science.ru.nl You can reach the person managing the list at fieldtrip-owner at science.ru.nl When replying, please edit your Subject line so it is more specific than "Re: Contents of fieldtrip digest..." Today's Topics: 1. Re: FEM using Simbio (Johannes Vorwerk) 2. Re: FEM using Simbio (Cristiano Micheli) 3. Dipole fitting (Giovanni Pellegrino) 4. Birmingham-Illinois BRIDGE Fellowships (Ole Jensen) 5. Using FieldTrip to analyse LFP recordings in rat (laetitia.lalla at inserm.fr) ---------------------------------------------------------------------- Message: 1 Date: Thu, 7 Apr 2016 14:25:42 +0200 From: Johannes Vorwerk To: FieldTrip discussion list Subject: Re: [FieldTrip] FEM using Simbio Message-ID: <435735E3-7D87-4DD6-A2C1-E2BBFBBF4B44 at googlemail.com> Content-Type: text/plain; charset="utf-8" Hi, this question was already answered in this thread http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html If ft_volumereslice is not applied before the mesh generation, the afterwards applied transformation might flip the directions of the mesh, leading to the described error. Best, Johannes > Am 06.04.2016 um 16:03 schrieb Carsten Wolters : > > Dear Rajat, > > the element-node cards of SimBio-NeuroFEM need to follow certain orientations (see www.simbio.de ). > > If you do not want to struggle with meshing/ordering, use the SimBio-VGRID mesher > http://vgrid.simbio.de/ > that follows the required ordering of nodes. You might use this mesher to produce 1mm geometry-adapted FEM meshes > that show good overall performance, see > http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf > and > http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf > (latter was just accepted by NeuroImage). > > Best regards > Carsten > > Am 06.04.2016 um 15:10 schrieb Rajat Thomas: >> Dear all, >> >> Has anyone used the FEM approach to Headmodels using Simbio recently? >> >> If so, I get this error: >> "Elements have wrong orientation or are degenerated" >> >> Any ideas? >> >> cfg = []; >> cfg.method ='simbio'; >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows mesh.tissyelabel >> vol = ft_prepare_headmodel(cfg, mesh); >> >> And; >> ? >> disp(mesh) >> hex: [545883x8 double] >> pnt: [569722x3 double] >> labels: [545883x1 double] >> tissue: [545883x1 double] >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >> unit: 'mm' >> cfg: [1x1 struct] >> >> Any help would be highly appreciated. >> >> Rajat >> >> >> >> >> >> >> Rajat Mani Thomas >> Social Brain Lab >> Netherlands Institute for Neuroscience >> Amsterdam >> >> >> _______________________________________________ >> 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 -------------- next part -------------- An HTML attachment was scrubbed... URL: ------------------------------ Message: 2 Date: Thu, 7 Apr 2016 17:36:37 +0200 From: Cristiano Micheli To: FieldTrip discussion list Subject: Re: [FieldTrip] FEM using Simbio Message-ID: Content-Type: text/plain; charset="utf-8" Hi Rajat My guess is that the orientations of your hexahedrons are not correct. According to a low-level file's internal rules, elements' orientations have to abide strict rules (not sure what exactly the contraints are in this case though...). I had same problems when for example the triangular boundaries used to define the 3d hexahedral mesh were not topologically correct, to start with. Admittedly this approach requires a lot of technical expertise. Can I ask you what do you need a FEM model for? Regards Cris Micheli On Wed, Apr 6, 2016 at 3:10 PM, Rajat Thomas wrote: > Dear all, > > > Has anyone used the FEM approach to Headmodels using Simbio recently? > > > If so, I get this error: > "Elements have wrong orientation or are degenerated" > > Any ideas? > > cfg = []; > > cfg.method ='simbio'; > > cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows > mesh.tissyelabel > > vol = ft_prepare_headmodel(cfg, mesh); > > > And; > > ? > disp(mesh) > hex: [545883x8 double] > pnt: [569722x3 double] > labels: [545883x1 double] > tissue: [545883x1 double] > tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} > unit: 'mm' > cfg: [1x1 struct] > > > Any help would be highly appreciated. > > Rajat > > > > > > > Rajat Mani Thomas > Social Brain Lab > Netherlands Institute for Neuroscience > Amsterdam > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: ------------------------------ Message: 3 Date: Thu, 7 Apr 2016 15:02:05 -0400 From: Giovanni Pellegrino To: fieldtrip at science.ru.nl Subject: [FieldTrip] Dipole fitting Message-ID: Content-Type: text/plain; charset="utf-8" Dear Fieldtrippers, Do you know if the FieldTrip Dipole Fitting has been compared to the CTF, Elekta, BESA or Curry? Are you aware of any study on this topic? Thanks in advance for your help Giovanni -- Giovanni Pellegrino, MD Multimodal Functional Imaging Laboratory Montreal Neurological Institute, McGill University Address: 332 Duff Medical Building, 3775 rue University, Montreal, QC, H3A 2B4, Canada Phone: (514) 398?1678 Fax: (514) 398?7461 Email: giovannipellegrino at gmail.com, giovanni.pellegrino2 at mcgill.ca Homepage: http://www.bic.mni.mcgill.ca/ResearchLabsMFIL/PeopleGiovanni -------------- next part -------------- An HTML attachment was scrubbed... URL: ------------------------------ Message: 4 Date: Fri, 8 Apr 2016 09:23:46 +0200 From: Ole Jensen To: fieldtrip at science.ru.nl Subject: [FieldTrip] Birmingham-Illinois BRIDGE Fellowships Message-ID: <57075C82.8030309 at donders.ru.nl> Content-Type: text/plain; charset=utf-8; format=flowed Dear all, I would like to point you to a set of Birmingham-Illinois BRIDGE Fellowships providing some exciting research and career prospects: http://www.birminghamillinoisbridge.org/index.php/fellows/ In particular the areas 'Cognition and Ageing' and 'Brain Trauma' could be relevant for candidates with EEG/MEG expertise. All the best, Ole -- Prof. dr. Ole Jensen http://www.neuosc.com ------------------------------ Message: 5 Date: Fri, 08 Apr 2016 10:27:58 +0200 From: laetitia.lalla at inserm.fr To: fieldtrip at science.ru.nl Subject: [FieldTrip] Using FieldTrip to analyse LFP recordings in rat Message-ID: <628babdc107aebd4cc7588ea87ce5ea6 at inserm.fr> Content-Type: text/plain; charset="utf-8" Hello everyone, my name is Laetitia and I'm a Phd student in Marseille (France). I'm doing in-vivo recording in freely-moving rats : I implant them with 2 electrodes deep into 2 different regions of the brain. I'm studying the Local Field Potentials and I want to use FieldTrip to analyse the data. To simplify : - I have 2 rats. - Each rat did 20 sessions of the task (on 20 different days). - Each session consists of 20 trials of condition 1 and 20 trials of condition 2. I have 2 questions. 1) I have the feeling it would be meaningless to do "source reconstruction" because my electrodes are already deep inside my "source" and the LFP I am recording is very local. (My electrodes have 32 channels separated by 20-200 ?m. The LFP is very very similar across all the channels, so I averaged over the 32 channels to have one signal for each region.) However, I see that 2 different functions exist for the statistics : FT_FREQSTATISTICS AND FT_SOURCESTATISTICS. So far, I've been using ft_freqstatistics but I encounter some issues (for exemple, doing monte-carlo permutation test to assess the imaginary coherence). I thought of computing it manually, but I'm thinking that maybe more stuff are implemented in ft_sourcestatisctics ? ? Are these 2 functions fundamentally different or do they call the same sub-fonctions (and my problem has actually nothing to do with that) ? 2) I'm a bit confused with the vocabulary from EEG and MEG studies (I'm not used to it yet...). From what I understood, in human studies, you can do comparison for a single subject (across trials) or across subjects. But I have 3 levels of comparisons in my design : - WITHIN A SESSION, I WANT TO COMPARE ACROSS TRIALS (the 20 trials of condition 1 VS the 20 trials of condition 2). - WITHIN A RAT, I WANT TO COMPARE ACROSS SESSIONS (between the 2 conditions) - then - in the very end - ACROSS RATS. But I have only 2 rats so far, so I will deal with this later. I'm a bit confused when reading the tutorials and the mailing list, especially when it comes to the statistics... For example : this is from an email from 2013 by Eric Maris about "Nonparametric statistical testing of phase coherence" (http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006401.html) "To compare coherence between conditions across subjects (instead of trials), you need a different statfun: depsamplesT (for a within-subjects design; subjects have participated in all conditions) or indepsamplesT (for a between-subjects design; subjects have participated in only one condition)." ? If I want to compare across sessions (for a same rat), can I actually consider that my different sessions are "subjects"? And then compare coherence "across subjects" would be doing it "across sessions" ? And I would be in a "within-subject design" since my sessions involve the 2 conditions every time ? I realise that it may be very confusing... I hope you will understand my problem ! And if anyone already applied fieldtrip functions to do statistics on a different framework that the usual EEG/MEG, please let me know ! Thanks a lot, Laetitia Lalla PhD Student in Neuroscience INMED, Marseille, France -------------- next part -------------- An HTML attachment was scrubbed... URL: ------------------------------ _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl http://mailman.science.ru.nl/mailman/listinfo/fieldtrip End of fieldtrip Digest, Vol 65, Issue 7 **************************************** From icelandhouse at gmail.com Wed Apr 13 19:35:17 2016 From: icelandhouse at gmail.com (Maris Skujevskis) Date: Wed, 13 Apr 2016 19:35:17 +0200 Subject: [FieldTrip] Correlated sources: LCMV, MNE, dipole fitting Message-ID: Dear Fieldtrip community, I am trying to localize neural sources of the primary somatosensory response using the LCMV beamformer on an ERP dataset. In my experiment the subjects are stimulated bilaterally - both the left and the right index finger simultaneously receive an identical tactile half a second stimulus. The LCMV beamformer fails to detect two distinct early cortical sources (left and right S1), instead I get a single rather central source (along the lines of Van Veen et al., 1997, Fig.2(f) ). My question is: -is it expected that MNE fares better than LCMV when two sources are correlated? (i.e. would MNE be more likely to detect both right and left S1)? -or would dipole fitting be the preferred method for obtaining an accurate estimate of left/right S1 location? Any suggestions will be appreciated! Thanks! Maris On Wed, Apr 13, 2016 at 12:00 PM, wrote: > Send fieldtrip mailing list submissions to > fieldtrip at science.ru.nl > > To subscribe or unsubscribe via the World Wide Web, visit > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > or, via email, send a message with subject or body 'help' to > fieldtrip-request at science.ru.nl > > You can reach the person managing the list at > fieldtrip-owner at science.ru.nl > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of fieldtrip digest..." > > > Today's Topics: > > 1. Re: Averaging 4D spatio-temporospectral data (trials x > channels x frequencies x time) (Mait? Crespo Garc?a) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Tue, 12 Apr 2016 11:43:45 +0000 (UTC) > From: Mait? Crespo Garc?a > To: FieldTrip discussion list > Subject: Re: [FieldTrip] Averaging 4D spatio-temporospectral data > (trials x channels x frequencies x time) > Message-ID: > <24058211.2420001.1460461425906.JavaMail.yahoo at mail.yahoo.com> > Content-Type: text/plain; charset="utf-8" > > Hi Ronny, > try the ft_freqdescriptives. In this tutorial? ( > http://www.fieldtriptoolbox.org/tutorial/cluster_permutation_freq) it > says you can do it. > Best,Maite > > cfg = []; > freqFIC_planar_cmb = ft_freqdescriptives(cfg, freqFIC_planar_cmb); > > > > El Martes 12 de abril de 2016 12:12, Ronny Ibrahim < > ronny.ibrahim at mq.edu.au> escribi?: > > > Dear Fellow > fieldtrip users,I was wondering whether there is any function which let's > me to?average my ?4D (trials?x channels x frequencies x time) > time-frequency?structure along the trials dimension. I have tried to look > into ft_freqgrandaverage function but it won't let me do it. I had set?the > keeptrials configuration to 'yes' with the aim of representing my data in > the relative percentage change format by using the?ft_freqbaseline to > represent my data in the 'relchange' (percent change format) in?which I > would like to average. > Many thank's in advance for your kind help. > Kind Regards, > Ronny?? > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: < > http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160412/8f7f5099/attachment-0001.html > > > > ------------------------------ > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > End of fieldtrip Digest, Vol 65, Issue 11 > ***************************************** > -------------- next part -------------- An HTML attachment was scrubbed... URL: From gina.joue at univr.it Wed Apr 13 20:13:44 2016 From: gina.joue at univr.it (gj) Date: Wed, 13 Apr 2016 20:13:44 +0200 Subject: [FieldTrip] source reconstruction + noise bias in center of head Message-ID: <570E8C58.6080709@univr.it> Hi FieldTrip community, I tried doing source analysis of EEG data using method "eloreta." For some participants, the sources found were where we expected, but for some participants, the strongest power is in the center of the brain (and some on the skull...). What can I do in this case/what should I doublecheck? We don't have structural MRIs for each participant but coregistered the electrodes to a template brain. I actually tried using DICS to do the source analysis in order to estimate the noise, but 1. there is high power in almost the entire brain 2. the noise estimated is all 0's or NAs. Thanks in advance for any help! Gina From julian.keil at gmail.com Thu Apr 14 09:48:05 2016 From: julian.keil at gmail.com (Julian Keil) Date: Thu, 14 Apr 2016 09:48:05 +0200 Subject: [FieldTrip] Simbio works with ft_volumereslice but leadfield In-Reply-To: <1460557552027.85876@nin.knaw.nl> References: <1460557552027.85876@nin.knaw.nl> Message-ID: Hi Rajat, what do you mean by "way too long"? Have you tried setting the resolution of the mesh in the call to ft_prepare_mesh prior to ft_prepare_headmodel? Setting it to cfg.resolution = 5 (which changes the mesh resolution from the default 1mm to 5mm) greatly sped up the mesh preparation and leadfield computation in my case. Please beware however that I use a rather old FT-Version as I don't have a current Matlab Version, so the functionality might have changed. Good Luck, Julian ******************** Dr. Julian Keil AG Multisensorische Integration Psychiatrische Universitätsklinik der Charité im St. Hedwig-Krankenhaus Große Hamburger Straße 5-11, Haus 2 10115 Berlin Telefon: +49-30-2311-1879 Fax: +49-30-2311-2209 http://psy-ccm.charite.de/forschung/bildgebung/ag_multisensorische_integration Am 13.04.2016 um 16:25 schrieb Rajat Thomas: > Dear all, > > Last week I asked for help with Simbio and after following the suggestion of volume reslicing magically the > simbio based headmodel was created. > > But my leadfield calculations are taking way too long. > It is a 128^3 grid and am running it on my desktop. (2.4 GHz, plenty of memory 32GB) > > Could anyone give me a rough ball park on how long it should take to create a leadfield? > > Thank you. > Rajat > > > > Rajat Mani Thomas > Social Brain Lab > Netherlands Institute for Neuroscience > Amsterdam > > ________________________________________ > From: fieldtrip-bounces at science.ru.nl on behalf of fieldtrip-request at science.ru.nl > Sent: 08 April 2016 12:00 > To: fieldtrip at science.ru.nl > Subject: fieldtrip Digest, Vol 65, Issue 7 > > Send fieldtrip mailing list submissions to > fieldtrip at science.ru.nl > > To subscribe or unsubscribe via the World Wide Web, visit > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > or, via email, send a message with subject or body 'help' to > fieldtrip-request at science.ru.nl > > You can reach the person managing the list at > fieldtrip-owner at science.ru.nl > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of fieldtrip digest..." > > > Today's Topics: > > 1. Re: FEM using Simbio (Johannes Vorwerk) > 2. Re: FEM using Simbio (Cristiano Micheli) > 3. Dipole fitting (Giovanni Pellegrino) > 4. Birmingham-Illinois BRIDGE Fellowships (Ole Jensen) > 5. Using FieldTrip to analyse LFP recordings in rat > (laetitia.lalla at inserm.fr) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Thu, 7 Apr 2016 14:25:42 +0200 > From: Johannes Vorwerk > To: FieldTrip discussion list > Subject: Re: [FieldTrip] FEM using Simbio > Message-ID: <435735E3-7D87-4DD6-A2C1-E2BBFBBF4B44 at googlemail.com> > Content-Type: text/plain; charset="utf-8" > > Hi, > > this question was already answered in this thread > > http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html > > If ft_volumereslice is not applied before the mesh generation, the afterwards applied transformation might flip the directions of the mesh, leading to the described error. > > Best, > Johannes > >> Am 06.04.2016 um 16:03 schrieb Carsten Wolters : >> >> Dear Rajat, >> >> the element-node cards of SimBio-NeuroFEM need to follow certain orientations (see www.simbio.de ). >> >> If you do not want to struggle with meshing/ordering, use the SimBio-VGRID mesher >> http://vgrid.simbio.de/ >> that follows the required ordering of nodes. You might use this mesher to produce 1mm geometry-adapted FEM meshes >> that show good overall performance, see >> http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf >> and >> http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf >> (latter was just accepted by NeuroImage). >> >> Best regards >> Carsten >> >> Am 06.04.2016 um 15:10 schrieb Rajat Thomas: >>> Dear all, >>> >>> Has anyone used the FEM approach to Headmodels using Simbio recently? >>> >>> If so, I get this error: >>> "Elements have wrong orientation or are degenerated" >>> >>> Any ideas? >>> >>> cfg = []; >>> cfg.method ='simbio'; >>> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows mesh.tissyelabel >>> vol = ft_prepare_headmodel(cfg, mesh); >>> >>> And; >>> ? >>> disp(mesh) >>> hex: [545883x8 double] >>> pnt: [569722x3 double] >>> labels: [545883x1 double] >>> tissue: [545883x1 double] >>> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >>> unit: 'mm' >>> cfg: [1x1 struct] >>> >>> Any help would be highly appreciated. >>> >>> Rajat >>> >>> >>> >>> >>> >>> >>> Rajat Mani Thomas >>> Social Brain Lab >>> Netherlands Institute for Neuroscience >>> Amsterdam >>> >>> >>> _______________________________________________ >>> 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 > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > Message: 2 > Date: Thu, 7 Apr 2016 17:36:37 +0200 > From: Cristiano Micheli > To: FieldTrip discussion list > Subject: Re: [FieldTrip] FEM using Simbio > Message-ID: > > Content-Type: text/plain; charset="utf-8" > > Hi Rajat > > My guess is that the orientations of your hexahedrons are not correct. > According to a low-level file's internal rules, elements' orientations have > to abide strict rules (not sure what exactly the contraints are in this > case though...). > I had same problems when for example the triangular boundaries used to > define the 3d hexahedral mesh were not topologically correct, to start with. > Admittedly this approach requires a lot of technical expertise. > Can I ask you what do you need a FEM model for? > > Regards > Cris Micheli > > > > > On Wed, Apr 6, 2016 at 3:10 PM, Rajat Thomas wrote: > >> Dear all, >> >> >> Has anyone used the FEM approach to Headmodels using Simbio recently? >> >> >> If so, I get this error: >> "Elements have wrong orientation or are degenerated" >> >> Any ideas? >> >> cfg = []; >> >> cfg.method ='simbio'; >> >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows >> mesh.tissyelabel >> >> vol = ft_prepare_headmodel(cfg, mesh); >> >> >> And; >> >> ? >> disp(mesh) >> hex: [545883x8 double] >> pnt: [569722x3 double] >> labels: [545883x1 double] >> tissue: [545883x1 double] >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >> unit: 'mm' >> cfg: [1x1 struct] >> >> >> Any help would be highly appreciated. >> >> Rajat >> >> >> >> >> >> >> Rajat Mani Thomas >> Social Brain Lab >> Netherlands Institute for Neuroscience >> Amsterdam >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > Message: 3 > Date: Thu, 7 Apr 2016 15:02:05 -0400 > From: Giovanni Pellegrino > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Dipole fitting > Message-ID: > > Content-Type: text/plain; charset="utf-8" > > Dear Fieldtrippers, > > Do you know if the FieldTrip Dipole Fitting has been compared to the CTF, > Elekta, BESA or Curry? Are you aware of any study on this topic? > > Thanks in advance for your help > > Giovanni > > -- > Giovanni Pellegrino, MD > Multimodal Functional Imaging Laboratory > Montreal Neurological Institute, McGill University > Address: 332 Duff Medical Building, 3775 rue University, Montreal, QC, H3A > 2B4, Canada > Phone: (514) 398?1678 > Fax: (514) 398?7461 > Email: giovannipellegrino at gmail.com, giovanni.pellegrino2 at mcgill.ca > Homepage: http://www.bic.mni.mcgill.ca/ResearchLabsMFIL/PeopleGiovanni > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > Message: 4 > Date: Fri, 8 Apr 2016 09:23:46 +0200 > From: Ole Jensen > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Birmingham-Illinois BRIDGE Fellowships > Message-ID: <57075C82.8030309 at donders.ru.nl> > Content-Type: text/plain; charset=utf-8; format=flowed > > Dear all, > > I would like to point you to a set of Birmingham-Illinois BRIDGE > Fellowships providing some exciting research and career prospects: > http://www.birminghamillinoisbridge.org/index.php/fellows/ > > In particular the areas 'Cognition and Ageing' and 'Brain Trauma' could > be relevant for candidates with EEG/MEG expertise. > > All the best, > > Ole > > -- > Prof. dr. Ole Jensen > http://www.neuosc.com > > > > ------------------------------ > > Message: 5 > Date: Fri, 08 Apr 2016 10:27:58 +0200 > From: laetitia.lalla at inserm.fr > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Using FieldTrip to analyse LFP recordings in rat > Message-ID: <628babdc107aebd4cc7588ea87ce5ea6 at inserm.fr> > Content-Type: text/plain; charset="utf-8" > > > > Hello everyone, > > my name is Laetitia and I'm a Phd student in Marseille (France). I'm > doing in-vivo recording in freely-moving rats : I implant them with 2 > electrodes deep into 2 different regions of the brain. I'm studying the > Local Field Potentials and I want to use FieldTrip to analyse the data. > > To simplify : > > - I have 2 rats. > > - Each rat did 20 sessions of the task (on 20 different days). > > - Each session consists of 20 trials of condition 1 and 20 trials of > condition 2. > > I have 2 questions. > > 1) I have the feeling it would be meaningless to do "source > reconstruction" because my electrodes are already deep inside my > "source" and the LFP I am recording is very local. (My electrodes have > 32 channels separated by 20-200 ?m. The LFP is very very similar across > all the channels, so I averaged over the 32 channels to have one signal > for each region.) > > However, I see that 2 different functions exist for the statistics : > FT_FREQSTATISTICS AND FT_SOURCESTATISTICS. So far, I've been using > ft_freqstatistics but I encounter some issues (for exemple, doing > monte-carlo permutation test to assess the imaginary coherence). I > thought of computing it manually, but I'm thinking that maybe more stuff > are implemented in ft_sourcestatisctics ? > > ? Are these 2 functions fundamentally different or do they call the same > sub-fonctions (and my problem has actually nothing to do with that) ? > > 2) I'm a bit confused with the vocabulary from EEG and MEG studies (I'm > not used to it yet...). From what I understood, in human studies, you > can do comparison for a single subject (across trials) or across > subjects. But I have 3 levels of comparisons in my design : > > - WITHIN A SESSION, I WANT TO COMPARE ACROSS TRIALS (the 20 trials of > condition 1 VS the 20 trials of condition 2). > > - WITHIN A RAT, I WANT TO COMPARE ACROSS SESSIONS (between the 2 > conditions) > > - then - in the very end - ACROSS RATS. But I have only 2 rats so far, > so I will deal with this later. > > I'm a bit confused when reading the tutorials and the mailing list, > especially when it comes to the statistics... For example : this is from > an email from 2013 by Eric Maris about "Nonparametric statistical > testing of phase coherence" > (http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006401.html) > "To compare coherence between conditions across subjects (instead of > trials), you need a different statfun: depsamplesT (for a > within-subjects design; subjects have participated in all conditions) or > indepsamplesT (for a between-subjects design; subjects have participated > in only one condition)." > > ? If I want to compare across sessions (for a same rat), can I actually > consider that my different sessions are "subjects"? And then compare > coherence "across subjects" would be doing it "across sessions" ? And I > would be in a "within-subject design" since my sessions involve the 2 > conditions every time ? > > I realise that it may be very confusing... I hope you will understand my > problem ! > > And if anyone already applied fieldtrip functions to do statistics on a > different framework that the usual EEG/MEG, please let me know ! > > Thanks a lot, > > Laetitia Lalla > > PhD Student in Neuroscience > > INMED, Marseille, France > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > End of fieldtrip Digest, Vol 65, Issue 7 > **************************************** > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 495 bytes Desc: Message signed with OpenPGP using GPGMail URL: From deb.desideri at gmail.com Thu Apr 14 10:21:08 2016 From: deb.desideri at gmail.com (Debora Desideri) Date: Thu, 14 Apr 2016 10:21:08 +0200 Subject: [FieldTrip] Simbio works with ft_volumereslice but leadfield In-Reply-To: <1460557552027.85876@nin.knaw.nl> References: <1460557552027.85876@nin.knaw.nl> Message-ID: Dear Rajat, I am also using Simbio and I usually run the leadfield calculation overnight since it takes approximatelly 12-15 hours for 64 EEG channels with a grid of 6 mm resolution ( 2.60 GHz, 32 GB RAM). I don't know whether there is a way to speed the process up. Maybe we just need to be patient, or work on a very powerful machine. Best, Debora On Wed, Apr 13, 2016 at 4:25 PM, Rajat Thomas wrote: > Dear all, > > Last week I asked for help with Simbio and after following the suggestion > of volume reslicing magically the > simbio based headmodel was created. > > But my leadfield calculations are taking way too long. > It is a 128^3 grid and am running it on my desktop. (2.4 GHz, plenty of > memory 32GB) > > Could anyone give me a rough ball park on how long it should take to > create a leadfield? > > Thank you. > Rajat > > > > Rajat Mani Thomas > Social Brain Lab > Netherlands Institute for Neuroscience > Amsterdam > > ________________________________________ > From: fieldtrip-bounces at science.ru.nl > on behalf of fieldtrip-request at science.ru.nl < > fieldtrip-request at science.ru.nl> > Sent: 08 April 2016 12:00 > To: fieldtrip at science.ru.nl > Subject: fieldtrip Digest, Vol 65, Issue 7 > > Send fieldtrip mailing list submissions to > fieldtrip at science.ru.nl > > To subscribe or unsubscribe via the World Wide Web, visit > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > or, via email, send a message with subject or body 'help' to > fieldtrip-request at science.ru.nl > > You can reach the person managing the list at > fieldtrip-owner at science.ru.nl > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of fieldtrip digest..." > > > Today's Topics: > > 1. Re: FEM using Simbio (Johannes Vorwerk) > 2. Re: FEM using Simbio (Cristiano Micheli) > 3. Dipole fitting (Giovanni Pellegrino) > 4. Birmingham-Illinois BRIDGE Fellowships (Ole Jensen) > 5. Using FieldTrip to analyse LFP recordings in rat > (laetitia.lalla at inserm.fr) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Thu, 7 Apr 2016 14:25:42 +0200 > From: Johannes Vorwerk > To: FieldTrip discussion list > Subject: Re: [FieldTrip] FEM using Simbio > Message-ID: <435735E3-7D87-4DD6-A2C1-E2BBFBBF4B44 at googlemail.com> > Content-Type: text/plain; charset="utf-8" > > Hi, > > this question was already answered in this thread > > http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html < > http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html> > > If ft_volumereslice is not applied before the mesh generation, the > afterwards applied transformation might flip the directions of the mesh, > leading to the described error. > > Best, > Johannes > > > Am 06.04.2016 um 16:03 schrieb Carsten Wolters < > carsten.wolters at uni-muenster.de>: > > > > Dear Rajat, > > > > the element-node cards of SimBio-NeuroFEM need to follow certain > orientations (see www.simbio.de ). > > > > If you do not want to struggle with meshing/ordering, use the > SimBio-VGRID mesher > > http://vgrid.simbio.de/ > > that follows the required ordering of nodes. You might use this mesher > to produce 1mm geometry-adapted FEM meshes > > that show good overall performance, see > > > http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf > < > http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf > > > > and > > > http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf > < > http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf > > > > (latter was just accepted by NeuroImage). > > > > Best regards > > Carsten > > > > Am 06.04.2016 um 15:10 schrieb Rajat Thomas: > >> Dear all, > >> > >> Has anyone used the FEM approach to Headmodels using Simbio recently? > >> > >> If so, I get this error: > >> "Elements have wrong orientation or are degenerated" > >> > >> Any ideas? > >> > >> cfg = []; > >> cfg.method ='simbio'; > >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows > mesh.tissyelabel > >> vol = ft_prepare_headmodel(cfg, mesh); > >> > >> And; > >> ? > >> disp(mesh) > >> hex: [545883x8 double] > >> pnt: [569722x3 double] > >> labels: [545883x1 double] > >> tissue: [545883x1 double] > >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} > >> unit: 'mm' > >> cfg: [1x1 struct] > >> > >> Any help would be highly appreciated. > >> > >> Rajat > >> > >> > >> > >> > >> > >> > >> Rajat Mani Thomas > >> Social Brain Lab > >> Netherlands Institute for Neuroscience > >> Amsterdam > >> > >> > >> _______________________________________________ > >> fieldtrip mailing list > >> fieldtrip at donders.ru.nl > >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip < > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip> > > _______________________________________________ > > fieldtrip mailing list > > fieldtrip at donders.ru.nl > > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip < > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip> > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: < > http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160407/2ea995ee/attachment-0001.html > > > > ------------------------------ > > Message: 2 > Date: Thu, 7 Apr 2016 17:36:37 +0200 > From: Cristiano Micheli > To: FieldTrip discussion list > Subject: Re: [FieldTrip] FEM using Simbio > Message-ID: > < > CADW7XCAQONsZ_ujPhkffskZ+j-mnHnAzunS68CdKU6MLSosUPA at mail.gmail.com> > Content-Type: text/plain; charset="utf-8" > > Hi Rajat > > My guess is that the orientations of your hexahedrons are not correct. > According to a low-level file's internal rules, elements' orientations have > to abide strict rules (not sure what exactly the contraints are in this > case though...). > I had same problems when for example the triangular boundaries used to > define the 3d hexahedral mesh were not topologically correct, to start > with. > Admittedly this approach requires a lot of technical expertise. > Can I ask you what do you need a FEM model for? > > Regards > Cris Micheli > > > > > On Wed, Apr 6, 2016 at 3:10 PM, Rajat Thomas wrote: > > > Dear all, > > > > > > Has anyone used the FEM approach to Headmodels using Simbio recently? > > > > > > If so, I get this error: > > "Elements have wrong orientation or are degenerated" > > > > Any ideas? > > > > cfg = []; > > > > cfg.method ='simbio'; > > > > cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows > > mesh.tissyelabel > > > > vol = ft_prepare_headmodel(cfg, mesh); > > > > > > And; > > > > ? > > disp(mesh) > > hex: [545883x8 double] > > pnt: [569722x3 double] > > labels: [545883x1 double] > > tissue: [545883x1 double] > > tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} > > unit: 'mm' > > cfg: [1x1 struct] > > > > > > Any help would be highly appreciated. > > > > Rajat > > > > > > > > > > > > > > Rajat Mani Thomas > > Social Brain Lab > > Netherlands Institute for Neuroscience > > Amsterdam > > > > _______________________________________________ > > fieldtrip mailing list > > fieldtrip at donders.ru.nl > > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: < > http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160407/4adfe55a/attachment-0001.html > > > > ------------------------------ > > Message: 3 > Date: Thu, 7 Apr 2016 15:02:05 -0400 > From: Giovanni Pellegrino > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Dipole fitting > Message-ID: > u8GDw at mail.gmail.com> > Content-Type: text/plain; charset="utf-8" > > Dear Fieldtrippers, > > Do you know if the FieldTrip Dipole Fitting has been compared to the CTF, > Elekta, BESA or Curry? Are you aware of any study on this topic? > > Thanks in advance for your help > > Giovanni > > -- > Giovanni Pellegrino, MD > Multimodal Functional Imaging Laboratory > Montreal Neurological Institute, McGill University > Address: 332 Duff Medical Building, 3775 rue University, Montreal, QC, H3A > 2B4, Canada > Phone: (514) 398?1678 > Fax: (514) 398?7461 > Email: giovannipellegrino at gmail.com, giovanni.pellegrino2 at mcgill.ca > Homepage: http://www.bic.mni.mcgill.ca/ResearchLabsMFIL/PeopleGiovanni > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: < > http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160407/d01144bd/attachment-0001.html > > > > ------------------------------ > > Message: 4 > Date: Fri, 8 Apr 2016 09:23:46 +0200 > From: Ole Jensen > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Birmingham-Illinois BRIDGE Fellowships > Message-ID: <57075C82.8030309 at donders.ru.nl> > Content-Type: text/plain; charset=utf-8; format=flowed > > Dear all, > > I would like to point you to a set of Birmingham-Illinois BRIDGE > Fellowships providing some exciting research and career prospects: > http://www.birminghamillinoisbridge.org/index.php/fellows/ > > In particular the areas 'Cognition and Ageing' and 'Brain Trauma' could > be relevant for candidates with EEG/MEG expertise. > > All the best, > > Ole > > -- > Prof. dr. Ole Jensen > http://www.neuosc.com > > > > ------------------------------ > > Message: 5 > Date: Fri, 08 Apr 2016 10:27:58 +0200 > From: laetitia.lalla at inserm.fr > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Using FieldTrip to analyse LFP recordings in rat > Message-ID: <628babdc107aebd4cc7588ea87ce5ea6 at inserm.fr> > Content-Type: text/plain; charset="utf-8" > > > > Hello everyone, > > my name is Laetitia and I'm a Phd student in Marseille (France). I'm > doing in-vivo recording in freely-moving rats : I implant them with 2 > electrodes deep into 2 different regions of the brain. I'm studying the > Local Field Potentials and I want to use FieldTrip to analyse the data. > > To simplify : > > - I have 2 rats. > > - Each rat did 20 sessions of the task (on 20 different days). > > - Each session consists of 20 trials of condition 1 and 20 trials of > condition 2. > > I have 2 questions. > > 1) I have the feeling it would be meaningless to do "source > reconstruction" because my electrodes are already deep inside my > "source" and the LFP I am recording is very local. (My electrodes have > 32 channels separated by 20-200 ?m. The LFP is very very similar across > all the channels, so I averaged over the 32 channels to have one signal > for each region.) > > However, I see that 2 different functions exist for the statistics : > FT_FREQSTATISTICS AND FT_SOURCESTATISTICS. So far, I've been using > ft_freqstatistics but I encounter some issues (for exemple, doing > monte-carlo permutation test to assess the imaginary coherence). I > thought of computing it manually, but I'm thinking that maybe more stuff > are implemented in ft_sourcestatisctics ? > > ? Are these 2 functions fundamentally different or do they call the same > sub-fonctions (and my problem has actually nothing to do with that) ? > > 2) I'm a bit confused with the vocabulary from EEG and MEG studies (I'm > not used to it yet...). From what I understood, in human studies, you > can do comparison for a single subject (across trials) or across > subjects. But I have 3 levels of comparisons in my design : > > - WITHIN A SESSION, I WANT TO COMPARE ACROSS TRIALS (the 20 trials of > condition 1 VS the 20 trials of condition 2). > > - WITHIN A RAT, I WANT TO COMPARE ACROSS SESSIONS (between the 2 > conditions) > > - then - in the very end - ACROSS RATS. But I have only 2 rats so far, > so I will deal with this later. > > I'm a bit confused when reading the tutorials and the mailing list, > especially when it comes to the statistics... For example : this is from > an email from 2013 by Eric Maris about "Nonparametric statistical > testing of phase coherence" > (http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006401.html) > "To compare coherence between conditions across subjects (instead of > trials), you need a different statfun: depsamplesT (for a > within-subjects design; subjects have participated in all conditions) or > indepsamplesT (for a between-subjects design; subjects have participated > in only one condition)." > > ? If I want to compare across sessions (for a same rat), can I actually > consider that my different sessions are "subjects"? And then compare > coherence "across subjects" would be doing it "across sessions" ? And I > would be in a "within-subject design" since my sessions involve the 2 > conditions every time ? > > I realise that it may be very confusing... I hope you will understand my > problem ! > > And if anyone already applied fieldtrip functions to do statistics on a > different framework that the usual EEG/MEG, please let me know ! > > Thanks a lot, > > Laetitia Lalla > > PhD Student in Neuroscience > > INMED, Marseille, France > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: < > http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160408/2aed96c1/attachment-0001.html > > > > ------------------------------ > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > End of fieldtrip Digest, Vol 65, Issue 7 > **************************************** > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -- Debora Desideri, PhD Student BNP Lab - Neurology Department University Hospital Tübingen Eberhard Karls University Tübingen Hoppe-Seyler Str. 3 D-72076 Tübingen Tel: +49 7071/29 80478 -------------- next part -------------- An HTML attachment was scrubbed... URL: From carsten.wolters at uni-muenster.de Thu Apr 14 11:26:48 2016 From: carsten.wolters at uni-muenster.de (Carsten Wolters) Date: Thu, 14 Apr 2016 11:26:48 +0200 Subject: [FieldTrip] Simbio works with ft_volumereslice but leadfield In-Reply-To: <1460557552027.85876@nin.knaw.nl> References: <1460557552027.85876@nin.knaw.nl> Message-ID: <570F6258.50305@uni-muenster.de> Dear Rajat, we will need a little bit more informations where you are stuck or where the calculations are way too long? In ft_prepare_headmodel the FEM stiffness matrix is computed, which should not take much time. In ft_prepare_sourcemodel, a so-called FE transfer matrix is computed. To do so, for each electrode (but reference) a FEM linear equation system needs to be solved. The time for it thus scales with your number of electrodes. A fully-populated matrix will be resulting that has "number of electrodes -1" many rows and "number of FE nodes" many columns. For a reasonable number of electrodes and with your big memory (32 GB), this should not cause any trouble, but ft_prepare_sourcemodel might be the computationally most expensive step (but has to be done only once for a given FE model and electrode setup, so just start it in the evening). Once the transfer matrix is computed, each FEM forward computation is extremenly fast and therefore also the setup of the leadfield matrix with ft_prepare_leadfield. This should be the case, because for each source, only a right-hand-side in the size "number of FE nodes", but with only about 30 nonzeros, has to be computed and multiplied with the transfer matrix, which takes all together only milliseconds. So a 128^3 grid should not cause any trouble, as long as the transfer matrix fits in the memory (which should also be the case with 32GB), so that the computer doesn't need to swap. Best regards Carsten Am 13.04.2016 um 16:25 schrieb Rajat Thomas: > Dear all, > > Last week I asked for help with Simbio and after following the suggestion of volume reslicing magically the > simbio based headmodel was created. > > But my leadfield calculations are taking way too long. > It is a 128^3 grid and am running it on my desktop. (2.4 GHz, plenty of memory 32GB) > > Could anyone give me a rough ball park on how long it should take to create a leadfield? > > Thank you. > Rajat > > > > Rajat Mani Thomas > Social Brain Lab > Netherlands Institute for Neuroscience > Amsterdam > > ________________________________________ > From: fieldtrip-bounces at science.ru.nl on behalf of fieldtrip-request at science.ru.nl > Sent: 08 April 2016 12:00 > To: fieldtrip at science.ru.nl > Subject: fieldtrip Digest, Vol 65, Issue 7 > > Send fieldtrip mailing list submissions to > fieldtrip at science.ru.nl > > To subscribe or unsubscribe via the World Wide Web, visit > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > or, via email, send a message with subject or body 'help' to > fieldtrip-request at science.ru.nl > > You can reach the person managing the list at > fieldtrip-owner at science.ru.nl > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of fieldtrip digest..." > > > Today's Topics: > > 1. Re: FEM using Simbio (Johannes Vorwerk) > 2. Re: FEM using Simbio (Cristiano Micheli) > 3. Dipole fitting (Giovanni Pellegrino) > 4. Birmingham-Illinois BRIDGE Fellowships (Ole Jensen) > 5. Using FieldTrip to analyse LFP recordings in rat > (laetitia.lalla at inserm.fr) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Thu, 7 Apr 2016 14:25:42 +0200 > From: Johannes Vorwerk > To: FieldTrip discussion list > Subject: Re: [FieldTrip] FEM using Simbio > Message-ID: <435735E3-7D87-4DD6-A2C1-E2BBFBBF4B44 at googlemail.com> > Content-Type: text/plain; charset="utf-8" > > Hi, > > this question was already answered in this thread > > http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html > > If ft_volumereslice is not applied before the mesh generation, the afterwards applied transformation might flip the directions of the mesh, leading to the described error. > > Best, > Johannes > >> Am 06.04.2016 um 16:03 schrieb Carsten Wolters : >> >> Dear Rajat, >> >> the element-node cards of SimBio-NeuroFEM need to follow certain orientations (see www.simbio.de ). >> >> If you do not want to struggle with meshing/ordering, use the SimBio-VGRID mesher >> http://vgrid.simbio.de/ >> that follows the required ordering of nodes. You might use this mesher to produce 1mm geometry-adapted FEM meshes >> that show good overall performance, see >> http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf >> and >> http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf >> (latter was just accepted by NeuroImage). >> >> Best regards >> Carsten >> >> Am 06.04.2016 um 15:10 schrieb Rajat Thomas: >>> Dear all, >>> >>> Has anyone used the FEM approach to Headmodels using Simbio recently? >>> >>> If so, I get this error: >>> "Elements have wrong orientation or are degenerated" >>> >>> Any ideas? >>> >>> cfg = []; >>> cfg.method ='simbio'; >>> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows mesh.tissyelabel >>> vol = ft_prepare_headmodel(cfg, mesh); >>> >>> And; >>> ? >>> disp(mesh) >>> hex: [545883x8 double] >>> pnt: [569722x3 double] >>> labels: [545883x1 double] >>> tissue: [545883x1 double] >>> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >>> unit: 'mm' >>> cfg: [1x1 struct] >>> >>> Any help would be highly appreciated. >>> >>> Rajat >>> >>> >>> >>> >>> >>> >>> Rajat Mani Thomas >>> Social Brain Lab >>> Netherlands Institute for Neuroscience >>> Amsterdam >>> >>> >>> _______________________________________________ >>> 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 > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > Message: 2 > Date: Thu, 7 Apr 2016 17:36:37 +0200 > From: Cristiano Micheli > To: FieldTrip discussion list > Subject: Re: [FieldTrip] FEM using Simbio > Message-ID: > > Content-Type: text/plain; charset="utf-8" > > Hi Rajat > > My guess is that the orientations of your hexahedrons are not correct. > According to a low-level file's internal rules, elements' orientations have > to abide strict rules (not sure what exactly the contraints are in this > case though...). > I had same problems when for example the triangular boundaries used to > define the 3d hexahedral mesh were not topologically correct, to start with. > Admittedly this approach requires a lot of technical expertise. > Can I ask you what do you need a FEM model for? > > Regards > Cris Micheli > > > > > On Wed, Apr 6, 2016 at 3:10 PM, Rajat Thomas wrote: > >> Dear all, >> >> >> Has anyone used the FEM approach to Headmodels using Simbio recently? >> >> >> If so, I get this error: >> "Elements have wrong orientation or are degenerated" >> >> Any ideas? >> >> cfg = []; >> >> cfg.method ='simbio'; >> >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows >> mesh.tissyelabel >> >> vol = ft_prepare_headmodel(cfg, mesh); >> >> >> And; >> >> ? >> disp(mesh) >> hex: [545883x8 double] >> pnt: [569722x3 double] >> labels: [545883x1 double] >> tissue: [545883x1 double] >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >> unit: 'mm' >> cfg: [1x1 struct] >> >> >> Any help would be highly appreciated. >> >> Rajat >> >> >> >> >> >> >> Rajat Mani Thomas >> Social Brain Lab >> Netherlands Institute for Neuroscience >> Amsterdam >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > Message: 3 > Date: Thu, 7 Apr 2016 15:02:05 -0400 > From: Giovanni Pellegrino > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Dipole fitting > Message-ID: > > Content-Type: text/plain; charset="utf-8" > > Dear Fieldtrippers, > > Do you know if the FieldTrip Dipole Fitting has been compared to the CTF, > Elekta, BESA or Curry? Are you aware of any study on this topic? > > Thanks in advance for your help > > Giovanni > > -- > Giovanni Pellegrino, MD > Multimodal Functional Imaging Laboratory > Montreal Neurological Institute, McGill University > Address: 332 Duff Medical Building, 3775 rue University, Montreal, QC, H3A > 2B4, Canada > Phone: (514) 398?1678 > Fax: (514) 398?7461 > Email: giovannipellegrino at gmail.com, giovanni.pellegrino2 at mcgill.ca > Homepage: http://www.bic.mni.mcgill.ca/ResearchLabsMFIL/PeopleGiovanni > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > Message: 4 > Date: Fri, 8 Apr 2016 09:23:46 +0200 > From: Ole Jensen > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Birmingham-Illinois BRIDGE Fellowships > Message-ID: <57075C82.8030309 at donders.ru.nl> > Content-Type: text/plain; charset=utf-8; format=flowed > > Dear all, > > I would like to point you to a set of Birmingham-Illinois BRIDGE > Fellowships providing some exciting research and career prospects: > http://www.birminghamillinoisbridge.org/index.php/fellows/ > > In particular the areas 'Cognition and Ageing' and 'Brain Trauma' could > be relevant for candidates with EEG/MEG expertise. > > All the best, > > Ole > > -- > Prof. dr. Ole Jensen > http://www.neuosc.com > > > > ------------------------------ > > Message: 5 > Date: Fri, 08 Apr 2016 10:27:58 +0200 > From: laetitia.lalla at inserm.fr > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Using FieldTrip to analyse LFP recordings in rat > Message-ID: <628babdc107aebd4cc7588ea87ce5ea6 at inserm.fr> > Content-Type: text/plain; charset="utf-8" > > > > Hello everyone, > > my name is Laetitia and I'm a Phd student in Marseille (France). I'm > doing in-vivo recording in freely-moving rats : I implant them with 2 > electrodes deep into 2 different regions of the brain. I'm studying the > Local Field Potentials and I want to use FieldTrip to analyse the data. > > To simplify : > > - I have 2 rats. > > - Each rat did 20 sessions of the task (on 20 different days). > > - Each session consists of 20 trials of condition 1 and 20 trials of > condition 2. > > I have 2 questions. > > 1) I have the feeling it would be meaningless to do "source > reconstruction" because my electrodes are already deep inside my > "source" and the LFP I am recording is very local. (My electrodes have > 32 channels separated by 20-200 ?m. The LFP is very very similar across > all the channels, so I averaged over the 32 channels to have one signal > for each region.) > > However, I see that 2 different functions exist for the statistics : > FT_FREQSTATISTICS AND FT_SOURCESTATISTICS. So far, I've been using > ft_freqstatistics but I encounter some issues (for exemple, doingIch werde nachfragen. Es wird doch immer in ft_prepare_sourcemodel > die Transfermatrix gerechnet, sodass > > in ft_prepare_leadfield nur noch Multiplikationen dieser > Transfermatrix mit den vielen rechten Seiten > > gerechnet wird, was ja schnell gehen sollte. Ich frage, wo es > hakt. > > > monte-carlo permutation test to assess the imaginary coherence). I > thought of computing it manually, but I'm thinking that maybe more stuff > are implemented in ft_sourcestatisctics ? > > ? Are these 2 functions fundamentally different or do they call the same > sub-fonctions (and my problem has actually nothing to do with that) ? > > 2) I'm a bit confused with the vocabulary from EEG and MEG studies (I'm > not used to it yet...). From what I understood, in human studies, you > can do comparison for a single subject (across trials) or across > subjects. But I have 3 levels of comparisons in my design : > > - WITHIN A SESSION, I WANT TO COMPARE ACROSS TRIALS (the 20 trials of > condition 1 VS the 20 trials of condition 2). > > - WITHIN A RAT, I WANT TO COMPARE ACROSS SESSIONS (between the 2 > conditions) > > - then - in the very end - ACROSS RATS. But I have only 2 rats so far, > so I will deal with this later. > > I'm a bit confused when reading the tutorials and the mailing list, > especially when it comes to the statistics... For example : this is from > an email from 2013 by Eric Maris about "Nonparametric statistical > testing of phase coherence" > (http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006401.html) > "To compare coherence between conditions across subjects (instead of > trials), you need a different statfun: depsamplesT (for a > within-subjects design; subjects have participated in all conditions) or > indepsamplesT (for a between-subjects design; subjects have participated > in only one condition)." > > ? If I want to compare across sessions (for a same rat), can I actually > consider that my different sessions are "subjects"? And then compare > coherence "across subjects" would be doing it "across sessions" ? And I > would be in a "within-subject design" since my sessions involve the 2 > conditions every time ? > > I realise that it may be very confusing... I hope you will understand my > problem ! > > And if anyone already applied fieldtrip functions to do statistics on a > different framework that the usual EEG/MEG, please let me know ! > > Thanks a lot, > > Laetitia Lalla > > PhD Student in Neuroscience > > INMED, Marseille, France > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > End of fieldtrip Digest, Vol 65, Issue 7 > **************************************** > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- A non-text attachment was scrubbed... Name: carsten_wolters.vcf Type: text/x-vcard Size: 402 bytes Desc: not available URL: From erin.white at sickkids.ca Thu Apr 14 20:26:37 2016 From: erin.white at sickkids.ca (Erin White) Date: Thu, 14 Apr 2016 18:26:37 +0000 Subject: [FieldTrip] Grand average with deleted channels In-Reply-To: References: Message-ID: <0D4EE8880DEE3047BEC905C0EC463F8C3E52629B@SKMBXX03.sickkids.ca> Dear Eliana, One option for you would be, rather than deleting the bad channels, to interpolate what their activity would be from the average of surrounding channels. You can do this with FT_CHANNELREPAIR and it's pretty straightforward http://www.fieldtriptoolbox.org/reference/channelrepair Good luck with it! Erin ---------------------------------------------------- Erin White, PhD Post-Doctoral Research Fellow Neurosciences and Mental Health The Hospital for Sick Children 555 University Avenue Toronto, Ontario Canada Telephone: (647)834-7813 ________________________________ From: fieldtrip-bounces at science.ru.nl [fieldtrip-bounces at science.ru.nl] on behalf of Eliana Nicolaisen [elinicolaisen at gmail.com] Sent: April 11, 2016 10:21 AM To: fieldtrip at science.ru.nl Subject: [FieldTrip] Grand average with deleted channels Dear all, I'm trying to make an ERP grand average using version 20150301. In some subjects I deleted bad channels. Those channels were replaced for NaNs. When I make the grand average using ft_timelockaverage, the grand average is composed only for the common channels across subjects. In other words, in channels deleated at least in one subject the grand average is NaN. This is because ft_timelockanalysis in this version calculates the average making a sum and dividng into degrees of freedom: grandavg.avg = reshape(sum(avgmat, 1), datsiz)./ResultDOF; (in line 187 of revision '$Id: ft_timelockgrandaverage.m 10194 2015-02-11 09:08:16Z roboos $') However, I tried version 20121014 that my colleague uses. In this version ft_timelockedanalysis makes a mean: ResultGrandavg = mean(avgmat, 1); (in line 183 of revision '$Id: ft_timelockgrandaverage.m 6750 2012-10-13 15:07:32Z roboos $') In the version 20121014 is easy to make a correction that calculates a grand average taking into account NaNs (just changing mean for nanmean). However, in version 20150301 making a similar correction seems more complicated. Question 1: Why version 20150301 calculates average using sum and division instead of using nanmean? Question 2: Do someone have a suggestion about how to change version 20150301? Any comment would be greatly appreciated. Kind regards, Eliana Nicolaisen ________________________________ This e-mail may contain confidential, personal and/or health information(information which may be subject to legal restrictions on use, retention and/or disclosure) for the sole use of the intended recipient. Any review or distribution by anyone other than the person for whom it was originally intended is strictly prohibited. If you have received this e-mail in error, please contact the sender and delete all copies. -------------- next part -------------- An HTML attachment was scrubbed... URL: From j.vorwerk at uni-muenster.de Thu Apr 14 23:28:46 2016 From: j.vorwerk at uni-muenster.de (Johannes Vorwerk) Date: Thu, 14 Apr 2016 15:28:46 -0600 Subject: [FieldTrip] Simbio works with ft_volumereslice but leadfield In-Reply-To: References: <1460557552027.85876@nin.knaw.nl> Message-ID: <82D66CB4-DE42-409C-B350-E5DA0984A07E@googlemail.com> Hi Debora, could you indicate which part of the computation is the most time consuming, i.e., calculation of the transfer matrix or the subsequent computation of the dipole solutions? Principally, it should be possible to parallelize many of these steps, however, this wasn’t added to the checked-in code yet for reasons of stability/compatibility. Best, Johannes > Am 14.04.2016 um 02:21 schrieb Debora Desideri : > > Dear Rajat, > I am also using Simbio and I usually run the leadfield calculation overnight since it takes approximatelly 12-15 hours for 64 EEG channels with a grid of 6 mm resolution ( 2.60 GHz, 32 GB RAM). > I don't know whether there is a way to speed the process up. Maybe we just need to be patient, or work on a very powerful machine. > > Best, > Debora > > > On Wed, Apr 13, 2016 at 4:25 PM, Rajat Thomas > wrote: > Dear all, > > Last week I asked for help with Simbio and after following the suggestion of volume reslicing magically the > simbio based headmodel was created. > > But my leadfield calculations are taking way too long. > It is a 128^3 grid and am running it on my desktop. (2.4 GHz, plenty of memory 32GB) > > Could anyone give me a rough ball park on how long it should take to create a leadfield? > > Thank you. > Rajat > > > > Rajat Mani Thomas > Social Brain Lab > Netherlands Institute for Neuroscience > Amsterdam > > ________________________________________ > From: fieldtrip-bounces at science.ru.nl > on behalf of fieldtrip-request at science.ru.nl > > Sent: 08 April 2016 12:00 > To: fieldtrip at science.ru.nl > Subject: fieldtrip Digest, Vol 65, Issue 7 > > Send fieldtrip mailing list submissions to > fieldtrip at science.ru.nl > > To subscribe or unsubscribe via the World Wide Web, visit > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > or, via email, send a message with subject or body 'help' to > fieldtrip-request at science.ru.nl > > You can reach the person managing the list at > fieldtrip-owner at science.ru.nl > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of fieldtrip digest..." > > > Today's Topics: > > 1. Re: FEM using Simbio (Johannes Vorwerk) > 2. Re: FEM using Simbio (Cristiano Micheli) > 3. Dipole fitting (Giovanni Pellegrino) > 4. Birmingham-Illinois BRIDGE Fellowships (Ole Jensen) > 5. Using FieldTrip to analyse LFP recordings in rat > (laetitia.lalla at inserm.fr ) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Thu, 7 Apr 2016 14:25:42 +0200 > From: Johannes Vorwerk > > To: FieldTrip discussion list > > Subject: Re: [FieldTrip] FEM using Simbio > Message-ID: <435735E3-7D87-4DD6-A2C1-E2BBFBBF4B44 at googlemail.com > > Content-Type: text/plain; charset="utf-8" > > Hi, > > this question was already answered in this thread > > http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html > > > If ft_volumereslice is not applied before the mesh generation, the afterwards applied transformation might flip the directions of the mesh, leading to the described error. > > Best, > Johannes > > > Am 06.04.2016 um 16:03 schrieb Carsten Wolters >: > > > > Dear Rajat, > > > > the element-node cards of SimBio-NeuroFEM need to follow certain orientations (see www.simbio.de >). > > > > If you do not want to struggle with meshing/ordering, use the SimBio-VGRID mesher > > http://vgrid.simbio.de/ > > > that follows the required ordering of nodes. You might use this mesher to produce 1mm geometry-adapted FEM meshes > > that show good overall performance, see > > http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf > > > and > > http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf > > > (latter was just accepted by NeuroImage). > > > > Best regards > > Carsten > > > > Am 06.04.2016 um 15:10 schrieb Rajat Thomas: > >> Dear all, > >> > >> Has anyone used the FEM approach to Headmodels using Simbio recently? > >> > >> If so, I get this error: > >> "Elements have wrong orientation or are degenerated" > >> > >> Any ideas? > >> > >> cfg = []; > >> cfg.method ='simbio'; > >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows mesh.tissyelabel > >> vol = ft_prepare_headmodel(cfg, mesh); > >> > >> And; > >> ? > >> disp(mesh) > >> hex: [545883x8 double] > >> pnt: [569722x3 double] > >> labels: [545883x1 double] > >> tissue: [545883x1 double] > >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} > >> unit: 'mm' > >> cfg: [1x1 struct] > >> > >> Any help would be highly appreciated. > >> > >> Rajat > >> > >> > >> > >> > >> > >> > >> Rajat Mani Thomas > >> Social Brain Lab > >> Netherlands Institute for Neuroscience > >> Amsterdam > >> > >> > >> _______________________________________________ > >> 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 > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > > ------------------------------ > > Message: 2 > Date: Thu, 7 Apr 2016 17:36:37 +0200 > From: Cristiano Micheli > > To: FieldTrip discussion list > > Subject: Re: [FieldTrip] FEM using Simbio > Message-ID: > > > Content-Type: text/plain; charset="utf-8" > > Hi Rajat > > My guess is that the orientations of your hexahedrons are not correct. > According to a low-level file's internal rules, elements' orientations have > to abide strict rules (not sure what exactly the contraints are in this > case though...). > I had same problems when for example the triangular boundaries used to > define the 3d hexahedral mesh were not topologically correct, to start with. > Admittedly this approach requires a lot of technical expertise. > Can I ask you what do you need a FEM model for? > > Regards > Cris Micheli > > > > > On Wed, Apr 6, 2016 at 3:10 PM, Rajat Thomas > wrote: > > > Dear all, > > > > > > Has anyone used the FEM approach to Headmodels using Simbio recently? > > > > > > If so, I get this error: > > "Elements have wrong orientation or are degenerated" > > > > Any ideas? > > > > cfg = []; > > > > cfg.method ='simbio'; > > > > cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows > > mesh.tissyelabel > > > > vol = ft_prepare_headmodel(cfg, mesh); > > > > > > And; > > > > ? > > disp(mesh) > > hex: [545883x8 double] > > pnt: [569722x3 double] > > labels: [545883x1 double] > > tissue: [545883x1 double] > > tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} > > unit: 'mm' > > cfg: [1x1 struct] > > > > > > Any help would be highly appreciated. > > > > Rajat > > > > > > > > > > > > > > Rajat Mani Thomas > > Social Brain Lab > > Netherlands Institute for Neuroscience > > Amsterdam > > > > _______________________________________________ > > fieldtrip mailing list > > fieldtrip at donders.ru.nl > > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > > ------------------------------ > > Message: 3 > Date: Thu, 7 Apr 2016 15:02:05 -0400 > From: Giovanni Pellegrino > > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Dipole fitting > Message-ID: > > > Content-Type: text/plain; charset="utf-8" > > Dear Fieldtrippers, > > Do you know if the FieldTrip Dipole Fitting has been compared to the CTF, > Elekta, BESA or Curry? Are you aware of any study on this topic? > > Thanks in advance for your help > > Giovanni > > -- > Giovanni Pellegrino, MD > Multimodal Functional Imaging Laboratory > Montreal Neurological Institute, McGill University > Address: 332 Duff Medical Building, 3775 rue University, Montreal, QC, H3A > 2B4, Canada > Phone: (514) 398?1678 > Fax: (514) 398?7461 > Email: giovannipellegrino at gmail.com , giovanni.pellegrino2 at mcgill.ca > Homepage: http://www.bic.mni.mcgill.ca/ResearchLabsMFIL/PeopleGiovanni > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > > ------------------------------ > > Message: 4 > Date: Fri, 8 Apr 2016 09:23:46 +0200 > From: Ole Jensen > > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Birmingham-Illinois BRIDGE Fellowships > Message-ID: <57075C82.8030309 at donders.ru.nl > > Content-Type: text/plain; charset=utf-8; format=flowed > > Dear all, > > I would like to point you to a set of Birmingham-Illinois BRIDGE > Fellowships providing some exciting research and career prospects: > http://www.birminghamillinoisbridge.org/index.php/fellows/ > > In particular the areas 'Cognition and Ageing' and 'Brain Trauma' could > be relevant for candidates with EEG/MEG expertise. > > All the best, > > Ole > > -- > Prof. dr. Ole Jensen > http://www.neuosc.com > > > > ------------------------------ > > Message: 5 > Date: Fri, 08 Apr 2016 10:27:58 +0200 > From: laetitia.lalla at inserm.fr > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Using FieldTrip to analyse LFP recordings in rat > Message-ID: <628babdc107aebd4cc7588ea87ce5ea6 at inserm.fr > > Content-Type: text/plain; charset="utf-8" > > > > Hello everyone, > > my name is Laetitia and I'm a Phd student in Marseille (France). I'm > doing in-vivo recording in freely-moving rats : I implant them with 2 > electrodes deep into 2 different regions of the brain. I'm studying the > Local Field Potentials and I want to use FieldTrip to analyse the data. > > To simplify : > > - I have 2 rats. > > - Each rat did 20 sessions of the task (on 20 different days). > > - Each session consists of 20 trials of condition 1 and 20 trials of > condition 2. > > I have 2 questions. > > 1) I have the feeling it would be meaningless to do "source > reconstruction" because my electrodes are already deep inside my > "source" and the LFP I am recording is very local. (My electrodes have > 32 channels separated by 20-200 ?m. The LFP is very very similar across > all the channels, so I averaged over the 32 channels to have one signal > for each region.) > > However, I see that 2 different functions exist for the statistics : > FT_FREQSTATISTICS AND FT_SOURCESTATISTICS. So far, I've been using > ft_freqstatistics but I encounter some issues (for exemple, doing > monte-carlo permutation test to assess the imaginary coherence). I > thought of computing it manually, but I'm thinking that maybe more stuff > are implemented in ft_sourcestatisctics ? > > ? Are these 2 functions fundamentally different or do they call the same > sub-fonctions (and my problem has actually nothing to do with that) ? > > 2) I'm a bit confused with the vocabulary from EEG and MEG studies (I'm > not used to it yet...). From what I understood, in human studies, you > can do comparison for a single subject (across trials) or across > subjects. But I have 3 levels of comparisons in my design : > > - WITHIN A SESSION, I WANT TO COMPARE ACROSS TRIALS (the 20 trials of > condition 1 VS the 20 trials of condition 2). > > - WITHIN A RAT, I WANT TO COMPARE ACROSS SESSIONS (between the 2 > conditions) > > - then - in the very end - ACROSS RATS. But I have only 2 rats so far, > so I will deal with this later. > > I'm a bit confused when reading the tutorials and the mailing list, > especially when it comes to the statistics... For example : this is from > an email from 2013 by Eric Maris about "Nonparametric statistical > testing of phase coherence" > (http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006401.html ) > "To compare coherence between conditions across subjects (instead of > trials), you need a different statfun: depsamplesT (for a > within-subjects design; subjects have participated in all conditions) or > indepsamplesT (for a between-subjects design; subjects have participated > in only one condition)." > > ? If I want to compare across sessions (for a same rat), can I actually > consider that my different sessions are "subjects"? And then compare > coherence "across subjects" would be doing it "across sessions" ? And I > would be in a "within-subject design" since my sessions involve the 2 > conditions every time ? > > I realise that it may be very confusing... I hope you will understand my > problem ! > > And if anyone already applied fieldtrip functions to do statistics on a > different framework that the usual EEG/MEG, please let me know ! > > Thanks a lot, > > Laetitia Lalla > > PhD Student in Neuroscience > > INMED, Marseille, France > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > > ------------------------------ > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > End of fieldtrip Digest, Vol 65, Issue 7 > **************************************** > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > > -- > > Debora Desideri, PhD Student > BNP Lab - Neurology Department > University Hospital Tübingen > Eberhard Karls University Tübingen > Hoppe-Seyler Str. 3 > D-72076 Tübingen > Tel: +49 7071/29 80478 > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From deb.desideri at gmail.com Fri Apr 15 09:55:43 2016 From: deb.desideri at gmail.com (Debora Desideri) Date: Fri, 15 Apr 2016 09:55:43 +0200 Subject: [FieldTrip] Simbio works with ft_volumereslice but leadfield In-Reply-To: <82D66CB4-DE42-409C-B350-E5DA0984A07E@googlemail.com> References: <1460557552027.85876@nin.knaw.nl> <82D66CB4-DE42-409C-B350-E5DA0984A07E@googlemail.com> Message-ID: Dear Johannes, the time consuming part is when I call ft_prepare_leadfield. The I used this precomputed leadfields for the computation of the dipole solution and this is actually quite fast. I started to use the FEM model only recently and I thought the long lasting calculation was normal. Is there a way to have a faster compuatation of leadfields? Best, Debora On Thu, Apr 14, 2016 at 11:28 PM, Johannes Vorwerk < j.vorwerk at uni-muenster.de> wrote: > Hi Debora, > > could you indicate which part of the computation is the most time > consuming, i.e., calculation of the transfer matrix or the subsequent > computation of the dipole solutions? Principally, it should be possible to > parallelize many of these steps, however, this wasn’t added to the > checked-in code yet for reasons of stability/compatibility. > > Best, > Johannes > > Am 14.04.2016 um 02:21 schrieb Debora Desideri : > > Dear Rajat, > I am also using Simbio and I usually run the leadfield calculation > overnight since it takes approximatelly 12-15 hours for 64 EEG channels > with a grid of 6 mm resolution ( 2.60 GHz, 32 GB RAM). > I don't know whether there is a way to speed the process up. Maybe we just > need to be patient, or work on a very powerful machine. > > Best, > Debora > > > On Wed, Apr 13, 2016 at 4:25 PM, Rajat Thomas > wrote: > >> Dear all, >> >> Last week I asked for help with Simbio and after following the suggestion >> of volume reslicing magically the >> simbio based headmodel was created. >> >> But my leadfield calculations are taking way too long. >> It is a 128^3 grid and am running it on my desktop. (2.4 GHz, plenty of >> memory 32GB) >> >> Could anyone give me a rough ball park on how long it should take to >> create a leadfield? >> >> Thank you. >> Rajat >> >> >> >> Rajat Mani Thomas >> Social Brain Lab >> Netherlands Institute for Neuroscience >> Amsterdam >> >> ________________________________________ >> From: fieldtrip-bounces at science.ru.nl >> on behalf of fieldtrip-request at science.ru.nl < >> fieldtrip-request at science.ru.nl> >> Sent: 08 April 2016 12:00 >> To: fieldtrip at science.ru.nl >> Subject: fieldtrip Digest, Vol 65, Issue 7 >> >> Send fieldtrip mailing list submissions to >> fieldtrip at science.ru.nl >> >> To subscribe or unsubscribe via the World Wide Web, visit >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> or, via email, send a message with subject or body 'help' to >> fieldtrip-request at science.ru.nl >> >> You can reach the person managing the list at >> fieldtrip-owner at science.ru.nl >> >> When replying, please edit your Subject line so it is more specific >> than "Re: Contents of fieldtrip digest..." >> >> >> Today's Topics: >> >> 1. Re: FEM using Simbio (Johannes Vorwerk) >> 2. Re: FEM using Simbio (Cristiano Micheli) >> 3. Dipole fitting (Giovanni Pellegrino) >> 4. Birmingham-Illinois BRIDGE Fellowships (Ole Jensen) >> 5. Using FieldTrip to analyse LFP recordings in rat >> (laetitia.lalla at inserm.fr) >> >> >> ---------------------------------------------------------------------- >> >> Message: 1 >> Date: Thu, 7 Apr 2016 14:25:42 +0200 >> From: Johannes Vorwerk >> To: FieldTrip discussion list >> Subject: Re: [FieldTrip] FEM using Simbio >> Message-ID: <435735E3-7D87-4DD6-A2C1-E2BBFBBF4B44 at googlemail.com> >> Content-Type: text/plain; charset="utf-8" >> >> Hi, >> >> this question was already answered in this thread >> >> http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html < >> http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html> >> >> If ft_volumereslice is not applied before the mesh generation, the >> afterwards applied transformation might flip the directions of the mesh, >> leading to the described error. >> >> Best, >> Johannes >> >> > Am 06.04.2016 um 16:03 schrieb Carsten Wolters < >> carsten.wolters at uni-muenster.de>: >> > >> > Dear Rajat, >> > >> > the element-node cards of SimBio-NeuroFEM need to follow certain >> orientations (see www.simbio.de ). >> > >> > If you do not want to struggle with meshing/ordering, use the >> SimBio-VGRID mesher >> > http://vgrid.simbio.de/ >> > that follows the required ordering of nodes. You might use this mesher >> to produce 1mm geometry-adapted FEM meshes >> > that show good overall performance, see >> > >> http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf >> < >> http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf >> > >> > and >> > >> http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf >> < >> http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf >> > >> > (latter was just accepted by NeuroImage). >> > >> > Best regards >> > Carsten >> > >> > Am 06.04.2016 um 15:10 schrieb Rajat Thomas: >> >> Dear all, >> >> >> >> Has anyone used the FEM approach to Headmodels using Simbio recently? >> >> >> >> If so, I get this error: >> >> "Elements have wrong orientation or are degenerated" >> >> >> >> Any ideas? >> >> >> >> cfg = []; >> >> cfg.method ='simbio'; >> >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows >> mesh.tissyelabel >> >> vol = ft_prepare_headmodel(cfg, mesh); >> >> >> >> And; >> >> ? >> >> disp(mesh) >> >> hex: [545883x8 double] >> >> pnt: [569722x3 double] >> >> labels: [545883x1 double] >> >> tissue: [545883x1 double] >> >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >> >> unit: 'mm' >> >> cfg: [1x1 struct] >> >> >> >> Any help would be highly appreciated. >> >> >> >> Rajat >> >> >> >> >> >> >> >> >> >> >> >> >> >> Rajat Mani Thomas >> >> Social Brain Lab >> >> Netherlands Institute for Neuroscience >> >> Amsterdam >> >> >> >> >> >> _______________________________________________ >> >> fieldtrip mailing list >> >> fieldtrip at donders.ru.nl >> >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip < >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip> >> > _______________________________________________ >> > fieldtrip mailing list >> > fieldtrip at donders.ru.nl >> > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip < >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip> >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> URL: < >> http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160407/2ea995ee/attachment-0001.html >> > >> >> ------------------------------ >> >> Message: 2 >> Date: Thu, 7 Apr 2016 17:36:37 +0200 >> From: Cristiano Micheli >> To: FieldTrip discussion list >> Subject: Re: [FieldTrip] FEM using Simbio >> Message-ID: >> < >> CADW7XCAQONsZ_ujPhkffskZ+j-mnHnAzunS68CdKU6MLSosUPA at mail.gmail.com> >> Content-Type: text/plain; charset="utf-8" >> >> Hi Rajat >> >> My guess is that the orientations of your hexahedrons are not correct. >> According to a low-level file's internal rules, elements' orientations >> have >> to abide strict rules (not sure what exactly the contraints are in this >> case though...). >> I had same problems when for example the triangular boundaries used to >> define the 3d hexahedral mesh were not topologically correct, to start >> with. >> Admittedly this approach requires a lot of technical expertise. >> Can I ask you what do you need a FEM model for? >> >> Regards >> Cris Micheli >> >> >> >> >> On Wed, Apr 6, 2016 at 3:10 PM, Rajat Thomas >> wrote: >> >> > Dear all, >> > >> > >> > Has anyone used the FEM approach to Headmodels using Simbio recently? >> > >> > >> > If so, I get this error: >> > "Elements have wrong orientation or are degenerated" >> > >> > Any ideas? >> > >> > cfg = []; >> > >> > cfg.method ='simbio'; >> > >> > cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows >> > mesh.tissyelabel >> > >> > vol = ft_prepare_headmodel(cfg, mesh); >> > >> > >> > And; >> > >> > ? >> > disp(mesh) >> > hex: [545883x8 double] >> > pnt: [569722x3 double] >> > labels: [545883x1 double] >> > tissue: [545883x1 double] >> > tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >> > unit: 'mm' >> > cfg: [1x1 struct] >> > >> > >> > Any help would be highly appreciated. >> > >> > Rajat >> > >> > >> > >> > >> > >> > >> > Rajat Mani Thomas >> > Social Brain Lab >> > Netherlands Institute for Neuroscience >> > Amsterdam >> > >> > _______________________________________________ >> > fieldtrip mailing list >> > fieldtrip at donders.ru.nl >> > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> > >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> URL: < >> http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160407/4adfe55a/attachment-0001.html >> > >> >> ------------------------------ >> >> Message: 3 >> Date: Thu, 7 Apr 2016 15:02:05 -0400 >> From: Giovanni Pellegrino >> To: fieldtrip at science.ru.nl >> Subject: [FieldTrip] Dipole fitting >> Message-ID: >> > u8GDw at mail.gmail.com> >> Content-Type: text/plain; charset="utf-8" >> >> Dear Fieldtrippers, >> >> Do you know if the FieldTrip Dipole Fitting has been compared to the CTF, >> Elekta, BESA or Curry? Are you aware of any study on this topic? >> >> Thanks in advance for your help >> >> Giovanni >> >> -- >> Giovanni Pellegrino, MD >> Multimodal Functional Imaging Laboratory >> Montreal Neurological Institute, McGill University >> Address: 332 Duff Medical Building, 3775 rue University, Montreal, QC, H3A >> 2B4, Canada >> Phone: (514) 398?1678 >> Fax: (514) 398?7461 >> Email: giovannipellegrino at gmail.com, giovanni.pellegrino2 at mcgill.ca >> Homepage: http://www.bic.mni.mcgill.ca/ResearchLabsMFIL/PeopleGiovanni >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> URL: < >> http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160407/d01144bd/attachment-0001.html >> > >> >> ------------------------------ >> >> Message: 4 >> Date: Fri, 8 Apr 2016 09:23:46 +0200 >> From: Ole Jensen >> To: fieldtrip at science.ru.nl >> Subject: [FieldTrip] Birmingham-Illinois BRIDGE Fellowships >> Message-ID: <57075C82.8030309 at donders.ru.nl> >> Content-Type: text/plain; charset=utf-8; format=flowed >> >> Dear all, >> >> I would like to point you to a set of Birmingham-Illinois BRIDGE >> Fellowships providing some exciting research and career prospects: >> http://www.birminghamillinoisbridge.org/index.php/fellows/ >> >> In particular the areas 'Cognition and Ageing' and 'Brain Trauma' could >> be relevant for candidates with EEG/MEG expertise. >> >> All the best, >> >> Ole >> >> -- >> Prof. dr. Ole Jensen >> http://www.neuosc.com >> >> >> >> ------------------------------ >> >> Message: 5 >> Date: Fri, 08 Apr 2016 10:27:58 +0200 >> From: laetitia.lalla at inserm.fr >> To: fieldtrip at science.ru.nl >> Subject: [FieldTrip] Using FieldTrip to analyse LFP recordings in rat >> Message-ID: <628babdc107aebd4cc7588ea87ce5ea6 at inserm.fr> >> Content-Type: text/plain; charset="utf-8" >> >> >> >> Hello everyone, >> >> my name is Laetitia and I'm a Phd student in Marseille (France). I'm >> doing in-vivo recording in freely-moving rats : I implant them with 2 >> electrodes deep into 2 different regions of the brain. I'm studying the >> Local Field Potentials and I want to use FieldTrip to analyse the data. >> >> To simplify : >> >> - I have 2 rats. >> >> - Each rat did 20 sessions of the task (on 20 different days). >> >> - Each session consists of 20 trials of condition 1 and 20 trials of >> condition 2. >> >> I have 2 questions. >> >> 1) I have the feeling it would be meaningless to do "source >> reconstruction" because my electrodes are already deep inside my >> "source" and the LFP I am recording is very local. (My electrodes have >> 32 channels separated by 20-200 ?m. The LFP is very very similar across >> all the channels, so I averaged over the 32 channels to have one signal >> for each region.) >> >> However, I see that 2 different functions exist for the statistics : >> FT_FREQSTATISTICS AND FT_SOURCESTATISTICS. So far, I've been using >> ft_freqstatistics but I encounter some issues (for exemple, doing >> monte-carlo permutation test to assess the imaginary coherence). I >> thought of computing it manually, but I'm thinking that maybe more stuff >> are implemented in ft_sourcestatisctics ? >> >> ? Are these 2 functions fundamentally different or do they call the same >> sub-fonctions (and my problem has actually nothing to do with that) ? >> >> 2) I'm a bit confused with the vocabulary from EEG and MEG studies (I'm >> not used to it yet...). From what I understood, in human studies, you >> can do comparison for a single subject (across trials) or across >> subjects. But I have 3 levels of comparisons in my design : >> >> - WITHIN A SESSION, I WANT TO COMPARE ACROSS TRIALS (the 20 trials of >> condition 1 VS the 20 trials of condition 2). >> >> - WITHIN A RAT, I WANT TO COMPARE ACROSS SESSIONS (between the 2 >> conditions) >> >> - then - in the very end - ACROSS RATS. But I have only 2 rats so far, >> so I will deal with this later. >> >> I'm a bit confused when reading the tutorials and the mailing list, >> especially when it comes to the statistics... For example : this is from >> an email from 2013 by Eric Maris about "Nonparametric statistical >> testing of phase coherence" >> (http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006401.html) >> "To compare coherence between conditions across subjects (instead of >> trials), you need a different statfun: depsamplesT (for a >> within-subjects design; subjects have participated in all conditions) or >> indepsamplesT (for a between-subjects design; subjects have participated >> in only one condition)." >> >> ? If I want to compare across sessions (for a same rat), can I actually >> consider that my different sessions are "subjects"? And then compare >> coherence "across subjects" would be doing it "across sessions" ? And I >> would be in a "within-subject design" since my sessions involve the 2 >> conditions every time ? >> >> I realise that it may be very confusing... I hope you will understand my >> problem ! >> >> And if anyone already applied fieldtrip functions to do statistics on a >> different framework that the usual EEG/MEG, please let me know ! >> >> Thanks a lot, >> >> Laetitia Lalla >> >> PhD Student in Neuroscience >> >> INMED, Marseille, France >> >> >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> URL: < >> http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160408/2aed96c1/attachment-0001.html >> > >> >> ------------------------------ >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> >> End of fieldtrip Digest, Vol 65, Issue 7 >> **************************************** >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> > > > > -- > > Debora Desideri, PhD Student > BNP Lab - Neurology Department > University Hospital Tübingen > Eberhard Karls University Tübingen > Hoppe-Seyler Str. 3 > D-72076 Tübingen > Tel: +49 7071/29 80478 > > _______________________________________________ > 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 > -- Debora Desideri, PhD Student BNP Lab - Neurology Department University Hospital Tübingen Eberhard Karls University Tübingen Hoppe-Seyler Str. 3 D-72076 Tübingen Tel: +49 7071/29 80478 -------------- next part -------------- An HTML attachment was scrubbed... URL: From Max.Cantor at Colorado.EDU Fri Apr 15 21:48:38 2016 From: Max.Cantor at Colorado.EDU (Max Cantor) Date: Fri, 15 Apr 2016 13:48:38 -0600 Subject: [FieldTrip] TFR mask stats question; Baselined vs unbaselined statistics question In-Reply-To: References: Message-ID: As a followup, I'd like to note that there was a mistake in the multiplot code in my prior post (I had in that code 1,3,5 instead of 1,2,3 as my indices for the stat cell array), and the comment for zlim was not relevant (that was for when I was plotting powspctrm, since the data were freqbaselined). Since the time I posted this, I've tried a few more things that have been somewhat successful. I have set frequency to [1 30], because gamma seemed to be very noisy and the data were bandpass filtered at [0.1 50]hz in the first place so I figured there would be no meaningful effect as high as 50hz. I have also played with the latency, testing a priori assumptions of the time window, as well as a general [0 1.8] window for TFR (and [0 1] window for ERP). Finally, I have tried the analyses using the nonparametric permutation test, but without the cluster correction (and setting cfg.alpha to 0.05 as opposed to 0.025, for the cluster statistics). When I do just the permutation test, I get the effects that I was anticipating in both ERP and TFR. It's only when I add in the cluster correction that I get no significant effects. Does anyone have an idea as to why this might be happening? Best, Max On Fri, Apr 8, 2016 at 3:02 PM, Max Cantor wrote: > Hi fieldtrippers, > > I have two unrelated stats questions, but I figured I'd post them together: > > 1. I've run within subjects permutation statistics testing the difference > between an anomaly and control condition for three different language > conditions; preposition, morphosyntax, and semantics. The code is nearly > identical for both my ERPs and TFRs, except that when I plot my ERPs with > cfg.maskparameter = 'mask', cfg.parameter = 'stat', and cfg.maskalpha = > 0.025, it seems to multiplot just fine, whereas when I try to do the same > for the TFRs, my multiplotted plots are blank, but when I comment out the > mask, the stat plots are fine. I'll attach the code, but is there something > I'm doing obviously wrong? Also, am I correct that my maskalpha should > correspond to my alpha, and not my cluster alpha? > > This is the TFR code, but the ERP code is the exact same except for with > timelocked data as the input and ft_timelockstatistics as the function. > > cfg = []; > cfg.method = 'montecarlo'; > cfg.statistic = 'depsamplesT'; > cfg.correctm = 'cluster'; > cfg.clusteralpha = 0.05; > cfg.clusterstatistic = 'maxsum'; > cfg.minnbchan = 2; > cfg.neighbours = neighbours; > cfg.tail = 0; > cfg.clustertail = 0; > cfg.alpha = 0.025; > cfg.numrandomization = 1000; > > nsubj = length(tot_tfr2_bl{1}); > design = zeros(2,2*nsubj); > for i = 1:nsubj > design(1,i) = i; > end > for i = 1:nsubj > design(1,nsubj+i) = i; > end > design(2,1:nsubj) = 1; > design(2,nsubj+1:2*nsubj) = 2; > > cfg.design = design; > cfg.uvar = 1; > cfg.ivar = 2; > > % Anomaly vs Control > stat_tfr{1} = ft_freqstatistics(cfg, tot_tfr2_bl{1}{:}, > tot_tfr2_bl{2}{:}); % Preposition > stat_tfr{2} = ft_freqstatistics(cfg, tot_tfr2_bl{3}{:}, > tot_tfr2_bl{4}{:}); % Semantics > stat_tfr{3} = ft_freqstatistics(cfg, tot_tfr2_bl{5}{:}, > tot_tfr2_bl{6}{:}); % Morphosyntax > > This is the plotting code. Again, it is virtually the same for the ERPs > except the non-stats configurations would be what makes sense for ERPs. > > % Anomaly vs Control TFR stats multiplot > > cfg = []; > cfg.xlim = [-0.2 1]; > cfg.zlim = [-3 3]; % proportion from baseline > cfg.layout = [max_dir '/quickcap64.mat']; > cfg.maskparameter = 'mask'; > cfg.parameter = 'stat'; > cfg.maskalpha = 0.025; > > ft_multiplotTFR(cfg, stat_tfr{1}); title('Preposition'); > ft_multiplotTFR(cfg, stat_tfr{3}); title('Semantic'); > ft_multiplotTFR(cfg, stat_tfr{5}); title('Morphosyntactic'); > > > 2. The second question is about analyzing baselined vs unbaselined data. > I've seen in the tutorials that there is a somewhat different method for > analyzing trial vs baseline period. However, what I've done instead (for > both ERP and TFR), is use the same within-subjects statistics as with > anomaly vs control, except with the inputs being baselined vs unbaselined > ERPs or TFRs, e.g. Baselined Preposition Anomaly vs Unbaselined Preposition > Anomaly, etc. I understand that the proposed method and my method are not > testing the same thing exactly, but is this a reasonable way of testing the > effect of the baselining anyway? > > Thanks, > > Max > > -- > Max Cantor > Graduate Student > Cognitive Neuroscience of Language Lab > University of Colorado Boulder > -- Max Cantor Graduate Student Cognitive Neuroscience of Language Lab University of Colorado Boulder -------------- next part -------------- An HTML attachment was scrubbed... URL: From j.vorwerk at uni-muenster.de Sun Apr 17 15:34:48 2016 From: j.vorwerk at uni-muenster.de (Johannes Vorwerk) Date: Sun, 17 Apr 2016 07:34:48 -0600 Subject: [FieldTrip] Simbio works with ft_volumereslice but leadfield In-Reply-To: References: <1460557552027.85876@nin.knaw.nl> <82D66CB4-DE42-409C-B350-E5DA0984A07E@googlemail.com> Message-ID: <24BC90ED-EEAA-4AAD-A0A3-0AB6E16E8108@googlemail.com> Hi, could you check if it’s the calculation of the transfer matrix (ft_prepare_vol_sens), which you can recoginze since the #electrode many equations are solved, or the call of leadfield_simbio that takes up the most time? It is normal that the matlab-code takes more time than the SimBio-standalon binary, since it includes some loops. I’ve never experienced such long computations as you did in my testings, so I didn’t think about it very much so far. One might try to find a way to formulate these parts without loops or use parallel loops at some points. Best, Johannes > Am 15.04.2016 um 01:55 schrieb Debora Desideri : > > Dear Johannes, > the time consuming part is when I call ft_prepare_leadfield. The I used this precomputed leadfields for the computation of the dipole solution and this is actually quite fast. > I started to use the FEM model only recently and I thought the long lasting calculation was normal. Is there a way to have a faster compuatation of leadfields? > > Best, > Debora > > > On Thu, Apr 14, 2016 at 11:28 PM, Johannes Vorwerk > wrote: > Hi Debora, > > could you indicate which part of the computation is the most time consuming, i.e., calculation of the transfer matrix or the subsequent computation of the dipole solutions? Principally, it should be possible to parallelize many of these steps, however, this wasn’t added to the checked-in code yet for reasons of stability/compatibility. > > Best, > Johannes > >> Am 14.04.2016 um 02:21 schrieb Debora Desideri >: >> >> Dear Rajat, >> I am also using Simbio and I usually run the leadfield calculation overnight since it takes approximatelly 12-15 hours for 64 EEG channels with a grid of 6 mm resolution ( 2.60 GHz, 32 GB RAM). >> I don't know whether there is a way to speed the process up. Maybe we just need to be patient, or work on a very powerful machine. >> >> Best, >> Debora >> >> >> On Wed, Apr 13, 2016 at 4:25 PM, Rajat Thomas > wrote: >> Dear all, >> >> Last week I asked for help with Simbio and after following the suggestion of volume reslicing magically the >> simbio based headmodel was created. >> >> But my leadfield calculations are taking way too long. >> It is a 128^3 grid and am running it on my desktop. (2.4 GHz, plenty of memory 32GB) >> >> Could anyone give me a rough ball park on how long it should take to create a leadfield? >> >> Thank you. >> Rajat >> >> >> >> Rajat Mani Thomas >> Social Brain Lab >> Netherlands Institute for Neuroscience >> Amsterdam >> >> ________________________________________ >> From: fieldtrip-bounces at science.ru.nl > on behalf of fieldtrip-request at science.ru.nl > >> Sent: 08 April 2016 12:00 >> To: fieldtrip at science.ru.nl >> Subject: fieldtrip Digest, Vol 65, Issue 7 >> >> Send fieldtrip mailing list submissions to >> fieldtrip at science.ru.nl >> >> To subscribe or unsubscribe via the World Wide Web, visit >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> or, via email, send a message with subject or body 'help' to >> fieldtrip-request at science.ru.nl >> >> You can reach the person managing the list at >> fieldtrip-owner at science.ru.nl >> >> When replying, please edit your Subject line so it is more specific >> than "Re: Contents of fieldtrip digest..." >> >> >> Today's Topics: >> >> 1. Re: FEM using Simbio (Johannes Vorwerk) >> 2. Re: FEM using Simbio (Cristiano Micheli) >> 3. Dipole fitting (Giovanni Pellegrino) >> 4. Birmingham-Illinois BRIDGE Fellowships (Ole Jensen) >> 5. Using FieldTrip to analyse LFP recordings in rat >> (laetitia.lalla at inserm.fr ) >> >> >> ---------------------------------------------------------------------- >> >> Message: 1 >> Date: Thu, 7 Apr 2016 14:25:42 +0200 >> From: Johannes Vorwerk > >> To: FieldTrip discussion list > >> Subject: Re: [FieldTrip] FEM using Simbio >> Message-ID: <435735E3-7D87-4DD6-A2C1-E2BBFBBF4B44 at googlemail.com > >> Content-Type: text/plain; charset="utf-8" >> >> Hi, >> >> this question was already answered in this thread >> >> http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html > >> >> If ft_volumereslice is not applied before the mesh generation, the afterwards applied transformation might flip the directions of the mesh, leading to the described error. >> >> Best, >> Johannes >> >> > Am 06.04.2016 um 16:03 schrieb Carsten Wolters >: >> > >> > Dear Rajat, >> > >> > the element-node cards of SimBio-NeuroFEM need to follow certain orientations (see www.simbio.de >). >> > >> > If you do not want to struggle with meshing/ordering, use the SimBio-VGRID mesher >> > http://vgrid.simbio.de/ > >> > that follows the required ordering of nodes. You might use this mesher to produce 1mm geometry-adapted FEM meshes >> > that show good overall performance, see >> > http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf > >> > and >> > http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf > >> > (latter was just accepted by NeuroImage). >> > >> > Best regards >> > Carsten >> > >> > Am 06.04.2016 um 15:10 schrieb Rajat Thomas: >> >> Dear all, >> >> >> >> Has anyone used the FEM approach to Headmodels using Simbio recently? >> >> >> >> If so, I get this error: >> >> "Elements have wrong orientation or are degenerated" >> >> >> >> Any ideas? >> >> >> >> cfg = []; >> >> cfg.method ='simbio'; >> >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows mesh.tissyelabel >> >> vol = ft_prepare_headmodel(cfg, mesh); >> >> >> >> And; >> >> ? >> >> disp(mesh) >> >> hex: [545883x8 double] >> >> pnt: [569722x3 double] >> >> labels: [545883x1 double] >> >> tissue: [545883x1 double] >> >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >> >> unit: 'mm' >> >> cfg: [1x1 struct] >> >> >> >> Any help would be highly appreciated. >> >> >> >> Rajat >> >> >> >> >> >> >> >> >> >> >> >> >> >> Rajat Mani Thomas >> >> Social Brain Lab >> >> Netherlands Institute for Neuroscience >> >> Amsterdam >> >> >> >> >> >> _______________________________________________ >> >> 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 > >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> URL: > >> >> ------------------------------ >> >> Message: 2 >> Date: Thu, 7 Apr 2016 17:36:37 +0200 >> From: Cristiano Micheli > >> To: FieldTrip discussion list > >> Subject: Re: [FieldTrip] FEM using Simbio >> Message-ID: >> > >> Content-Type: text/plain; charset="utf-8" >> >> Hi Rajat >> >> My guess is that the orientations of your hexahedrons are not correct. >> According to a low-level file's internal rules, elements' orientations have >> to abide strict rules (not sure what exactly the contraints are in this >> case though...). >> I had same problems when for example the triangular boundaries used to >> define the 3d hexahedral mesh were not topologically correct, to start with. >> Admittedly this approach requires a lot of technical expertise. >> Can I ask you what do you need a FEM model for? >> >> Regards >> Cris Micheli >> >> >> >> >> On Wed, Apr 6, 2016 at 3:10 PM, Rajat Thomas > wrote: >> >> > Dear all, >> > >> > >> > Has anyone used the FEM approach to Headmodels using Simbio recently? >> > >> > >> > If so, I get this error: >> > "Elements have wrong orientation or are degenerated" >> > >> > Any ideas? >> > >> > cfg = []; >> > >> > cfg.method ='simbio'; >> > >> > cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows >> > mesh.tissyelabel >> > >> > vol = ft_prepare_headmodel(cfg, mesh); >> > >> > >> > And; >> > >> > ? >> > disp(mesh) >> > hex: [545883x8 double] >> > pnt: [569722x3 double] >> > labels: [545883x1 double] >> > tissue: [545883x1 double] >> > tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >> > unit: 'mm' >> > cfg: [1x1 struct] >> > >> > >> > Any help would be highly appreciated. >> > >> > Rajat >> > >> > >> > >> > >> > >> > >> > Rajat Mani Thomas >> > Social Brain Lab >> > Netherlands Institute for Neuroscience >> > Amsterdam >> > >> > _______________________________________________ >> > fieldtrip mailing list >> > fieldtrip at donders.ru.nl >> > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> > >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> URL: > >> >> ------------------------------ >> >> Message: 3 >> Date: Thu, 7 Apr 2016 15:02:05 -0400 >> From: Giovanni Pellegrino > >> To: fieldtrip at science.ru.nl >> Subject: [FieldTrip] Dipole fitting >> Message-ID: >> > >> Content-Type: text/plain; charset="utf-8" >> >> Dear Fieldtrippers, >> >> Do you know if the FieldTrip Dipole Fitting has been compared to the CTF, >> Elekta, BESA or Curry? Are you aware of any study on this topic? >> >> Thanks in advance for your help >> >> Giovanni >> >> -- >> Giovanni Pellegrino, MD >> Multimodal Functional Imaging Laboratory >> Montreal Neurological Institute, McGill University >> Address: 332 Duff Medical Building, 3775 rue University, Montreal, QC, H3A >> 2B4, Canada >> Phone: (514) 398?1678 >> Fax: (514) 398?7461 >> Email: giovannipellegrino at gmail.com , giovanni.pellegrino2 at mcgill.ca >> Homepage: http://www.bic.mni.mcgill.ca/ResearchLabsMFIL/PeopleGiovanni >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> URL: > >> >> ------------------------------ >> >> Message: 4 >> Date: Fri, 8 Apr 2016 09:23:46 +0200 >> From: Ole Jensen > >> To: fieldtrip at science.ru.nl >> Subject: [FieldTrip] Birmingham-Illinois BRIDGE Fellowships >> Message-ID: <57075C82.8030309 at donders.ru.nl > >> Content-Type: text/plain; charset=utf-8; format=flowed >> >> Dear all, >> >> I would like to point you to a set of Birmingham-Illinois BRIDGE >> Fellowships providing some exciting research and career prospects: >> http://www.birminghamillinoisbridge.org/index.php/fellows/ >> >> In particular the areas 'Cognition and Ageing' and 'Brain Trauma' could >> be relevant for candidates with EEG/MEG expertise. >> >> All the best, >> >> Ole >> >> -- >> Prof. dr. Ole Jensen >> http://www.neuosc.com >> >> >> >> ------------------------------ >> >> Message: 5 >> Date: Fri, 08 Apr 2016 10:27:58 +0200 >> From: laetitia.lalla at inserm.fr >> To: fieldtrip at science.ru.nl >> Subject: [FieldTrip] Using FieldTrip to analyse LFP recordings in rat >> Message-ID: <628babdc107aebd4cc7588ea87ce5ea6 at inserm.fr > >> Content-Type: text/plain; charset="utf-8" >> >> >> >> Hello everyone, >> >> my name is Laetitia and I'm a Phd student in Marseille (France). I'm >> doing in-vivo recording in freely-moving rats : I implant them with 2 >> electrodes deep into 2 different regions of the brain. I'm studying the >> Local Field Potentials and I want to use FieldTrip to analyse the data. >> >> To simplify : >> >> - I have 2 rats. >> >> - Each rat did 20 sessions of the task (on 20 different days). >> >> - Each session consists of 20 trials of condition 1 and 20 trials of >> condition 2. >> >> I have 2 questions. >> >> 1) I have the feeling it would be meaningless to do "source >> reconstruction" because my electrodes are already deep inside my >> "source" and the LFP I am recording is very local. (My electrodes have >> 32 channels separated by 20-200 ?m. The LFP is very very similar across >> all the channels, so I averaged over the 32 channels to have one signal >> for each region.) >> >> However, I see that 2 different functions exist for the statistics : >> FT_FREQSTATISTICS AND FT_SOURCESTATISTICS. So far, I've been using >> ft_freqstatistics but I encounter some issues (for exemple, doing >> monte-carlo permutation test to assess the imaginary coherence). I >> thought of computing it manually, but I'm thinking that maybe more stuff >> are implemented in ft_sourcestatisctics ? >> >> ? Are these 2 functions fundamentally different or do they call the same >> sub-fonctions (and my problem has actually nothing to do with that) ? >> >> 2) I'm a bit confused with the vocabulary from EEG and MEG studies (I'm >> not used to it yet...). From what I understood, in human studies, you >> can do comparison for a single subject (across trials) or across >> subjects. But I have 3 levels of comparisons in my design : >> >> - WITHIN A SESSION, I WANT TO COMPARE ACROSS TRIALS (the 20 trials of >> condition 1 VS the 20 trials of condition 2). >> >> - WITHIN A RAT, I WANT TO COMPARE ACROSS SESSIONS (between the 2 >> conditions) >> >> - then - in the very end - ACROSS RATS. But I have only 2 rats so far, >> so I will deal with this later. >> >> I'm a bit confused when reading the tutorials and the mailing list, >> especially when it comes to the statistics... For example : this is from >> an email from 2013 by Eric Maris about "Nonparametric statistical >> testing of phase coherence" >> (http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006401.html ) >> "To compare coherence between conditions across subjects (instead of >> trials), you need a different statfun: depsamplesT (for a >> within-subjects design; subjects have participated in all conditions) or >> indepsamplesT (for a between-subjects design; subjects have participated >> in only one condition)." >> >> ? If I want to compare across sessions (for a same rat), can I actually >> consider that my different sessions are "subjects"? And then compare >> coherence "across subjects" would be doing it "across sessions" ? And I >> would be in a "within-subject design" since my sessions involve the 2 >> conditions every time ? >> >> I realise that it may be very confusing... I hope you will understand my >> problem ! >> >> And if anyone already applied fieldtrip functions to do statistics on a >> different framework that the usual EEG/MEG, please let me know ! >> >> Thanks a lot, >> >> Laetitia Lalla >> >> PhD Student in Neuroscience >> >> INMED, Marseille, France >> >> >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> URL: > >> >> ------------------------------ >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> >> End of fieldtrip Digest, Vol 65, Issue 7 >> **************************************** >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> >> >> >> -- >> >> Debora Desideri, PhD Student >> BNP Lab - Neurology Department >> University Hospital Tübingen >> Eberhard Karls University Tübingen >> Hoppe-Seyler Str. 3 >> D-72076 Tübingen >> Tel: +49 7071/29 80478 >> >> _______________________________________________ >> 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 > > > > -- > > Debora Desideri, PhD Student > BNP Lab - Neurology Department > University Hospital Tübingen > Eberhard Karls University Tübingen > Hoppe-Seyler Str. 3 > D-72076 Tübingen > Tel: +49 7071/29 80478 > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From deb.desideri at gmail.com Sun Apr 17 21:08:32 2016 From: deb.desideri at gmail.com (Debora Desideri) Date: Sun, 17 Apr 2016 21:08:32 +0200 Subject: [FieldTrip] Simbio works with ft_volumereslice but leadfield In-Reply-To: <24BC90ED-EEAA-4AAD-A0A3-0AB6E16E8108@googlemail.com> References: <1460557552027.85876@nin.knaw.nl> <82D66CB4-DE42-409C-B350-E5DA0984A07E@googlemail.com> <24BC90ED-EEAA-4AAD-A0A3-0AB6E16E8108@googlemail.com> Message-ID: Dear Johannes, yes, the calculation of the transfer matrix is actually the part that takes so long (ft_prepare_vol_sens). But as you point out, it is maybe just a not efficient matlab implementation... Best, Debora On Sun, Apr 17, 2016 at 3:34 PM, Johannes Vorwerk wrote: > Hi, > > could you check if it’s the calculation of the transfer matrix > (ft_prepare_vol_sens), which you can recoginze since the #electrode many > equations are solved, or the call of leadfield_simbio that takes up the > most time? > > It is normal that the matlab-code takes more time than the > SimBio-standalon binary, since it includes some loops. I’ve never > experienced such long computations as you did in my testings, so I didn’t > think about it very much so far. One might try to find a way to formulate > these parts without loops or use parallel loops at some points. > > Best, > Johannes > > Am 15.04.2016 um 01:55 schrieb Debora Desideri : > > Dear Johannes, > the time consuming part is when I call ft_prepare_leadfield. The I used > this precomputed leadfields for the computation of the dipole solution and > this is actually quite fast. > I started to use the FEM model only recently and I thought the long > lasting calculation was normal. Is there a way to have a faster > compuatation of leadfields? > > Best, > Debora > > > On Thu, Apr 14, 2016 at 11:28 PM, Johannes Vorwerk < > j.vorwerk at uni-muenster.de> wrote: > >> Hi Debora, >> >> could you indicate which part of the computation is the most time >> consuming, i.e., calculation of the transfer matrix or the subsequent >> computation of the dipole solutions? Principally, it should be possible to >> parallelize many of these steps, however, this wasn’t added to the >> checked-in code yet for reasons of stability/compatibility. >> >> Best, >> Johannes >> >> Am 14.04.2016 um 02:21 schrieb Debora Desideri : >> >> Dear Rajat, >> I am also using Simbio and I usually run the leadfield calculation >> overnight since it takes approximatelly 12-15 hours for 64 EEG channels >> with a grid of 6 mm resolution ( 2.60 GHz, 32 GB RAM). >> I don't know whether there is a way to speed the process up. Maybe we >> just need to be patient, or work on a very powerful machine. >> >> Best, >> Debora >> >> >> On Wed, Apr 13, 2016 at 4:25 PM, Rajat Thomas >> wrote: >> >>> Dear all, >>> >>> Last week I asked for help with Simbio and after following the >>> suggestion of volume reslicing magically the >>> simbio based headmodel was created. >>> >>> But my leadfield calculations are taking way too long. >>> It is a 128^3 grid and am running it on my desktop. (2.4 GHz, plenty of >>> memory 32GB) >>> >>> Could anyone give me a rough ball park on how long it should take to >>> create a leadfield? >>> >>> Thank you. >>> Rajat >>> >>> >>> >>> Rajat Mani Thomas >>> Social Brain Lab >>> Netherlands Institute for Neuroscience >>> Amsterdam >>> >>> ________________________________________ >>> From: fieldtrip-bounces at science.ru.nl >>> on behalf of fieldtrip-request at science.ru.nl < >>> fieldtrip-request at science.ru.nl> >>> Sent: 08 April 2016 12:00 >>> To: fieldtrip at science.ru.nl >>> Subject: fieldtrip Digest, Vol 65, Issue 7 >>> >>> Send fieldtrip mailing list submissions to >>> fieldtrip at science.ru.nl >>> >>> To subscribe or unsubscribe via the World Wide Web, visit >>> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >>> or, via email, send a message with subject or body 'help' to >>> fieldtrip-request at science.ru.nl >>> >>> You can reach the person managing the list at >>> fieldtrip-owner at science.ru.nl >>> >>> When replying, please edit your Subject line so it is more specific >>> than "Re: Contents of fieldtrip digest..." >>> >>> >>> Today's Topics: >>> >>> 1. Re: FEM using Simbio (Johannes Vorwerk) >>> 2. Re: FEM using Simbio (Cristiano Micheli) >>> 3. Dipole fitting (Giovanni Pellegrino) >>> 4. Birmingham-Illinois BRIDGE Fellowships (Ole Jensen) >>> 5. Using FieldTrip to analyse LFP recordings in rat >>> (laetitia.lalla at inserm.fr) >>> >>> >>> ---------------------------------------------------------------------- >>> >>> Message: 1 >>> Date: Thu, 7 Apr 2016 14:25:42 +0200 >>> From: Johannes Vorwerk >>> To: FieldTrip discussion list >>> Subject: Re: [FieldTrip] FEM using Simbio >>> Message-ID: <435735E3-7D87-4DD6-A2C1-E2BBFBBF4B44 at googlemail.com> >>> Content-Type: text/plain; charset="utf-8" >>> >>> Hi, >>> >>> this question was already answered in this thread >>> >>> http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html >>> >> > >>> >>> If ft_volumereslice is not applied before the mesh generation, the >>> afterwards applied transformation might flip the directions of the mesh, >>> leading to the described error. >>> >>> Best, >>> Johannes >>> >>> > Am 06.04.2016 um 16:03 schrieb Carsten Wolters < >>> carsten.wolters at uni-muenster.de>: >>> > >>> > Dear Rajat, >>> > >>> > the element-node cards of SimBio-NeuroFEM need to follow certain >>> orientations (see www.simbio.de ). >>> > >>> > If you do not want to struggle with meshing/ordering, use the >>> SimBio-VGRID mesher >>> > http://vgrid.simbio.de/ >>> > that follows the required ordering of nodes. You might use this mesher >>> to produce 1mm geometry-adapted FEM meshes >>> > that show good overall performance, see >>> > >>> http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf >>> < >>> http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf >>> > >>> > and >>> > >>> http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf >>> < >>> http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf >>> > >>> > (latter was just accepted by NeuroImage). >>> > >>> > Best regards >>> > Carsten >>> > >>> > Am 06.04.2016 um 15:10 schrieb Rajat Thomas: >>> >> Dear all, >>> >> >>> >> Has anyone used the FEM approach to Headmodels using Simbio recently? >>> >> >>> >> If so, I get this error: >>> >> "Elements have wrong orientation or are degenerated" >>> >> >>> >> Any ideas? >>> >> >>> >> cfg = []; >>> >> cfg.method ='simbio'; >>> >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows >>> mesh.tissyelabel >>> >> vol = ft_prepare_headmodel(cfg, mesh); >>> >> >>> >> And; >>> >> ? >>> >> disp(mesh) >>> >> hex: [545883x8 double] >>> >> pnt: [569722x3 double] >>> >> labels: [545883x1 double] >>> >> tissue: [545883x1 double] >>> >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >>> >> unit: 'mm' >>> >> cfg: [1x1 struct] >>> >> >>> >> Any help would be highly appreciated. >>> >> >>> >> Rajat >>> >> >>> >> >>> >> >>> >> >>> >> >>> >> >>> >> Rajat Mani Thomas >>> >> Social Brain Lab >>> >> Netherlands Institute for Neuroscience >>> >> Amsterdam >>> >> >>> >> >>> >> _______________________________________________ >>> >> fieldtrip mailing list >>> >> fieldtrip at donders.ru.nl >>> >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip < >>> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip> >>> > _______________________________________________ >>> > fieldtrip mailing list >>> > fieldtrip at donders.ru.nl >>> > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip < >>> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip> >>> -------------- next part -------------- >>> An HTML attachment was scrubbed... >>> URL: < >>> http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160407/2ea995ee/attachment-0001.html >>> > >>> >>> ------------------------------ >>> >>> Message: 2 >>> Date: Thu, 7 Apr 2016 17:36:37 +0200 >>> From: Cristiano Micheli >>> To: FieldTrip discussion list >>> Subject: Re: [FieldTrip] FEM using Simbio >>> Message-ID: >>> < >>> CADW7XCAQONsZ_ujPhkffskZ+j-mnHnAzunS68CdKU6MLSosUPA at mail.gmail.com> >>> Content-Type: text/plain; charset="utf-8" >>> >>> Hi Rajat >>> >>> My guess is that the orientations of your hexahedrons are not correct. >>> According to a low-level file's internal rules, elements' orientations >>> have >>> to abide strict rules (not sure what exactly the contraints are in this >>> case though...). >>> I had same problems when for example the triangular boundaries used to >>> define the 3d hexahedral mesh were not topologically correct, to start >>> with. >>> Admittedly this approach requires a lot of technical expertise. >>> Can I ask you what do you need a FEM model for? >>> >>> Regards >>> Cris Micheli >>> >>> >>> >>> >>> On Wed, Apr 6, 2016 at 3:10 PM, Rajat Thomas >>> wrote: >>> >>> > Dear all, >>> > >>> > >>> > Has anyone used the FEM approach to Headmodels using Simbio recently? >>> > >>> > >>> > If so, I get this error: >>> > "Elements have wrong orientation or are degenerated" >>> > >>> > Any ideas? >>> > >>> > cfg = []; >>> > >>> > cfg.method ='simbio'; >>> > >>> > cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows >>> > mesh.tissyelabel >>> > >>> > vol = ft_prepare_headmodel(cfg, mesh); >>> > >>> > >>> > And; >>> > >>> > ? >>> > disp(mesh) >>> > hex: [545883x8 double] >>> > pnt: [569722x3 double] >>> > labels: [545883x1 double] >>> > tissue: [545883x1 double] >>> > tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >>> > unit: 'mm' >>> > cfg: [1x1 struct] >>> > >>> > >>> > Any help would be highly appreciated. >>> > >>> > Rajat >>> > >>> > >>> > >>> > >>> > >>> > >>> > Rajat Mani Thomas >>> > Social Brain Lab >>> > Netherlands Institute for Neuroscience >>> > Amsterdam >>> > >>> > _______________________________________________ >>> > fieldtrip mailing list >>> > fieldtrip at donders.ru.nl >>> > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >>> > >>> -------------- next part -------------- >>> An HTML attachment was scrubbed... >>> URL: < >>> http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160407/4adfe55a/attachment-0001.html >>> > >>> >>> ------------------------------ >>> >>> Message: 3 >>> Date: Thu, 7 Apr 2016 15:02:05 -0400 >>> From: Giovanni Pellegrino >>> To: fieldtrip at science.ru.nl >>> Subject: [FieldTrip] Dipole fitting >>> Message-ID: >>> >> u8GDw at mail.gmail.com> >>> Content-Type: text/plain; charset="utf-8" >>> >>> Dear Fieldtrippers, >>> >>> Do you know if the FieldTrip Dipole Fitting has been compared to the CTF, >>> Elekta, BESA or Curry? Are you aware of any study on this topic? >>> >>> Thanks in advance for your help >>> >>> Giovanni >>> >>> -- >>> Giovanni Pellegrino, MD >>> Multimodal Functional Imaging Laboratory >>> Montreal Neurological Institute, McGill University >>> Address: 332 Duff Medical Building, 3775 rue University, Montreal, QC, >>> H3A >>> 2B4, Canada >>> Phone: (514) 398?1678 >>> Fax: (514) 398?7461 >>> Email: giovannipellegrino at gmail.com, giovanni.pellegrino2 at mcgill.ca >>> Homepage: http://www.bic.mni.mcgill.ca/ResearchLabsMFIL/PeopleGiovanni >>> -------------- next part -------------- >>> An HTML attachment was scrubbed... >>> URL: < >>> http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160407/d01144bd/attachment-0001.html >>> > >>> >>> ------------------------------ >>> >>> Message: 4 >>> Date: Fri, 8 Apr 2016 09:23:46 +0200 >>> From: Ole Jensen >>> To: fieldtrip at science.ru.nl >>> Subject: [FieldTrip] Birmingham-Illinois BRIDGE Fellowships >>> Message-ID: <57075C82.8030309 at donders.ru.nl> >>> Content-Type: text/plain; charset=utf-8; format=flowed >>> >>> Dear all, >>> >>> I would like to point you to a set of Birmingham-Illinois BRIDGE >>> Fellowships providing some exciting research and career prospects: >>> http://www.birminghamillinoisbridge.org/index.php/fellows/ >>> >>> In particular the areas 'Cognition and Ageing' and 'Brain Trauma' could >>> be relevant for candidates with EEG/MEG expertise. >>> >>> All the best, >>> >>> Ole >>> >>> -- >>> Prof. dr. Ole Jensen >>> http://www.neuosc.com >>> >>> >>> >>> ------------------------------ >>> >>> Message: 5 >>> Date: Fri, 08 Apr 2016 10:27:58 +0200 >>> From: laetitia.lalla at inserm.fr >>> To: fieldtrip at science.ru.nl >>> Subject: [FieldTrip] Using FieldTrip to analyse LFP recordings in rat >>> Message-ID: <628babdc107aebd4cc7588ea87ce5ea6 at inserm.fr> >>> Content-Type: text/plain; charset="utf-8" >>> >>> >>> >>> Hello everyone, >>> >>> my name is Laetitia and I'm a Phd student in Marseille (France). I'm >>> doing in-vivo recording in freely-moving rats : I implant them with 2 >>> electrodes deep into 2 different regions of the brain. I'm studying the >>> Local Field Potentials and I want to use FieldTrip to analyse the data. >>> >>> To simplify : >>> >>> - I have 2 rats. >>> >>> - Each rat did 20 sessions of the task (on 20 different days). >>> >>> - Each session consists of 20 trials of condition 1 and 20 trials of >>> condition 2. >>> >>> I have 2 questions. >>> >>> 1) I have the feeling it would be meaningless to do "source >>> reconstruction" because my electrodes are already deep inside my >>> "source" and the LFP I am recording is very local. (My electrodes have >>> 32 channels separated by 20-200 ?m. The LFP is very very similar across >>> all the channels, so I averaged over the 32 channels to have one signal >>> for each region.) >>> >>> However, I see that 2 different functions exist for the statistics : >>> FT_FREQSTATISTICS AND FT_SOURCESTATISTICS. So far, I've been using >>> ft_freqstatistics but I encounter some issues (for exemple, doing >>> monte-carlo permutation test to assess the imaginary coherence). I >>> thought of computing it manually, but I'm thinking that maybe more stuff >>> are implemented in ft_sourcestatisctics ? >>> >>> ? Are these 2 functions fundamentally different or do they call the same >>> sub-fonctions (and my problem has actually nothing to do with that) ? >>> >>> 2) I'm a bit confused with the vocabulary from EEG and MEG studies (I'm >>> not used to it yet...). From what I understood, in human studies, you >>> can do comparison for a single subject (across trials) or across >>> subjects. But I have 3 levels of comparisons in my design : >>> >>> - WITHIN A SESSION, I WANT TO COMPARE ACROSS TRIALS (the 20 trials of >>> condition 1 VS the 20 trials of condition 2). >>> >>> - WITHIN A RAT, I WANT TO COMPARE ACROSS SESSIONS (between the 2 >>> conditions) >>> >>> - then - in the very end - ACROSS RATS. But I have only 2 rats so far, >>> so I will deal with this later. >>> >>> I'm a bit confused when reading the tutorials and the mailing list, >>> especially when it comes to the statistics... For example : this is from >>> an email from 2013 by Eric Maris about "Nonparametric statistical >>> testing of phase coherence" >>> (http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006401.html >>> ) >>> "To compare coherence between conditions across subjects (instead of >>> trials), you need a different statfun: depsamplesT (for a >>> within-subjects design; subjects have participated in all conditions) or >>> indepsamplesT (for a between-subjects design; subjects have participated >>> in only one condition)." >>> >>> ? If I want to compare across sessions (for a same rat), can I actually >>> consider that my different sessions are "subjects"? And then compare >>> coherence "across subjects" would be doing it "across sessions" ? And I >>> would be in a "within-subject design" since my sessions involve the 2 >>> conditions every time ? >>> >>> I realise that it may be very confusing... I hope you will understand my >>> problem ! >>> >>> And if anyone already applied fieldtrip functions to do statistics on a >>> different framework that the usual EEG/MEG, please let me know ! >>> >>> Thanks a lot, >>> >>> Laetitia Lalla >>> >>> PhD Student in Neuroscience >>> >>> INMED, Marseille, France >>> >>> >>> -------------- next part -------------- >>> An HTML attachment was scrubbed... >>> URL: < >>> http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160408/2aed96c1/attachment-0001.html >>> > >>> >>> ------------------------------ >>> >>> _______________________________________________ >>> fieldtrip mailing list >>> fieldtrip at donders.ru.nl >>> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >>> >>> End of fieldtrip Digest, Vol 65, Issue 7 >>> **************************************** >>> >>> _______________________________________________ >>> fieldtrip mailing list >>> fieldtrip at donders.ru.nl >>> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >>> >> >> >> >> -- >> >> Debora Desideri, PhD Student >> BNP Lab - Neurology Department >> University Hospital Tübingen >> Eberhard Karls University Tübingen >> Hoppe-Seyler Str. 3 >> D-72076 Tübingen >> Tel: +49 7071/29 80478 >> >> _______________________________________________ >> 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 >> > > > > -- > > Debora Desideri, PhD Student > BNP Lab - Neurology Department > University Hospital Tübingen > Eberhard Karls University Tübingen > Hoppe-Seyler Str. 3 > D-72076 Tübingen > Tel: +49 7071/29 80478 > > _______________________________________________ > 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 > -- Debora Desideri, PhD Student BNP Lab - Neurology Department University Hospital Tübingen Eberhard Karls University Tübingen Hoppe-Seyler Str. 3 D-72076 Tübingen Tel: +49 7071/29 80478 -------------- next part -------------- An HTML attachment was scrubbed... URL: From icelandhouse at gmail.com Mon Apr 18 10:45:33 2016 From: icelandhouse at gmail.com (Maris Skujevskis) Date: Mon, 18 Apr 2016 10:45:33 +0200 Subject: [FieldTrip] fieldtrip Digest, Vol 65, Issue 14 In-Reply-To: References: Message-ID: Dear Fieldtrip users, When constructing an EEG forward model, the function ft_prepare_sourcemodel has an option cfg.inwardshift. When plotting the grid of the source model over the brain volume, I get the following differences between a negative and a zero inwardshift (skull and scalp layers not shown): https://drive.google.com/file/d/0B9QSyDy3RhMIUkdxaHBPV2FtODg/view?usp=sharing >From this I conclude that a negative inward shift means that grid points that in reality are outside the brain get treated as inside the brain in the source model. Based on this observation, I have two questions: a) why could a shift be necessary? -- naively, it doesn't make sense that a grid point needs to be labeled as being in the brain when it actually is outside. b) how can a shift be justified? -- it seems that the outer grid points that get labeled as 'inside' due to the shift would have incorrect conductivity values when the leadfield matrix is calculated. This would be the case because in the volume conduction model the coordinates of those points correspond to the skull and not to the brain tissue. Any explanations/corrections of the above outline of what cfg.inwardshift does will be highly appreciated, Maris. On Sat, Apr 16, 2016 at 12:00 PM, wrote: > Send fieldtrip mailing list submissions to > fieldtrip at science.ru.nl > > To subscribe or unsubscribe via the World Wide Web, visit > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > or, via email, send a message with subject or body 'help' to > fieldtrip-request at science.ru.nl > > You can reach the person managing the list at > fieldtrip-owner at science.ru.nl > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of fieldtrip digest..." > > > Today's Topics: > > 1. Re: TFR mask stats question; Baselined vs unbaselined > statistics question (Max Cantor) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Fri, 15 Apr 2016 13:48:38 -0600 > From: Max Cantor > To: FieldTrip discussion list > Subject: Re: [FieldTrip] TFR mask stats question; Baselined vs > unbaselined statistics question > Message-ID: > < > CAOv1Hy1VumqCGBuzCpTOo7KPLDfTPXMGMoWVrhzbO2+cvqjRdQ at mail.gmail.com> > Content-Type: text/plain; charset="utf-8" > > As a followup, I'd like to note that there was a mistake in the multiplot > code in my prior post (I had in that code 1,3,5 instead of 1,2,3 as my > indices for the stat cell array), and the comment for zlim was not relevant > (that was for when I was plotting powspctrm, since the data were > freqbaselined). > > Since the time I posted this, I've tried a few more things that have been > somewhat successful. I have set frequency to [1 30], because gamma seemed > to be very noisy and the data were bandpass filtered at [0.1 50]hz in the > first place so I figured there would be no meaningful effect as high as > 50hz. I have also played with the latency, testing a priori assumptions of > the time window, as well as a general [0 1.8] window for TFR (and [0 1] > window for ERP). > > Finally, I have tried the analyses using the nonparametric permutation > test, but without the cluster correction (and setting cfg.alpha to 0.05 as > opposed to 0.025, for the cluster statistics). When I do just the > permutation test, I get the effects that I was anticipating in both ERP and > TFR. It's only when I add in the cluster correction that I get no > significant effects. > > Does anyone have an idea as to why this might be happening? > > Best, > > Max > > On Fri, Apr 8, 2016 at 3:02 PM, Max Cantor > wrote: > > > Hi fieldtrippers, > > > > I have two unrelated stats questions, but I figured I'd post them > together: > > > > 1. I've run within subjects permutation statistics testing the difference > > between an anomaly and control condition for three different language > > conditions; preposition, morphosyntax, and semantics. The code is nearly > > identical for both my ERPs and TFRs, except that when I plot my ERPs with > > cfg.maskparameter = 'mask', cfg.parameter = 'stat', and cfg.maskalpha = > > 0.025, it seems to multiplot just fine, whereas when I try to do the same > > for the TFRs, my multiplotted plots are blank, but when I comment out the > > mask, the stat plots are fine. I'll attach the code, but is there > something > > I'm doing obviously wrong? Also, am I correct that my maskalpha should > > correspond to my alpha, and not my cluster alpha? > > > > This is the TFR code, but the ERP code is the exact same except for with > > timelocked data as the input and ft_timelockstatistics as the function. > > > > cfg = []; > > cfg.method = 'montecarlo'; > > cfg.statistic = 'depsamplesT'; > > cfg.correctm = 'cluster'; > > cfg.clusteralpha = 0.05; > > cfg.clusterstatistic = 'maxsum'; > > cfg.minnbchan = 2; > > cfg.neighbours = neighbours; > > cfg.tail = 0; > > cfg.clustertail = 0; > > cfg.alpha = 0.025; > > cfg.numrandomization = 1000; > > > > nsubj = length(tot_tfr2_bl{1}); > > design = zeros(2,2*nsubj); > > for i = 1:nsubj > > design(1,i) = i; > > end > > for i = 1:nsubj > > design(1,nsubj+i) = i; > > end > > design(2,1:nsubj) = 1; > > design(2,nsubj+1:2*nsubj) = 2; > > > > cfg.design = design; > > cfg.uvar = 1; > > cfg.ivar = 2; > > > > % Anomaly vs Control > > stat_tfr{1} = ft_freqstatistics(cfg, tot_tfr2_bl{1}{:}, > > tot_tfr2_bl{2}{:}); % Preposition > > stat_tfr{2} = ft_freqstatistics(cfg, tot_tfr2_bl{3}{:}, > > tot_tfr2_bl{4}{:}); % Semantics > > stat_tfr{3} = ft_freqstatistics(cfg, tot_tfr2_bl{5}{:}, > > tot_tfr2_bl{6}{:}); % Morphosyntax > > > > This is the plotting code. Again, it is virtually the same for the ERPs > > except the non-stats configurations would be what makes sense for ERPs. > > > > % Anomaly vs Control TFR stats multiplot > > > > cfg = []; > > cfg.xlim = [-0.2 1]; > > cfg.zlim = [-3 3]; % proportion from baseline > > cfg.layout = [max_dir '/quickcap64.mat']; > > cfg.maskparameter = 'mask'; > > cfg.parameter = 'stat'; > > cfg.maskalpha = 0.025; > > > > ft_multiplotTFR(cfg, stat_tfr{1}); title('Preposition'); > > ft_multiplotTFR(cfg, stat_tfr{3}); title('Semantic'); > > ft_multiplotTFR(cfg, stat_tfr{5}); title('Morphosyntactic'); > > > > > > 2. The second question is about analyzing baselined vs unbaselined data. > > I've seen in the tutorials that there is a somewhat different method for > > analyzing trial vs baseline period. However, what I've done instead (for > > both ERP and TFR), is use the same within-subjects statistics as with > > anomaly vs control, except with the inputs being baselined vs unbaselined > > ERPs or TFRs, e.g. Baselined Preposition Anomaly vs Unbaselined > Preposition > > Anomaly, etc. I understand that the proposed method and my method are not > > testing the same thing exactly, but is this a reasonable way of testing > the > > effect of the baselining anyway? > > > > Thanks, > > > > Max > > > > -- > > Max Cantor > > Graduate Student > > Cognitive Neuroscience of Language Lab > > University of Colorado Boulder > > > > > > -- > Max Cantor > Graduate Student > Cognitive Neuroscience of Language Lab > University of Colorado Boulder > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: < > http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160415/4cd234cd/attachment-0001.html > > > > ------------------------------ > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > End of fieldtrip Digest, Vol 65, Issue 14 > ***************************************** > -------------- next part -------------- An HTML attachment was scrubbed... URL: From seymourr at aston.ac.uk Mon Apr 18 11:13:29 2016 From: seymourr at aston.ac.uk (Seymour, Robert (Research Student)) Date: Mon, 18 Apr 2016 09:13:29 +0000 Subject: [FieldTrip] Recombining Trials for Source Analysis Message-ID: Dear Fieldtrippers, I am trying to use an LCMV beamformer to project 5 minutes of resting state data to the source level. During my data cleaning procedure I segment my continuous recording into 1 second "trials" and reject those with high amplitudes (using the ft_rejectvisual summary window). However I would then like to recombine these "trials" (to make 1 long "trial") before I do ft_timelockanalysis. Is there a way to do this whilst keeping the Fieldtrip structure intact . My current code is below: % Segment into 1s chunks. Input is preprocessed variable called data. cfg = []; cfg.length = 1; cfg.overlap = 0; data_segmented = ft_redefinetrial(cfg,data); % Reject deviant trials cfg = []; cfg.method = 'summary'; cfg.keepchannel = 'yes'; cfg.channel = 'MEGMAG'; clean1 = ft_rejectvisual(cfg,data_segmented); % Now load this cfg.channel = 'MEGGRAD'; clean2 = ft_rejectvisual(cfg,clean1); data_clean_rs = clean2 clear clean1 clean2 save data_clean_rs data_clean_rs % Now to recombine trials data_clean_rs.trial = horzcat(data_clean_rs.trial{1,:}); % (This distorts the fieldtrip structure meaning ft_timelockanalysis doesn't work) Many thanks, Robert -------------- next part -------------- An HTML attachment was scrubbed... URL: From magazzinil at gmail.com Mon Apr 18 11:24:48 2016 From: magazzinil at gmail.com (Lorenzo Magazzini) Date: Mon, 18 Apr 2016 10:24:48 +0100 Subject: [FieldTrip] Recombining Trials for Source Analysis In-Reply-To: References: Message-ID: Hi Robert, I'm not sure, but my guess would be that you need to adjust the .time field in your data_clean_rs structure, so that it matches the length of the .trial field. Best wishes, Lorenzo Lorenzo Magazzini PhD Student magazzinil at cardiff.ac.uk CUBRIC Building Maindy Road Cardiff CF24 4HQ On 18 April 2016 at 10:13, Seymour, Robert (Research Student) < seymourr at aston.ac.uk> wrote: > Dear Fieldtrippers, > > > I am trying to use an LCMV beamformer to project 5 minutes of resting > state data to the source level. During my data cleaning procedure I segment > my continuous recording into 1 second "trials" and reject those with high > amplitudes (using the ft_rejectvisual summary window). However I would then > like to recombine these "trials" (to make 1 long "trial") before I do > ft_timelockanalysis. Is there a way to do this whilst keeping the Fieldtrip > structure intact . My current code is below: > > > % Segment into 1s chunks. Input is preprocessed variable called data. > > cfg = []; > > cfg.length = 1; > > cfg.overlap = 0; > > data_segmented = ft_redefinetrial(cfg,data); > > > % Reject deviant trials > > cfg = []; > > cfg.method = 'summary'; > > cfg.keepchannel = 'yes'; > > cfg.channel = 'MEGMAG'; > > clean1 = ft_rejectvisual(cfg,data_segmented); > > % Now load this > > cfg.channel = 'MEGGRAD'; > > clean2 = ft_rejectvisual(cfg,clean1); > > data_clean_rs = clean2 > > > clear clean1 clean2 > > save data_clean_rs data_clean_rs > > > % Now to recombine trials > > data_clean_rs.trial = horzcat(data_clean_rs.trial{1,:}); % (This distorts > the fieldtrip structure meaning ft_timelockanalysis doesn't work) > > > > Many thanks, > > > Robert > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From mi_mayer at gmx.de Tue Apr 19 20:07:09 2016 From: mi_mayer at gmx.de (Irene Sophia Mayer) Date: Tue, 19 Apr 2016 20:07:09 +0200 Subject: [FieldTrip] ft_channelrepair: index exceeds matrix dimensions Message-ID: An HTML attachment was scrubbed... URL: From XDu at mprc.umaryland.edu Tue Apr 19 20:38:10 2016 From: XDu at mprc.umaryland.edu (Xiaoming Du) Date: Tue, 19 Apr 2016 14:38:10 -0400 Subject: [FieldTrip] ft_channelrepair: index exceeds matrix dimensions In-Reply-To: References: Message-ID: <571642D3020000DC0001A139@MPRC.UMARYLAND.EDU> Hello, I am not a fieldtrip expert, but I happen to use ft_channelrepair recently. In you code, does the 'data' have FT9 or CP6? Are those electrodes missing or bad? If you construct neighbours based on less number of electrodes, you may still lack the neighbour-info to interpolate them. I suggest to check the dimension of neighbours and see if it contains the neighbours info for all electrodes (especially for FT9 and CP6). Also, you can try cfg.missingchannel instead of cfg.badchannel and see if that helps. p.s., in my case, I used a good data (meaning without missing or bad channels) to create the neighbours and use it for all others dataset with same type of EEG caps. Best, Xiaoming >>> "Irene Sophia Mayer" 4/19/2016 2:07 PM >>> Dear fieldtrippers, When trying to repair bad channels, I get the following error message: Index exceeds matrix dimensions. Error in ft_channelrepair (line 177) goodsensindx = a(b); Error in prepro_neu (line 129) data = ft_channelrepair(cfg,data); This seems to happen for specific channels, e.g. 'FT9' and 'CP6', but the script works fine, if I don't try to interpolate those channels. Any ideas what the problem could be? My code: cfg = []; cfg.method = 'template'; cfg.layout = 'EEG1010.lay'; cfg.feedback = 'yes'; neighbours = ft_prepare_neighbours(cfg,data); cfg = []; cfg.method = 'average'; % 'nearest', 'average', 'spline' or 'slap' (default='nearest') cfg.badchannel = bad_chan{x}; % predefined list of channels cfg.elec = ft_read_sens('path'); cfg.neighbours = neighbours; cfg.trials = 'all'; cfg.lambda = 1e-5; cfg.order = 4; data = ft_channelrepair(cfg,data); -------------- next part -------------- An HTML attachment was scrubbed... URL: From anne.urai at gmail.com Wed Apr 20 08:19:44 2016 From: anne.urai at gmail.com (Anne Urai) Date: Wed, 20 Apr 2016 08:19:44 +0200 Subject: [FieldTrip] ft_megrealign - complete CTF275 grad struct wanted Message-ID: Dear Fieldtrippers, tl;dr 1. I'm looking for a gradiometer structure that includes coils (so a subject or dummy measurement) with *all* squids present.  2. Can I rename the CTF HLC0011 etc... to {'nasX';'nasY';'nasZ';'lpaX';'lpaY';'lpaZ';'rpaX';'rpaY';'rpaZ'}? --------- 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.  After making the headmodel (and ensuring it's aligned with the gradiometers), this works quite well: % realign to template sensor positions cfg             = []; cfg.template    = {'ctf275.mat'};  cfg.headmodel   = headmodel;   % For a realistic single-shell volume conduction model based on the brain surface, you % should probably use an inward shift of about 1 cm. cfg.inwardshift  = 1; cfg.feedback     = 'no'; data2            = ft_megrealign(cfg, data); 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 ftp://ftp.fieldtriptoolbox.org/pub/fieldtrip/example/megrealign, 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. 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. 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.  In ft_headmovement (and also buried somewhere in the CTF documentation), I could find % HLC0011 HLC0012 HLC0013 x, y, z coordinates of nasion-coil in m. % HLC0021 HLC0022 HLC0023 x, y, z coordinates of lpa-coil in m. % HLC0031 HLC0032 HLC0033 x, y, z coordinates of rpa-coil in m. 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.  Thanks! —  Anne E. Urai, MSc PhD student | Institut für Neurophysiologie und Pathophysiologie  Universitätsklinikum Hamburg-Eppendorf | Martinistrasse 52, 20246 | Hamburg, Germany  www.anneurai.net / @AnneEUrai -------------- next part -------------- An HTML attachment was scrubbed... URL: From mi_mayer at gmx.de Wed Apr 20 09:07:15 2016 From: mi_mayer at gmx.de (Irene Sophia Mayer) Date: Wed, 20 Apr 2016 09:07:15 +0200 Subject: [FieldTrip] ft_channelrepair: index exceeds matrix dimensions In-Reply-To: <571642D3020000DC0001A139@MPRC.UMARYLAND.EDU> References: , <571642D3020000DC0001A139@MPRC.UMARYLAND.EDU> Message-ID: An HTML attachment was scrubbed... URL: From XDu at mprc.umaryland.edu Wed Apr 20 11:19:23 2016 From: XDu at mprc.umaryland.edu (Xiaoming Du) Date: Wed, 20 Apr 2016 05:19:23 -0400 Subject: [FieldTrip] ft_channelrepair: index exceeds matrix dimensions In-Reply-To: References: , <571642D3020000DC0001A139@MPRC.UMARYLAND.EDU> Message-ID: <5717115B020000DC0001A158@MPRC.UMARYLAND.EDU> Hi Irene, Here is the code I used: cfg = []; cfg.method = 'triangulation' cfg.senstype = 'EEG' neighbours_66 = ft_prepare_neighbours(cfg, data_intact); cfg = []; cfg.method = 'average'; cfg.neighbours = neighbours_66; cfg.missingchannel = missingChann; cfg.senstype = 'EEG'; data_clean = ft_channelrepair(cfg, data); Here is an example from Fieldtrip website http://www.fieldtriptoolbox.org/tutorial/natmeg/timefrequency?s[]=ft&s[]=channelrepair Regards, Xiaoming >>> "Irene Sophia Mayer" 4/20/2016 3:07 AM >>> Hello, The data does always have those channels, they are bad and not missing. All electrodes have neighbours assigned to them and I'm doing this on the original data without having changed anything before that. Did you use the same code as I did? Best, Irene Gesendet: Dienstag, 19. April 2016 um 20:38 Uhr Von: "Xiaoming Du" An: fieldtrip at science.ru.nl Betreff: Re: [FieldTrip] ft_channelrepair: index exceeds matrix dimensions Hello, I am not a fieldtrip expert, but I happen to use ft_channelrepair recently. In you code, does the 'data' have FT9 or CP6? Are those electrodes missing or bad? If you construct neighbours based on less number of electrodes, you may still lack the neighbour-info to interpolate them. I suggest to check the dimension of neighbours and see if it contains the neighbours info for all electrodes (especially for FT9 and CP6). Also, you can try cfg.missingchannel instead of cfg.badchannel and see if that helps. p.s., in my case, I used a good data (meaning without missing or bad channels) to create the neighbours and use it for all others dataset with same type of EEG caps. Best, Xiaoming >>> "Irene Sophia Mayer" 4/19/2016 2:07 PM >>> Dear fieldtrippers, When trying to repair bad channels, I get the following error message: Index exceeds matrix dimensions. Error in ft_channelrepair (line 177) goodsensindx = a(b); Error in prepro_neu (line 129) data = ft_channelrepair(cfg,data); This seems to happen for specific channels, e.g. 'FT9' and 'CP6', but the script works fine, if I don't try to interpolate those channels. Any ideas what the problem could be? My code: cfg = []; cfg.method = 'template'; cfg.layout = 'EEG1010.lay'; cfg.feedback = 'yes'; neighbours = ft_prepare_neighbours(cfg,data); cfg = []; cfg.method = 'average'; % 'nearest', 'average', 'spline' or 'slap' (default='nearest') cfg.badchannel = bad_chan{x}; % predefined list of channels cfg.elec = ft_read_sens('path'); cfg.neighbours = neighbours; cfg.trials = 'all'; cfg.lambda = 1e-5; cfg.order = 4; data = ft_channelrepair(cfg,data); _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From elmeri.syrjanen at gmail.com Wed Apr 20 14:05:20 2016 From: elmeri.syrjanen at gmail.com (=?UTF-8?Q?Elmeri_Syrj=C3=A4nen?=) Date: Wed, 20 Apr 2016 14:05:20 +0200 Subject: [FieldTrip] Plotting combining figures Message-ID: Dear all, I'am trying to build a figure in Matlab composed of multiple elements. For example I would like to have a upper part of the figure with mean amplitudes and CIs. The lower part of the figure would be composed of the output from ft_singleplotER and ft_clusterplot. Is this possible? So far i tried various combinations of the set(), hold and subplot() commands in Matlab. I suspect that the problem arises from that FieldTrip creates a new figure each time one of the plotting functions are called. Is there a handle to the figure that is created? It would be great if this would be possible. The advantage is obvious if it's possible to build the complete figure in Matlab with consistent font sizes etc. /elmeri -------------- next part -------------- An HTML attachment was scrubbed... URL: From fosco.bernasconi at gmail.com Wed Apr 20 14:53:32 2016 From: fosco.bernasconi at gmail.com (fosco bernasconi) Date: Wed, 20 Apr 2016 14:53:32 +0200 Subject: [FieldTrip] ft_sourceplot NaN, connectivity degree Message-ID: Dear list, I am trig to plot the connectivity degree of my beamforming sources, after interpolation. What happens, is that also the NaN values outside the headmodel are plotted (see figure below). Is there an easy fix for this? or did I do some errors in my computation? My code: cfg = []; cfg.method = 'ortho'; cfg.funparameter = 'degrees'; cfg.maskparameter = 'mask'; cfg.funcolormap = 'jet'; cfg.location = 'max'; ft_sourceplot(cfg,source_degint_S); and my data structure: source_degint_S = anatomy: [91x109x91 double] coordsys: 'spm' dim: [91 109 91] transform: [4x4 double] unit: 'mm' inside: [91x109x91 logical] degrees: [91x109x91 double] cfg: [1x1 struct] Thanks a lot in advance! fosco [image: Immagine incorporata 2] -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: Screenshot from 2016-04-20 13:38:28.png Type: image/png Size: 74696 bytes Desc: not available URL: From icelandhouse at gmail.com Wed Apr 20 17:11:24 2016 From: icelandhouse at gmail.com (Maris Skujevskis) Date: Wed, 20 Apr 2016 17:11:24 +0200 Subject: [FieldTrip] why are grid points located outside the brain? Message-ID: Dear Fieldtrip users, Can someone please explain the reason why in the tutorial http://www.fieldtriptoolbox.org/tutorial/sourcemodel (or in general, for that matter) the outer layer of grid points of the source model lie outside the brain though they are defined as being inside? This is what I am refering to: http://www.fieldtriptoolbox.org/_detail/example/mnispace/mni_fig1a.png?id=tutorial%3Asourcemodel http://www.fieldtriptoolbox.org/_detail/example/mnispace/mni_fig2b.png?id=tutorial%3Asourcemodel According to my naive understanding, this means that in this model the potential neural sources may also lie outside the brain, which makes no sense. Clearly, I am missing something here... Thanks! Maris -------------- next part -------------- An HTML attachment was scrubbed... URL: From nicholas.balderston at nih.gov Wed Apr 20 23:27:00 2016 From: nicholas.balderston at nih.gov (Balderston, Nicholas (NIH/NIMH) [F]) Date: Wed, 20 Apr 2016 21:27:00 +0000 Subject: [FieldTrip] why are grid points located outside the brain? In-Reply-To: References: Message-ID: Dear all, Thanks for the question Maris, I have been wondering the same. Along those lines, I was wondering if it is appropriate to scale the resulting beamformer grids to match the size of the MNI template after the fact? thanks, -nick ________________________________ From: Maris Skujevskis [icelandhouse at gmail.com] Sent: Wednesday, April 20, 2016 11:11 AM To: fieldtrip at science.ru.nl Subject: [FieldTrip] why are grid points located outside the brain? Dear Fieldtrip users, Can someone please explain the reason why in the tutorial http://www.fieldtriptoolbox.org/tutorial/sourcemodel (or in general, for that matter) the outer layer of grid points of the source model lie outside the brain though they are defined as being inside? This is what I am refering to: http://www.fieldtriptoolbox.org/_detail/example/mnispace/mni_fig1a.png?id=tutorial%3Asourcemodel http://www.fieldtriptoolbox.org/_detail/example/mnispace/mni_fig2b.png?id=tutorial%3Asourcemodel According to my naive understanding, this means that in this model the potential neural sources may also lie outside the brain, which makes no sense. Clearly, I am missing something here... Thanks! Maris -------------- next part -------------- An HTML attachment was scrubbed... URL: From muthuraman10 at hotmail.com Fri Apr 22 14:19:33 2016 From: muthuraman10 at hotmail.com (Muthuraman Muthuraman) Date: Fri, 22 Apr 2016 12:19:33 +0000 Subject: [FieldTrip] PhD Position on Brian Imaging in Multiple Sclerosis! Message-ID: Doctoral Student Neuroscientist with focus on brain imaging in multiple sclerosis diagnosis The medical faculty of the University of Mainz, Germany, invites applications for a PhD Student for a functional translational neuroscience (FTN) scholarship three year position to work on the Multiple sclerosis imaging with modalities like structural MRI, diffusion tensor imaging, functional magnetic resonance imaging and Electro encephalography (EEG). The successful applicant holds a Master’s degree (or equivalent) in a relevant academic area such as basic life sciences, neuropsychology, applied mathematics, computer science or biomedical engineering or similar disciplines. The working language at the institute is English. Experience with brain imaging and the analysis of brain signals is advantageous, but not essential. The applicant’s merits are assessed on the basis of the quality of Master’s level studies and thesis, previous experience with the brain imaging, motivation and research interests. The location for this research will mainly be the workgroups “Section of movement disorders, neurostimulation and neuroimaging“ of Prof. Sergiu Groppa at the Department of Neurology and “Multimodal signal processing and statistical analyses” of Prof. Muthuraman Muthuraman, both at the Focus Program Translational Neurosciences (http://www.ftn.uni-mainz.de/) and Neuroimaging Centre Mainz (http://www.ftn.nic.uni-mainz.de/). Expected close collaborations with national and international partners. The application should include a statement of research interests and reasons for applying to the project, a curriculum vitae (max. 4 pages) composed according to good scientific practice, a certificate of Master’s degree, copy of the master’s thesis and grades of Master’s level studies, the names and e-mail addresses of two referees and a proof of proficiency in English. The position will be open until filled. To apply for the position, please send the above documents as pdfs until 15.05.2016 to Prof. Sergiu Groppa, Department of Neurology, Section of movement disorders and neurostimulation, University of Mainz, Langenbeckstrasse 1, 55131 Mainz, Germany, or by Email to segroppa(at)uni-mainz.de. For additional information please contact Sergiu Groppa. -------------- next part -------------- An HTML attachment was scrubbed... URL: From 9605 at eng.asu.edu.eg Fri Apr 22 16:52:36 2016 From: 9605 at eng.asu.edu.eg (Mina Romany Meshriky) Date: Fri, 22 Apr 2016 14:52:36 +0000 Subject: [FieldTrip] FW: From a .csv data file, to a recognized dataset by fieldtrip In-Reply-To: <006c01d19ca6$65683f50$3038bdf0$@gmail.com> References: <006c01d19ca6$65683f50$3038bdf0$@gmail.com> Message-ID: Dears, My name is Mina, and I am working with event related potentials. I think my question is somehow basic but, it's been a day and I am still stuck. I am working with the Emotiv Epoc device, and I am using Labview and Matlab for real time acquisition and processing. Until recently I was using my own functions to read and process the data, however now I would like to use the fieldtrip toolbox. When I receive data from the device using Labview I store it directly to a .csv file and then start the processing on Matlab I would like to change this .csv file to a format recognized by field trip What I have separately now is 1- The data 2- The channel names 3- The channel locations 4- The markers 5- The sampling frequency Best Regards Mina Meshriky -------------- next part -------------- An HTML attachment was scrubbed... URL: From WILLIAM.DEWISPELAERE at UCDENVER.EDU Fri Apr 22 18:27:11 2016 From: WILLIAM.DEWISPELAERE at UCDENVER.EDU (Dewispelaere, William B) Date: Fri, 22 Apr 2016 16:27:11 +0000 Subject: [FieldTrip] ft_sourceinterpolate and ft_sourcestatistics outputs Message-ID: Hey all, I have a few questions about the output that results from ft_sourceinterpolate and ft_sourcestatistics. For some background, I ran ft_sourcestatistics on un-interpolated data in order to save some memory space. I then interpolated this stat output onto my realigned and resliced anatomical MRI. Everything looks alright, I just want to know: 1) Positive vs negative clusters - I'm assuming positive clusters are where condition 1 (as defined in the design matrix) is greater than condition 2 (I only have 2 conditions). Correct me if I'm wrong! 2) The 'prob' field - Before I interpolate my ft_sourcestatistics output, the 'prob' field contains the p-values for each voxel. After interpolation, I'm not sure what the 'prob' field is, since the values range from above 1 to below -1. If someone could clarify the meaning of these values, that would make my day. Thanks! Will -------------- next part -------------- An HTML attachment was scrubbed... URL: From laxmi.shaw22 at gmail.com Fri Apr 22 19:05:40 2016 From: laxmi.shaw22 at gmail.com (Laxmi Shaw) Date: Fri, 22 Apr 2016 22:35:40 +0530 Subject: [FieldTrip] Fieldtrip_issues Message-ID: Dear list, I am having an situation . I am having data in excels file which i have converted to.mat file. The file content as each columns indicates number of channels and the data points are indicates the corresponding amplitude. I want to use ft_topoplotER and ft_clusterplot,for that i need to convert .mat to structure file . How can i use topoplot in that way. Could you please help me in this regard. Thanks and Regards -- Laxmi Shaw Research Scholar(PhD) IIT Kharagpur West Bengal Ph no-08388837821 -------------- next part -------------- An HTML attachment was scrubbed... URL: From dlozanosoldevilla at gmail.com Fri Apr 22 19:27:38 2016 From: dlozanosoldevilla at gmail.com (Diego Lozano-Soldevilla) Date: Fri, 22 Apr 2016 19:27:38 +0200 Subject: [FieldTrip] Fieldtrip_issues In-Reply-To: References: Message-ID: Dear Laxmi, These two pages should definitely help you: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat http://www.fieldtriptoolbox.org/getting_started best, Diego On 22 April 2016 at 19:05, Laxmi Shaw wrote: > Dear list, > I am having an situation . I am having data in excels file which i have > converted to.mat file. The file content as each columns indicates number of > channels and the data points are indicates the corresponding amplitude. I > want to use ft_topoplotER and ft_clusterplot,for that i need to convert > .mat to structure file . How can i use topoplot in that way. Could you > please help me in this regard. > > > > > Thanks and Regards > > -- > Laxmi Shaw > Research Scholar(PhD) > IIT Kharagpur > West Bengal > Ph no-08388837821 > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From gaur-p at email.ulster.ac.uk Fri Apr 22 19:34:09 2016 From: gaur-p at email.ulster.ac.uk (Pramod Gaur) Date: Fri, 22 Apr 2016 18:34:09 +0100 Subject: [FieldTrip] Fieldtrip_issues In-Reply-To: References: Message-ID: <2099a01d19cbd$2f7b3250$8e7196f0$@email.ulster.ac.uk> Dear Users, I am newbie to fieldtrip and just wanted to analyse BCI competition IV datasets. I have seen many format are mentioned but nothing is given for GDF format. Could you please help me and point me to the correct link, so I can start working on EEG data. Best regards, Pramod From: fieldtrip-bounces at science.ru.nl [mailto:fieldtrip-bounces at science.ru.nl] On Behalf Of Diego Lozano-Soldevilla Sent: 22 April 2016 18:28 To: FieldTrip discussion list Subject: Re: [FieldTrip] Fieldtrip_issues Dear Laxmi, These two pages should definitely help you: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat http://www.fieldtriptoolbox.org/getting_started best, Diego On 22 April 2016 at 19:05, Laxmi Shaw > wrote: Dear list, I am having an situation . I am having data in excels file which i have converted to.mat file. The file content as each columns indicates number of channels and the data points are indicates the corresponding amplitude. I want to use ft_topoplotER and ft_clusterplot,for that i need to convert .mat to structure file . How can i use topoplot in that way. Could you please help me in this regard. Thanks and Regards -- Laxmi Shaw Research Scholar(PhD) IIT Kharagpur West Bengal Ph no-08388837821 _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From sauer.mpih at googlemail.com Sun Apr 24 18:36:06 2016 From: sauer.mpih at googlemail.com (Andreas Sauer) Date: Sun, 24 Apr 2016 18:36:06 +0200 Subject: [FieldTrip] Why does ft_selectdata remove "pow" from sourcedata during statistics? Message-ID: Dear all, unfortunately, I am having problems to run source statistics on ERF mismatch negativity data (recorded with a 4D system). With the following data structure as input (output from ft_sourcegrandaverage), fieldtrip gives a warning that it „could not determine dimord of „pow“ in the following data“ pow: [16x37696 double] dim: [31 38 32] inside: [37696x1 logical] pos: [37696x3 double] time: [1x900 double] cfg: [1x1 struct] and later throws an error that „field „pow“ (is) not present in data“. I checked the ft_sourcestatistic script step by step and found out that ft_selectdata removes it after being called by ft_sourcestatistics. I am using the fieldtrip version from 15/05/2015. I also tried with older versions, one from late 2014 and late 2013, but nothing worked. Unfortunately, since ft_selectdata removes the field "pow" from the data during the call to ft_sourcestatistic, I can’t put it back in to the structure. Any help with this (esp. why „pow“ is being removed) is highly appreciated! Thanks and best wishes, Andreas -- Dipl.-Psych. Andreas Sauer Max Planck Institute for Brain Research Deutschordenstraße 46 60528 Frankfurt am Main Germany T: +49 69 96769 278 F: +49 69 96769 327 Email: sauer.mpih at gmail.com www.brain.mpg.de -------------- next part -------------- An HTML attachment was scrubbed... URL: From pantev at uni-muenster.de Mon Apr 25 11:18:51 2016 From: pantev at uni-muenster.de (Christo Pantev) Date: Mon, 25 Apr 2016 11:18:51 +0200 Subject: [FieldTrip] Full Professor (W3 Position) for Biomagnetism and Biosignalanalysis with focus on Magnetoencephalography and Multimodal Imaging of Neural Systems Message-ID: Dear colleagues, The Medical Faculty of the University of Münster offers the position of a Full Professor (W3) for "Biomagnetism and Biosignalanalysis with focus on Magnetoencephalography and Multimodal Imaging of Neural Systems” at the nearest possible time. The Institute for Biomagnetism and Biosignalanalysis of the University of Münster has an excellent structure and it is “state-of-the art” equipped. Therefore I would like to encourage all qualified colleagues to apply. Furthermore, Münster is a wonderful city to live! The Medical Faculty of the University of Münster offers the position of a Full Professor (W3) for Biomagnetism and Biosignalanalysis with focus on Magnetoencephalography and Multimodal Imaging of Neural Systems at the nearest possible time. The position is an appointment as a Head of the Institute for Biomagnestism and Biosignalanalysis at the Medical Faculty Münster. The holder of this position-to-be (she/he) should have the ability to represent the discipline entirely in research and teaching as well. The candidates should have medical or natural science training and an outstanding qualification in scientific research and teaching. An internationally recognized research profile in application of Magnetoencephalography and other Neuroimaging-Methods in particular EEG, MRI/fMRI, TMS/tDCS, PET are expected. Beside the ability to formulate and solve theoretical and analytical tasks, a successful cooperation with the clinical neuro-scientific research field of the Faculty is presumed. The active collaboration with the scientific main topic oft the faculty “Neural Systems” is explicitly required. Further important criteria are excellent research- and publication-records. Likewise, convincing experience in modern scientific management, particularly in raising of national and international scientific funds, ability for collaboration, interdisciplinarity, and administrative and social competence are requirements for application. The scientific networking and close cooperation with adjacent disciplines are expected. The Medical Faculty anticipates a collaboration with existing research foci and research associations e.g. the excellence cluster “Cells in motion” (EXC 1003), the interdisciplinary clinical research center (IZKF), the center for clinical studies (ZKS), the existing research associations (SFB) and the MPI “Molecular biomedicine”. Prerequisites for the application are scientific achievements, which have been yielded within Junior-Professorship, Habilitation, or scientific work at university or non-university institutions. We point additionally on the required qualification given in § 36 of the Hochschulgesetz. The University of Münster is an equal opportunity employer and is committed to increasing the proportion of senior female academics. Consequently, we actively encourage applications by women. Female candidates with equivalent qualifications and academic achievements will be preferentially considered within the framework of the legal possibilities. We also welcome applications from candidates with severe disabilities. Disabled candidates with equivalent qualifications will be preferentially considered. Applications including the standard documents (CV, scientific career, structured publication list, raised funds) inclusively the summary of the teaching accomplishments with detailed and profound teaching concept together with reprints of the six most important publications should be submitted to the Dean of the Medical Faculty, Westfälische Wilhelms-Universität Münster, Albert-Schweitzer-Campus 1, Gebäude D3, 48149 Münster, by 27.05.2016. Please take into account the hints about Professorial Nominations at our website: www.campus.uni-muenster.de . Best regards --- Univ.-Prof. Dr. Christo Pantev Direktor des Instituts für Biomagnetismus und Biosignalanalyse WWU Münster Adjunct Professor Rotman Research Institute for Neuroscience University of Toronto, Canada Malmedyweg 15 D-48149 Münster Telefon: +49 (0)251 83 56865 (56885) fax: +49 (0)251 83 56874 E-Mail: pantev at uni-muenster.de http://biomag.uni-muenster.de -------------- next part -------------- An HTML attachment was scrubbed... URL: From j.brehm at uu.nl Mon Apr 25 15:55:53 2016 From: j.brehm at uu.nl (Brehm, J. (Julia)) Date: Mon, 25 Apr 2016 13:55:53 +0000 Subject: [FieldTrip] Problems with filterpadding in ft_artifact_zvalue Message-ID: <385DDA785CF9764B8E184EF28D01ADE05995E2@WP0046.soliscom.uu.nl> Dear list, I am currently working on implementing an automatic artifact rejection using ft_artifact_zvalue. It already works quite nicely for detecting jumps and EOG artifacts. However, when trying to detect high frequency noise I am often getting edge effects. I am already using filterpadding for the eog artifacts were it does a good job, but for the higher frequencies it suddenly almost only detects artifacts at the outermost trials (first and last) even though there are also obvious artifacts in different trials. The data is previously demeaned and filtered using a notch filter and a bandpass filter from 1-100 Hz. These are my settings for the artifact detection now: cfg = []; cfg.trl = temptrl; % all trials in this case cfg.artfctdef.zvalue.channel = channel{ch}; % single channel cfg.artfctdef.zvalue.cutoff = 3; cfg.artfctdef.zvalue.fltpadding = 0.1; cfg.artfctdef.zvalue.bpfilter = 'yes'; cfg.artfctdef.zvalue.bpfilttype = 'but'; cfg.artfctdef.zvalue.bpfreq = [70 100]; cfg.artfctdef.zvalue.bpfiltord = 2; cfg.artfctdef.zvalue.hilbert = 'yes'; cfg.artfctdef.zvalue.boxcar = 0.2; [cfg, artifact] = ft_artifact_zvalue(cfg, data); I already tried changing the settings around but that didn't do much good. Any help would be appreciated and please tell me if I am doing anything terribly wrong! Best, Julia -------------- next part -------------- An HTML attachment was scrubbed... URL: From icelandhouse at gmail.com Mon Apr 25 23:51:34 2016 From: icelandhouse at gmail.com (Maris Skujevskis) Date: Mon, 25 Apr 2016 23:51:34 +0200 Subject: [FieldTrip] transformation matrix Message-ID: Dear Fieldtrip users, A quick simple question (maybe it's been answered somewhere already but really I cannot find it...) Functions like ft_read_mri and ft_volumerealign attach the field 'transform' (a 4 x 4 matrix) to the data structure ( http://www.fieldtriptoolbox.org/faq/how_to_coregister_an_anatomical_mri_with_the_gradiometer_or_electrode_positions ) My question is: what operations do each of the values in this transformation matrix correspond to? Thanks for your help! Maris -------------- next part -------------- An HTML attachment was scrubbed... URL: From jorn at artinis.com Tue Apr 26 09:26:25 2016 From: jorn at artinis.com (=?UTF-8?Q?J=C3=B6rn_M._Horschig?=) Date: Tue, 26 Apr 2016 09:26:25 +0200 Subject: [FieldTrip] transformation matrix In-Reply-To: References: Message-ID: <003301d19f8c$f1442d70$d3cc8850$@artinis.com> Hi Maris, The transformation matrix contains the rotation, scaling (so to say, the upper-left 3x3 matrix) and other components, e.g. a translational component (the 4th column). You can think of the fourth row as a sort of a mathematical trick to end up with a square matrix, making a lot of operations easier and computationally more efficient. This 4x4 transformation matrix is actually called a projection matrix (widely used in 3D programming), and there the 4th row actually plays a big role in perspective mapping (e.g. being able to make objects farther away seem smaller). This explanation should be roughly correct - I am not a mathematician though ;) Best regards, Jörn -- Jörn M. Horschig, PhD, Software Engineer Artinis Medical Systems | +31 481 350 980 From: fieldtrip-bounces at science.ru.nl [mailto:fieldtrip-bounces at science.ru.nl] On Behalf Of Maris Skujevskis Sent: Monday, April 25, 2016 23:52 To: fieldtrip at science.ru.nl Subject: [FieldTrip] transformation matrix Dear Fieldtrip users, A quick simple question (maybe it's been answered somewhere already but really I cannot find it...) Functions like ft_read_mri and ft_volumerealign attach the field 'transform' (a 4 x 4 matrix) to the data structure ( http://www.fieldtriptoolbox.org/faq/how_to_coregister_an_anatomical_mri_with_the_gradiometer_or_electrode_positions ) My question is: what operations do each of the values in this transformation matrix correspond to? Thanks for your help! Maris -------------- next part -------------- An HTML attachment was scrubbed... URL: From zsoltturi at gmail.com Tue Apr 26 14:14:34 2016 From: zsoltturi at gmail.com (Zsolt Turi) Date: Tue, 26 Apr 2016 14:14:34 +0200 Subject: [FieldTrip] cluster plot Message-ID: Dear Filedtrip users, I recently performed a non-parametric cluster-based permutation test on time-frequency data using a within-subjects design. I have two related questions/issues: 1) Size issues: For 11 participants the size of the file containing the time-frequency grand averages is 1.4 GB for each condition (I have two conditions), which is really hard to load in for the permutation test. Is this size reasonable? powspctrm: [4-D double] label: {64x1 cell} freq: [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20] time: [1x26 double] dimord: 'subj_chan_freq_time' cfg: [1x1 struct] 2) Cluster plot issue: Related to the first issue, after generating the plots for the stat, the computer stops responding and it is impossible to save the figure or even close it. cfg = []; cfg.alpha = 0.05; cfg.parameter = 'stat'; cfg.zlim = [-4 4]; cfg.layout = 'EEG1010.lay'; ft_clusterplot(cfg, stat); Have some of you encountered such kind of issues? I use 64 bit Win 7 OS, 8 GB RAM, Intel Core i5 CPU, 9.0.0.341360 (R2016a) Matlab and fieldtrip-20160424 versions. Thanks for your help in advance! Zsolt -------------- next part -------------- An HTML attachment was scrubbed... URL: From p.taesler at uke.de Tue Apr 26 14:45:03 2016 From: p.taesler at uke.de (Philipp Taesler) Date: Tue, 26 Apr 2016 14:45:03 +0200 Subject: [FieldTrip] cluster plot In-Reply-To: References: Message-ID: <571F62CF.6000201@uke.de> Hi Zsolt, I've had some similar problems with data from a very long analysis pipeline. It also failed to plot. A quick and dirty solution for me was to get rid of the "cfg" field in the struct, as it had somehow accumulated lots of data. newdata = rmfield(olddata, 'cfg'); Maybe this will help, otherwise I'm out of ideas for now :) Cheers, Phil Am 26.04.2016 um 14:14 schrieb Zsolt Turi: > Dear Filedtrip users, > > I recently performed a non-parametric cluster-based permutation test on > time-frequency data using a within-subjects design. I have two related > questions/issues: > > 1) Size issues: > > For 11 participants the size of the file containing the time-frequency > grand averages is 1.4 GB for each condition (I have two conditions), > which is really hard to load in for the permutation test. Is this size > reasonable? > > > powspctrm: [4-D double] > label: {64x1 cell} > freq: [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20] > time: [1x26 double] > dimord: 'subj_chan_freq_time' > cfg: [1x1 struct] > > > 2) Cluster plot issue: > > Related to the first issue, after generating the plots for the stat, the > computer stops responding and it is impossible to save the figure or > even close it. > > cfg = []; > cfg.alpha = 0.05; > cfg.parameter = 'stat'; > cfg.zlim = [-4 4]; > cfg.layout = 'EEG1010.lay'; > ft_clusterplot(cfg, stat); > > Have some of you encountered such kind of issues? > > > I use 64 bit Win 7 OS, 8 GB RAM, Intel Core i5 CPU, 9.0.0.341360 > (R2016a) Matlab and fieldtrip-20160424 versions. > > Thanks for your help in advance! > > Zsolt -- Philipp Taesler Department of Systems Neuroscience University Medical Center Hamburg-Eppendorf Martinistr. 52, W34, 20248 Hamburg, Germany Phone: +49-40-7410-59902 Fax: +49-40-7410-59955 Email: p.taesler at uke.de -- _____________________________________________________________________ Universitätsklinikum Hamburg-Eppendorf; Körperschaft des öffentlichen Rechts; Gerichtsstand: Hamburg | www.uke.de Vorstandsmitglieder: Prof. Dr. Burkhard Göke (Vorsitzender), Prof. Dr. Dr. Uwe Koch-Gromus, Joachim Prölß, Rainer Schoppik _____________________________________________________________________ SAVE PAPER - THINK BEFORE PRINTING From rb643 at medschl.cam.ac.uk Tue Apr 26 23:12:27 2016 From: rb643 at medschl.cam.ac.uk (Richard Bethlehem) Date: Tue, 26 Apr 2016 21:12:27 +0000 Subject: [FieldTrip] PostDoc/Bioinformatician post available at Cambridge Message-ID: <3188FAB8621D294696F13E80A7BBC97E01013D9C2D@me-mbx3.medschl.cam.ac.uk> Dear all, Our lab is current looking hire a bio-information to work and a large genetics data project and in a wonderful team! http://www.jobs.cam.ac.uk/job/10224/ It might be beyond the remit of the mailing list so please feel free toward to anyone you think might be interested! Cheers, Richard -------------- next part -------------- An HTML attachment was scrubbed... URL: From zsoltturi at gmail.com Wed Apr 27 09:46:34 2016 From: zsoltturi at gmail.com (Zsolt Turi) Date: Wed, 27 Apr 2016 09:46:34 +0200 Subject: [FieldTrip] cluster plot In-Reply-To: <571F62CF.6000201@uke.de> References: <571F62CF.6000201@uke.de> Message-ID: Dear Phil, thanks for the suggestion, I tried and it worked out! Cheers, Zsolt 2016-04-26 14:45 GMT+02:00 Philipp Taesler : > Hi Zsolt, > > I've had some similar problems with data from a very long analysis > pipeline. It also failed to plot. A quick and dirty solution for me was > to get rid of the "cfg" field in the struct, as it had somehow > accumulated lots of data. > > newdata = rmfield(olddata, 'cfg'); > > Maybe this will help, otherwise I'm out of ideas for now :) > > Cheers, > Phil > > > Am 26.04.2016 um 14:14 schrieb Zsolt Turi: > > Dear Filedtrip users, > > > > I recently performed a non-parametric cluster-based permutation test on > > time-frequency data using a within-subjects design. I have two related > > questions/issues: > > > > 1) Size issues: > > > > For 11 participants the size of the file containing the time-frequency > > grand averages is 1.4 GB for each condition (I have two conditions), > > which is really hard to load in for the permutation test. Is this size > > reasonable? > > > > > > powspctrm: [4-D double] > > label: {64x1 cell} > > freq: [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20] > > time: [1x26 double] > > dimord: 'subj_chan_freq_time' > > cfg: [1x1 struct] > > > > > > 2) Cluster plot issue: > > > > Related to the first issue, after generating the plots for the stat, the > > computer stops responding and it is impossible to save the figure or > > even close it. > > > > cfg = []; > > cfg.alpha = 0.05; > > cfg.parameter = 'stat'; > > cfg.zlim = [-4 4]; > > cfg.layout = 'EEG1010.lay'; > > ft_clusterplot(cfg, stat); > > > > Have some of you encountered such kind of issues? > > > > > > I use 64 bit Win 7 OS, 8 GB RAM, Intel Core i5 CPU, 9.0.0.341360 > > (R2016a) Matlab and fieldtrip-20160424 versions. > > > > Thanks for your help in advance! > > > > Zsolt > > > -- > Philipp Taesler > Department of Systems Neuroscience > University Medical Center Hamburg-Eppendorf > Martinistr. 52, W34, 20248 Hamburg, Germany > > Phone: +49-40-7410-59902 > Fax: +49-40-7410-59955 > Email: p.taesler at uke.de > -- > > _____________________________________________________________________ > > Universitätsklinikum Hamburg-Eppendorf; Körperschaft des öffentlichen > Rechts; Gerichtsstand: Hamburg | www.uke.de > Vorstandsmitglieder: Prof. Dr. Burkhard Göke (Vorsitzender), Prof. Dr. Dr. > Uwe Koch-Gromus, Joachim Prölß, Rainer Schoppik > _____________________________________________________________________ > > SAVE PAPER - THINK BEFORE PRINTING > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -- Post-doctoral Research Fellow Department of Clinical Neurophysiology Georg-August University, Göttingen Robert-Koch-Str. 40 37075 Goettingen -------------- next part -------------- An HTML attachment was scrubbed... URL: From ph442 at cam.ac.uk Wed Apr 27 12:49:18 2016 From: ph442 at cam.ac.uk (parham hashemzadeh) Date: Wed, 27 Apr 2016 11:49:18 +0100 Subject: [FieldTrip] MNE-sample data set on Fieldtrip. Message-ID: <96d4943980d708a2b7d8b6ffbc439792@cam.ac.uk> Dear All I was hoping to perform a complete source analysis using FieldTrip on the MNE-sample data set. The link to the MNE data set link is given below: http://martinos.org/mne/dev/manual/sample_dataset.html#babdhifj I am terribly confused on how to align the MRI coordinates to MEG. The MEG system is a neuromag306. The function hdr=ft_read_header(raw_data_set_filename) reads fiducial marks HPI. It is contained in hdr.orig.dig. Also shape = ft_read_headshape(raw_data_set_filename) gives a structure shape = pos: [143x3 double] fid: [1x1 struct] label: {143x1 cell} coordsys: 'neuromag' unit: 'cm' pnt: [143x3 double] where the shape.fid has the nasion, lpa and rpa. I have the following questions: 1. It appears to me that the MRI coordinate system is already spm. Axis X :Left to right. Axis Y: Posterior to Anterior. Axis Z: bottom to top. 2. How can I realign the MRI to MEG? a) Interactively: ft_volumerealign or b) Should I use the information in shape to have it done automatically? I think, it would be unwise to define my own lpa, rpa and nasion. 3. What is the relationship between HPI coil coordinates and the lpa, rpa and nasion coordinates? Are there scripts that relate the two. 4. Has anyone ever created a script to use Fieldtrip to analyze this specific data set? 5. The MEG sensors are in a different coordinate frame "1" as opposed to head coordinates (Electrodes). Do I have to make sure that these coordinates are transformed to head coordinates prior to ft_prepare_leadfield calculations? or is this done automatically by fieldtrip? I just have the feeling that it would be unwise to do this interactively because of the existence of the fiducial markers. Many thanks if you are able to help me. -- best regards Parham Hashemzadeh Research Associate Department of Applied Mathematics and Theoretical Physics University of Cambridge, UK. email: hashemzadeh at damtp.cam.ac.uk From gina.joue at univr.it Wed Apr 27 18:24:16 2016 From: gina.joue at univr.it (gj) Date: Wed, 27 Apr 2016 18:24:16 +0200 Subject: [FieldTrip] FW: From a .csv data file, to a recognized dataset by fieldtrip In-Reply-To: References: Message-ID: <5720E7B0.4060207@univr.it> Hi Mina, I'm definitely not a FieldTrip expert, but I recently did something similar with .dat files that was just tab-delimited EEG data in the format [nsamples x nchan]. I followed this page closely: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat Basically, I created the following FT data structure: data.label % [nchan x 1] cell array of string labels for channels data.fsample % sampling frequency in Hz % for each trial t: data.trial{t} = load('eeg.dat'); % load your EEG data file -- should be [nchan x nsamples] data.time{t} % [1 x nsamples] vector corresponding to the time axis for each trial in SECONDS at each sampling point! If you've set all of that, you should be able to doublecheck your data by plotting it, e.g. cfg = []; cfg.viewmode = 'vertical'; % 'butterfly" superimposes channels cfg.continuous = 'no'; ft_databrowser(cfg,data); To prepare your channel layouts in FT data format, it seems like you need the electrodes in the ff formats 1. in mm in MNI coordinates and FT 2-D data format (see also templates in your FT subfolder: template/electrode/). If you don't have this, you can prepare your channel layout by using ft_prepare_layout() (check out the comments in the code or 'help ft_prepare_layout'). Then check that you've set up your data structure correctly with ft_plot_lay(); 2. in phi/theta coordinates of FT_DATATYPE_SENS format (some templates in FT subfolder template/layout/). Check out "help FT_DATATYPE_SENS" Your fiducials should be at the beginning of the list of your channels. Hope that is somewhat useful. Good luck! g From runna90 at 126.com Thu Apr 28 03:15:05 2016 From: runna90 at 126.com (CRN) Date: Thu, 28 Apr 2016 09:15:05 +0800 Subject: [FieldTrip] filter in continuous data and then epoch Message-ID: Dear fieldtrippers, I am processing MEG data acquired by CTF275 and I want to do filters in continuous raw data and then epoch them according to triggers. But I got warnings which were displayed below the code. Here is my code: cfg = []; cfg.dataset = dataset.ds; cfg.continuous = 'yes'; cfg.channel = 'meg'; raw_data = ft_preprocessing(cfg); cfg = []; cfg.lpfilter = 'yes'; cfg.lpfreq = 30; cfg.hpfilter = 'yes'; cfg.hpfreq = 1; cfg.dftfilte = 'yes'; cfg.dftfreq = 50; conti_filt = ft_preprocessing(cfg,raw_data); cfg=[]; cfg.dataset = [subjectdata.subjectdir filesep subjectdata.datadir{f_n}]; cfg.trialdef.eventtype = 'frontpanel trigger'; cfg.trialdef.eventvalue = 3; cfg.trialdef.pre = 0.5; cfg.trialdef.post = 1.2; cfg.continuous = 'yes'; cfg.trialfun = 'ft_trialfun_crn'; % self defined trl function cfg.channel = 'MEG'; cfg.layout = 'MEG.lay'; cfg = ft_definetrial(cfg); data_filt = ft_preprocessing(cfg, conti_filt); Warning: The field cfg.trl is forbidden, it will be removed from your configuration The field cfg.dataset is forbidden, it will be removed from your configuration The field cfg.datafile is forbidden, it will be removed from your configuration The field cfg.headerfile is forbidden, it will be removed from your configuration I have stuck in this question a whole night, please help! Thank you very much! Best wishes, Runnan runna90 at 126.com Institute of Biophysics, Chinese Academy of Science, Beijing, China -------------- next part -------------- An HTML attachment was scrubbed... URL: From icelandhouse at gmail.com Thu Apr 28 21:06:35 2016 From: icelandhouse at gmail.com (Maris Skujevskis) Date: Thu, 28 Apr 2016 21:06:35 +0200 Subject: [FieldTrip] Electrode position effects on leadfield values Message-ID: Dear Fieldtrip users, It is common knowledge that due to noise/measurement error, it is hard, if not impossible to match Polhemus digitized electrode locations with the MR head shape precisely. Even after manual and iterative alignment some electrodes remain "hanging" in the air above the head surface, while some others get buried below the head surface. Here is an illustration of what I mean: https://goo.gl/aSm7YU I am wondering what effect this type of electrode misplacement has on the values in the leadfield matrix as calculated by ft_prepare_leadfield? How does fieldtrip deal with electrodes placed in such a way? It seems that there is some magic involved there, since in theory the lead field matrix values for the electrodes not touching the surface of the head should be zero (which is not the case in the lead field matrix produced by ft_prepare_leadfield). I am currently testing how moving a "floating" and a "buried" electrode to its nearest point on the scalp affects the leadfield matrix values. I do not have any definite answers yet, but I did want to check in with some more experienced users out there before spending too much time on this (and possibly reinventing the wheel, so to speak). Thanks! Maris -------------- next part -------------- An HTML attachment was scrubbed... URL: From A.Reid at psych.ru.nl Fri Apr 29 14:01:38 2016 From: A.Reid at psych.ru.nl (Reid, A.T. (Andrew)) Date: Fri, 29 Apr 2016 12:01:38 +0000 Subject: [FieldTrip] Unit error using ft_topoplotTFR.m Message-ID: <5AE33796-5433-4D90-AE5F-A3ABD85E0C00@donders.ru.nl> Hi all, I am trying to do a simple topo plot of some time-locked HCP data. Running ft_multiplotTFR on the TFR output structure works fine. When I run ft_topoplotTFR on the same structure, I get the following error: creating layout from data.grad undoing the invcomp balancing for the gradiometer definition Error using ft_scalingfactor (line 181) cannot convert T to unknown Error in ft_scalingfactor (line 94) factor = cellfun(@ft_scalingfactor, old(:), new(:)); Error in ft_apply_montage (line 309) scale = ft_scalingfactor(input.chanunit, montage.chanunitorg); Error in undobalancing (line 37) sens = ft_apply_montage(sens, sens.balance.(sens.balance.current), 'inverse', 'yes', 'keepunused', 'yes', 'warning', 'no'); Error in ft_prepare_layout>sens2lay (line 957) sens = undobalancing(sens); Error in ft_prepare_layout (line 430) layout = sens2lay(data.grad, cfg.rotate, cfg.projection, cfg.style, cfg.overlap); Error in ft_topoplotTFR (line 192) cfg.layout = ft_prepare_layout(cfg, varargin{:}); The data.grad.balance.invcomp.chanunitnew cell array appears to be the culprit, as it contains “unknown” while the main data.chanunit has unit “T”. Not sure how to proceed here.. Thanks! Andrew ____________________________________________________ Andrew Reid Postdoctoral Fellow Department of Cognitive Artificial Intelligence Donders Institute for Brain, Cognition and Behaviour Radboud University Nijmegen Web: http://andrew.modelgui.org/ Tel: +31 (0)24 36 55931 -------------- next part -------------- An HTML attachment was scrubbed... URL: From gina.joue at univr.it Fri Apr 29 17:49:05 2016 From: gina.joue at univr.it (gj) Date: Fri, 29 Apr 2016 17:49:05 +0200 Subject: [FieldTrip] Fwd: ft_sourcegrandaverage and ft_sourceplot usage In-Reply-To: <57238213.5090103@univr.it> References: <57238213.5090103@univr.it> Message-ID: <57238271.70009@univr.it> Hi, I had computed source reconstruction in the frequency domain of my EEG data -- followed by * ft_sourcedescriptives with cfg.projectmom="yes" * set the resulting source_proj.dim = grid.dim source_proj.pos = grid.pos * ft_sourceinterpolate onto an MNI template brain but for some conditions of some subjects, this resulting localizations were predominantly in the center of the head. So, I was thinking of calculating the grand average of the source (though is this kosher when I have obvious individual source modeling problems?): ----- cfg.parameter = 'avg.pow'; cfg.keepindividual = 'yes'; cfg.outputfile = 'srcGrandAvg'; srcGrandAvg = ft_sourcegrandaverage(cfg, source_interp{:}); % source_interp = output of ft_sourceinterpolate ----- I'm not sure if my approach is correct because this results in a HUGE (several hundred MBs) srcGrandAvg matrix per condition that takes forever to write to disk. Moreover I cannot seem to plot it with ft_sourceplot (doesn't plot the source averaging results): ----- cfg = []; cfg.funparameter = 'pow'; cfg.method='ortho'; srcGrandAvg.anatomy = mri.anatomy; % from load('standard_mri.mat'); figure ft_sourceplot(cfg,srcGrandAvg); ----- ft_sourceplot gives me the messages: ----- the input is source data with 7109137 brainordinates on a [181 217 181] grid scaling anatomy to [0 1] not plotting functional data not applying a mask on the functional data not using an atlas not using a region-of-interest ----- My output from ft_sourcegrandaverage looks like this: ----- srcGrandAvg = pow: [19x7109137 double] coordsys: 'spm' dim: [181 217 181] freq: 12 inside: [7109137x1 logical] pos: [7109137x3 double] unit: 'mm' cfg: [1x1 struct] anatomy: [1x1 struct] ----- Thanks in advance for any help or advice!!! Gina From tineke.snijders at donders.ru.nl Fri Apr 1 12:03:30 2016 From: tineke.snijders at donders.ru.nl (Snijders, T.M. (Tineke)) Date: Fri, 1 Apr 2016 10:03:30 +0000 Subject: [FieldTrip] Question about coherence statistics In-Reply-To: References: <2595287eebb0aeacfe5761a9de10de24@inserm.fr> <68a5ba763224075e6d9ec9aa7684221a@inserm.fr>, <815A9820E75FBC4F96B7CD3A8089D11C378AE3E0@exprd04.hosting.ru.nl>, Message-ID: <815A9820E75FBC4F96B7CD3A8089D11C378AE4DA@exprd04.hosting.ru.nl> Hi Laetitia, Indeed, as 'coh' doesn't have the trial information anymore after ft_connectivityanalysis, you can't use it as input for ft_freqstatistics if you only have one subject. Indeed, giving 'cohspctrm' as parameter with your freq data doesn't work as 'cohspctrm' is not in your freq data. The cfg.parameter specifies what data to use for the randomization, so that parameter should be in the data you give as input. You can use the freq data as input for freq_statistics, but then you have to change your cfg.statistic. This is the statistical function that is called after shuffling your trials - in your case after shuffling your trials the coherence has to be computed and the difference between conditions calculated. As far as I know, if you set your cfg.statistic to 'diff_itc', it will compute the difference in the inter-trial coherence between two conditions (looking at the phase consistency over trials). Best, Tineke ________________________________ From: laetitia.lalla at inserm.fr [laetitia.lalla at inserm.fr] Sent: Thursday, March 31, 2016 3:22 PM To: FieldTrip discussion list Cc: Snijders, T.M. (Tineke) Subject: Re: [FieldTrip] Question about coherence statistics Dear Tineke, thank you very much for your fast answer ! I'm not sure I understand what you mean though... Maybe i did not express myself correctly. I do have individual trial data : I have 26 observations for condition 1 and 26 observations for condition 2. They appear : - In my structure "data" (output of ft_preprocessing) : data.trial is a cell {1 x nbtrials} (in my case : {1, 26}) - in my structure "freq" (output of ft_freqanalysis) : freq.powspctrm is a matrix of dimension : nbtrials X nbchannel X nbfreq (in my case 26x2x25) But I don't have this information anymore in the structure "coh" (output of ft_connectivityanalysis) : coh.cospctrm is a matrix of dimension nbchannelcmb x nbfreq (in my case 1x25) since the coherence is calculated by averaging over trials... You may mean I should give the "freq" structures as inputs to the fonction ft_freqstatistics ? I just tried that : I created a structure data_all by concatenated data1.trial and data2.trial (and every other appropriate attribute). I took the Time Frequency Representation with ft_freqanalysis (with keeptrials='yes') to obtain a structure TFR_all (following this tutorial : http://www.fieldtriptoolbox.org/tutorial/natmeg/statistics This is actually how I did the statistics for the Power). But then, if I give this as an input to ft_freqstatistics, like this : cfg = []; cfg.statistic = 'diff'; cfg.parameter='cohspctrm'; cfg.design= [ones(1,nbtrial)) 2*ones(1, nbtrial))]; %same nb of trials for both condition cfg.method = 'montecarlo'; cfg.numrandomization = 1000; cfg.ivar = 1; cfg.alpha=0.05; cfg.tail=0; cfg.correcttail='alpha'; >> stat=ft_freqstatistics(cfg, FR_alltrials); I have the following error : Error using getdimord (line 15) field "cohspctrm" not present in data which makes a lot of sense, since I did not gave coherence as an input... I gave Frequency representations.. I was hoping that maybe the function would calculate the coherence itself for the statistics ? ^^ But it's clearly not the way to go. Could you be a bit more explicit about what you meant ? Thanks a lot. Best, Laetitia Lalla PhD student in Neurosciences INMED, Marseille, France On 31-03-2016 13:47, Snijders, T.M. (Tineke) wrote: Hi Laetitia, If you only have one subject you do need individual trial data, otherwise you can't do statistics like this. You need multiple observations (either subjects or trials). Best, Tineke ________________________________ From: fieldtrip-bounces at science.ru.nl [fieldtrip-bounces at science.ru.nl] on behalf of laetitia.lalla at inserm.fr [laetitia.lalla at inserm.fr] Sent: Thursday, March 31, 2016 1:11 PM To: fieldtrip at science.ru.nl Subject: [FieldTrip] Question about coherence statistics Dear FielTrip community, Sorry to bother you again... I have a question about the statistical testing to assess coherence differences and the related paper by E Maris, JM Schoffelen and P Fries (Journal of Neuroscience Methods, 2007) I believe I am exactly in the framework described in this paper, but I guess there is still some crucial information that I don't understand... This is my story : - It's a single-subject study - I want to compare two sets of trials observed in different conditions. - The 2 sets of trials are exactly the same size, so my coherence estimate won't be biased by the "unequal sample size problem". - I just want to compare for 1 channel pair, for 1 frequency bin [6Hz 10Hz], so I guess the Multiple Comparison problem won't affect my analysis too much (either in the spatial or the spectral dimension). Based on the paper, I could refer myself to the point "2.7.1. A non parametric satistical test for a single signal pair and a single frequency bin". - Since my interest is in the coherence difference for a single signal pair, I can choose [|C1(f)|-|C2(f)|] as a test statistic. - And I can perform the montecarlo simulation. My question is the following : How can I implement the nonparametric test of the coherence difference between my 2 conditions with the fieldtrip functions ? This is what I did : 1) Extract and preprocess the signal from my condition 1. 2) freq1= ft_freqanalysis(cfg, signal1) (with cfg.method='mtmfft', cfg.output='powandcsd') → 3) coh1= ft_connectivityanalysis(cfg, freq1) I did the same thing for the other condition → coh2. And then for the statistics : cfg = []; cfg.statistic = 'diff'; (% because the statistic test than I chose is the difference [|C1(f)|-|C2(f)|]) cfg.parameter='cohspctrm'; cfg.method = 'montecarlo'; cfg.numrandomization = 1000; cfg.ivar = 1; cfg.alpha=0.05; cfg.tail=0; cfg.correcttail='alpha'; stat=ft_freqstatistics(cfg, coh1, coh2); And it gives me the following error : Error using ft_checkconfig (line 153) The field cfg.design is required. Here, I really don't understand why I'm asked for the design matrix... When doing the statistics for the Power, I understood that the design matrix was telling which trial belonged to the condition 1 and which trial belonged to the condition 2. But here, it doesn't make any sense because my coherence was calculated by averaging on the trials... Does the design matrix mean something differently here ? Or maybe I forgot one parameter to put in the cfg ? Any help will be appreciated ! Thanks a lot for your time, Laetitia Lalla PhD student in Neurosciences INMED, Marseille, France _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From hibafouani123 at hotmail.com Fri Apr 1 12:15:53 2016 From: hibafouani123 at hotmail.com (hiba fouani) Date: Fri, 1 Apr 2016 10:15:53 +0000 Subject: [FieldTrip] Bidomain model instead of dipoles In-Reply-To: References: Message-ID: Dear fieldtripper, I want to study source localization for ecg but with bidomain model for sources not dipoles, is it possible with fieldtrip or openmeeg? and thank you for suggestion for any tool. Thank you Hiba > From: fieldtrip-request at science.ru.nl > Subject: fieldtrip Digest, Vol 65, Issue 1 > To: fieldtrip at science.ru.nl > Date: Fri, 1 Apr 2016 12:00:02 +0200 > > Send fieldtrip mailing list submissions to > fieldtrip at science.ru.nl > > To subscribe or unsubscribe via the World Wide Web, visit > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > or, via email, send a message with subject or body 'help' to > fieldtrip-request at science.ru.nl > > You can reach the person managing the list at > fieldtrip-owner at science.ru.nl > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of fieldtrip digest..." > > > Today's Topics: > > 1. Question about coherence statistics (laetitia.lalla at inserm.fr) > 2. Re: Question about coherence statistics (Snijders, T.M. (Tineke)) > 3. Re: Question about coherence statistics (laetitia.lalla at inserm.fr) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Thu, 31 Mar 2016 13:11:31 +0200 > From: laetitia.lalla at inserm.fr > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Question about coherence statistics > Message-ID: > Content-Type: text/plain; charset="utf-8" > > > > Dear FielTrip community, > > Sorry to bother you again... > > I have a question about the statistical testing to assess coherence > differences and the related paper by E Maris, JM Schoffelen and P Fries > (Journal of Neuroscience Methods, 2007) > > I believe I am exactly in the framework described in this paper, but I > guess there is still some crucial information that I don't understand... > > > This is my story : > > - It's a single-subject study > > - I want to compare two sets of trials observed in different conditions. > > > - The 2 sets of trials are exactly the same size, so my coherence > estimate won't be biased by the "unequal sample size problem". > > - I just want to compare for 1 channel pair, for 1 frequency bin [6Hz > 10Hz], so I guess the Multiple Comparison problem won't affect my > analysis too much (either in the spatial or the spectral dimension). > > Based on the paper, I could refer myself to the point "2.7.1. A non > parametric satistical test for a single signal pair and a single > frequency bin". > > - Since my interest is in the coherence difference for a single signal > pair, I can choose [|C1(f)|-|C2(f)|] as a test statistic. > > - And I can perform the montecarlo simulation. > > My question is the following : How can I implement the nonparametric > test of the coherence difference between my 2 conditions with the > fieldtrip functions ? > > This is what I did : > > 1) Extract and preprocess the signal from my condition 1. > > 2) freq1= ft_freqanalysis(cfg, signal1) (with cfg.method='mtmfft', > cfg.output='powandcsd') ? > > 3) coh1= ft_connectivityanalysis(cfg, freq1) > > I did the same thing for the other condition ? coh2. > > And then for the statistics : > > cfg = []; > > cfg.statistic = 'diff'; (% because the statistic test than I chose is > the difference [|C1(f)|-|C2(f)|]) > > cfg.parameter='cohspctrm'; > > cfg.method = 'montecarlo'; > > cfg.numrandomization = 1000; > > cfg.ivar = 1; > > cfg.alpha=0.05; > > cfg.tail=0; > > cfg.correcttail='alpha'; > > stat=ft_freqstatistics(cfg, coh1, coh2); > > And it gives me the following error : > > Error using ft_checkconfig (line 153) > > The field cfg.design is required. > > Here, I really don't understand why I'm asked for the design matrix... > When doing the statistics for the Power, I understood that the design > matrix was telling which trial belonged to the condition 1 and which > trial belonged to the condition 2. But here, it doesn't make any sense > because my coherence was calculated by averaging on the trials... > > Does the design matrix mean something differently here ? Or maybe I > forgot one parameter to put in the cfg ? > > Any help will be appreciated ! > > Thanks a lot for your time, > > Laetitia Lalla > > PhD student in Neurosciences > > INMED, Marseille, France > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > Message: 2 > Date: Thu, 31 Mar 2016 11:47:19 +0000 > From: "Snijders, T.M. (Tineke)" > To: FieldTrip discussion list > Subject: Re: [FieldTrip] Question about coherence statistics > Message-ID: > <815A9820E75FBC4F96B7CD3A8089D11C378AE3E0 at exprd04.hosting.ru.nl> > Content-Type: text/plain; charset="iso-2022-jp" > > Hi Laetitia, > > If you only have one subject you do need individual trial data, otherwise you can't do statistics like this. > You need multiple observations (either subjects or trials). > > Best, > Tineke > > ________________________________ > From: fieldtrip-bounces at science.ru.nl [fieldtrip-bounces at science.ru.nl] on behalf of laetitia.lalla at inserm.fr [laetitia.lalla at inserm.fr] > Sent: Thursday, March 31, 2016 1:11 PM > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Question about coherence statistics > > > Dear FielTrip community, > > Sorry to bother you again... > > I have a question about the statistical testing to assess coherence differences and the related paper by E Maris, JM Schoffelen and P Fries (Journal of Neuroscience Methods, 2007) > > I believe I am exactly in the framework described in this paper, but I guess there is still some crucial information that I don't understand... > > > > This is my story : > > - It's a single-subject study > > - I want to compare two sets of trials observed in different conditions. > > - The 2 sets of trials are exactly the same size, so my coherence estimate won't be biased by the ?unequal sample size problem?. > > - I just want to compare for 1 channel pair, for 1 frequency bin [6Hz 10Hz], so I guess the Multiple Comparison problem won't affect my analysis too much (either in the spatial or the spectral dimension). > > > > Based on the paper, I could refer myself to the point ?2.7.1. A non parametric satistical test for a single signal pair and a single frequency bin?. > > - Since my interest is in the coherence difference for a single signal pair, I can choose [|C1(f)|-|C2(f)|] as a test statistic. > > - And I can perform the montecarlo simulation. > > > > My question is the following : How can I implement the nonparametric test of the coherence difference between my 2 conditions with the fieldtrip functions ? > > > > This is what I did : > > 1) Extract and preprocess the signal from my condition 1. > > 2) freq1= ft_freqanalysis(cfg, signal1) (with cfg.method='mtmfft', cfg.output='powandcsd') ? > > 3) coh1= ft_connectivityanalysis(cfg, freq1) > > > > I did the same thing for the other condition ? coh2. > > > > And then for the statistics : > > cfg = []; > > cfg.statistic = 'diff'; (% because the statistic test than I chose is the difference [|C1(f)|-|C2(f)|]) > > cfg.parameter='cohspctrm'; > > cfg.method = 'montecarlo'; > > cfg.numrandomization = 1000; > > cfg.ivar = 1; > > cfg.alpha=0.05; > > cfg.tail=0; > > cfg.correcttail='alpha'; > > stat=ft_freqstatistics(cfg, coh1, coh2); > > > > And it gives me the following error : > > Error using ft_checkconfig (line 153) > > The field cfg.design is required. > > > > Here, I really don't understand why I'm asked for the design matrix... When doing the statistics for the Power, I understood that the design matrix was telling which trial belonged to the condition 1 and which trial belonged to the condition 2. But here, it doesn't make any sense because my coherence was calculated by averaging on the trials... > > Does the design matrix mean something differently here ? Or maybe I forgot one parameter to put in the cfg ? > > > > Any help will be appreciated ! > > > > Thanks a lot for your time, > > > > Laetitia Lalla > > PhD student in Neurosciences > > INMED, Marseille, France > > > > > > > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > Message: 3 > Date: Thu, 31 Mar 2016 15:22:31 +0200 > From: laetitia.lalla at inserm.fr > To: FieldTrip discussion list > Subject: Re: [FieldTrip] Question about coherence statistics > Message-ID: > Content-Type: text/plain; charset="utf-8" > > > > Dear Tineke, > > thank you very much for your fast answer ! I'm not sure I understand > what you mean though... Maybe i did not express myself correctly. I do > have individual trial data : I have 26 observations for condition 1 and > 26 observations for condition 2. > > They appear : > > - In my structure "data" (output of ft_preprocessing) : data.trial is a > cell {1 x nbtrials} (in my case : {1, 26}) > > - in my structure "freq" (output of ft_freqanalysis) : freq.powspctrm is > a matrix of dimension : nbtrials X nbchannel X nbfreq (in my case > 26x2x25) > > But I don't have this information anymore in the structure "coh" (output > of ft_connectivityanalysis) : coh.cospctrm is a matrix of dimension > nbchannelcmb x nbfreq (in my case 1x25) since the coherence is > calculated by averaging over trials... > > You may mean I should give the "freq" structures as inputs to the > fonction ft_freqstatistics ? > > I just tried that : I created a structure data_all by concatenated > data1.trial and data2.trial (and every other appropriate attribute). I > took the Time Frequency Representation with ft_freqanalysis (with > keeptrials='yes') to obtain a structure TFR_all (following this tutorial > : http://www.fieldtriptoolbox.org/tutorial/natmeg/statistics This is > actually how I did the statistics for the Power). > > But then, if I give this as an input to ft_freqstatistics, like this : > > cfg = []; > cfg.statistic = 'diff'; > cfg.parameter='cohspctrm'; > cfg.design= [ones(1,nbtrial)) 2*ones(1, nbtrial))]; %same nb of trials > for both condition > cfg.method = 'montecarlo'; > cfg.numrandomization = 1000; > cfg.ivar = 1; > cfg.alpha=0.05; > cfg.tail=0; > cfg.correcttail='alpha'; > >> stat=ft_freqstatistics(cfg, FR_alltrials); > > I have the following error : > > Error using getdimord (line 15) > field "cohspctrm" not present in data > > which makes a lot of sense, since I did not gave coherence as an > input... I gave Frequency representations.. I was hoping that maybe the > function would calculate the coherence itself for the statistics ? ^^ > But it's clearly not the way to go. > > Could you be a bit more explicit about what you meant ? > > Thanks a lot. > > Best, > > Laetitia Lalla > > PhD student in Neurosciences > > INMED, Marseille, France > > On 31-03-2016 13:47, Snijders, T.M. (Tineke) wrote: > > > Hi Laetitia, > > > > If you only have one subject you do need individual trial data, otherwise you can't do statistics like this. > > You need multiple observations (either subjects or trials). > > > > Best, > > Tineke > > > > ------------------------- > > > > FROM: fieldtrip-bounces at science.ru.nl [fieldtrip-bounces at science.ru.nl] on behalf of laetitia.lalla at inserm.fr [laetitia.lalla at inserm.fr] > > SENT: Thursday, March 31, 2016 1:11 PM > > TO: fieldtrip at science.ru.nl > > SUBJECT: [FieldTrip] Question about coherence statistics > > > > Dear FielTrip community, > > > > Sorry to bother you again... > > > > I have a question about the statistical testing to assess coherence differences and the related paper by E Maris, JM Schoffelen and P Fries (Journal of Neuroscience Methods, 2007) > > > > I believe I am exactly in the framework described in this paper, but I guess there is still some crucial information that I don't understand... > > > > This is my story : > > > > - It's a single-subject study > > > > - I want to compare two sets of trials observed in different conditions. > > > > - The 2 sets of trials are exactly the same size, so my coherence estimate won't be biased by the "unequal sample size problem". > > > > - I just want to compare for 1 channel pair, for 1 frequency bin [6Hz 10Hz], so I guess the Multiple Comparison problem won't affect my analysis too much (either in the spatial or the spectral dimension). > > > > Based on the paper, I could refer myself to the point "2.7.1. A non parametric satistical test for a single signal pair and a single frequency bin". > > > > - Since my interest is in the coherence difference for a single signal pair, I can choose [|C1(f)|-|C2(f)|] as a test statistic. > > > > - And I can perform the montecarlo simulation. > > > > My question is the following : How can I implement the nonparametric test of the coherence difference between my 2 conditions with the fieldtrip functions ? > > > > This is what I did : > > > > 1) Extract and preprocess the signal from my condition 1. > > > > 2) freq1= ft_freqanalysis(cfg, signal1) (with cfg.method='mtmfft', cfg.output='powandcsd') ? > > > > 3) coh1= ft_connectivityanalysis(cfg, freq1) > > > > I did the same thing for the other condition ? coh2. > > > > And then for the statistics : > > > > cfg = []; > > > > cfg.statistic = 'diff'; (% because the statistic test than I chose is the difference [|C1(f)|-|C2(f)|]) > > > > cfg.parameter='cohspctrm'; > > > > cfg.method = 'montecarlo'; > > > > cfg.numrandomization = 1000; > > > > cfg.ivar = 1; > > > > cfg.alpha=0.05; > > > > cfg.tail=0; > > > > cfg.correcttail='alpha'; > > > > stat=ft_freqstatistics(cfg, coh1, coh2); > > > > And it gives me the following error : > > > > Error using ft_checkconfig (line 153) > > > > The field cfg.design is required. > > > > Here, I really don't understand why I'm asked for the design matrix... When doing the statistics for the Power, I understood that the design matrix was telling which trial belonged to the condition 1 and which trial belonged to the condition 2. But here, it doesn't make any sense because my coherence was calculated by averaging on the trials... > > > > Does the design matrix mean something differently here ? Or maybe I forgot one parameter to put in the cfg ? > > > > Any help will be appreciated ! > > > > Thanks a lot for your time, > > > > Laetitia Lalla > > > > PhD student in Neurosciences > > > > INMED, Marseille, France > > > > _______________________________________________ > > fieldtrip mailing list > > fieldtrip at donders.ru.nl > > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > End of fieldtrip Digest, Vol 65, Issue 1 > **************************************** -------------- next part -------------- An HTML attachment was scrubbed... URL: From juangpc at gmail.com Fri Apr 1 22:38:54 2016 From: juangpc at gmail.com (Juan) Date: Fri, 1 Apr 2016 22:38:54 +0200 Subject: [FieldTrip] tutorial on preprocessing ERP activity in combined MEG/EEG data Message-ID: Hi, Following the tutorial on preprocessing combined MEG/EEG data, I've noticed that in order to reproduce ft_multiplotER figures (i.e. ) some changes must be made to the code. ​ I c ​ould do the changes these myself but ​as this implies quite a few within the tutorial, ​ I'm wondering if this is ok or not. For instance, cfg.xlim and cfg.ylim must be changed to cfg.vlim and cfg.hlim. Also ERF_diff = ft_math(cfg, ERF_oddball, ERF_standard); must be changed to ERF_diff = ft_math(cfg, ERF_standard, ERF_oddball); ​ Juan -------------- next part -------------- An HTML attachment was scrubbed... URL: From laetitia.lalla at inserm.fr Mon Apr 4 11:45:49 2016 From: laetitia.lalla at inserm.fr (laetitia.lalla at inserm.fr) Date: Mon, 04 Apr 2016 11:45:49 +0200 Subject: [FieldTrip] Question about coherence statistics In-Reply-To: <815A9820E75FBC4F96B7CD3A8089D11C378AE4DA@exprd04.hosting.ru.nl> References: <2595287eebb0aeacfe5761a9de10de24@inserm.fr> <68a5ba763224075e6d9ec9aa7684221a@inserm.fr>, <815A9820E75FBC4F96B7CD3A8089D11C378AE3E0@exprd04.hosting.ru.nl>, <815A9820E75FBC4F96B7CD3A8089D11C378AE4DA@exprd04.hosting.ru.nl> Message-ID: <17c319aeab6f35a621fb193e8b051792@inserm.fr> Hey Tineke, Thank you very much ! It's all clear now. I was stuck with the list of statistics described in the "help" of freqstatistics and I did not even though of browsing the ft_statfun_XXX functions. I'm gonna try this right away. Have a nice day, Laetitia Lalla PhD student in Neurosciences INMED, Marseille, France On 01-04-2016 12:03, Snijders, T.M. (Tineke) wrote: > Hi Laetitia, > > Indeed, as 'coh' doesn't have the trial information anymore after ft_connectivityanalysis, you can't use it as input for ft_freqstatistics if you only have one subject. > > Indeed, giving 'cohspctrm' as parameter with your freq data doesn't work as 'cohspctrm' is not in your freq data. The cfg.parameter specifies what data to use for the randomization, so that parameter should be in the data you give as input. > > You can use the freq data as input for freq_statistics, but then you have to change your cfg.statistic. This is the statistical function that is called after shuffling your trials - in your case after shuffling your trials the coherence has to be computed and the difference between conditions calculated. As far as I know, if you set your cfg.statistic to 'diff_itc', it will compute the difference in the inter-trial coherence between two conditions (looking at the phase consistency over trials). > > Best, > Tineke > > ------------------------- > > FROM: laetitia.lalla at inserm.fr [laetitia.lalla at inserm.fr] > SENT: Thursday, March 31, 2016 3:22 PM > TO: FieldTrip discussion list > CC: Snijders, T.M. (Tineke) > SUBJECT: Re: [FieldTrip] Question about coherence statistics > > Dear Tineke, > > thank you very much for your fast answer ! I'm not sure I understand what you mean though... Maybe i did not express myself correctly. I do have individual trial data : I have 26 observations for condition 1 and 26 observations for condition 2. > > They appear : > > - In my structure "data" (output of ft_preprocessing) : data.trial is a cell {1 x nbtrials} (in my case : {1, 26}) > > - in my structure "freq" (output of ft_freqanalysis) : freq.powspctrm is a matrix of dimension : nbtrials X nbchannel X nbfreq (in my case 26x2x25) > > But I don't have this information anymore in the structure "coh" (output of ft_connectivityanalysis) : coh.cospctrm is a matrix of dimension nbchannelcmb x nbfreq (in my case 1x25) since the coherence is calculated by averaging over trials... > > You may mean I should give the "freq" structures as inputs to the fonction ft_freqstatistics ? > > I just tried that : I created a structure data_all by concatenated data1.trial and data2.trial (and every other appropriate attribute). I took the Time Frequency Representation with ft_freqanalysis (with keeptrials='yes') to obtain a structure TFR_all (following this tutorial : http://www.fieldtriptoolbox.org/tutorial/natmeg/statistics This is actually how I did the statistics for the Power). > > But then, if I give this as an input to ft_freqstatistics, like this : > > cfg = []; > cfg.statistic = 'diff'; > cfg.parameter='cohspctrm'; > cfg.design= [ones(1,nbtrial)) 2*ones(1, nbtrial))]; %same nb of trials for both condition > cfg.method = 'montecarlo'; > cfg.numrandomization = 1000; > cfg.ivar = 1; > cfg.alpha=0.05; > cfg.tail=0; > cfg.correcttail='alpha'; >>> stat=ft_freqstatistics(cfg, FR_alltrials); > > I have the following error : > > Error using getdimord (line 15) > field "cohspctrm" not present in data > > which makes a lot of sense, since I did not gave coherence as an input... I gave Frequency representations.. I was hoping that maybe the function would calculate the coherence itself for the statistics ? ^^ But it's clearly not the way to go. > > Could you be a bit more explicit about what you meant ? > > Thanks a lot. > > Best, > > Laetitia Lalla > > PhD student in Neurosciences > > INMED, Marseille, France > > On 31-03-2016 13:47, Snijders, T.M. (Tineke) wrote: > >> Hi Laetitia, >> >> If you only have one subject you do need individual trial data, otherwise you can't do statistics like this. >> You need multiple observations (either subjects or trials). >> >> Best, >> Tineke >> >> ------------------------- >> >> FROM: fieldtrip-bounces at science.ru.nl [fieldtrip-bounces at science.ru.nl] on behalf of laetitia.lalla at inserm.fr [laetitia.lalla at inserm.fr] >> SENT: Thursday, March 31, 2016 1:11 PM >> TO: fieldtrip at science.ru.nl >> SUBJECT: [FieldTrip] Question about coherence statistics >> >> Dear FielTrip community, >> >> Sorry to bother you again... >> >> I have a question about the statistical testing to assess coherence differences and the related paper by E Maris, JM Schoffelen and P Fries (Journal of Neuroscience Methods, 2007) >> >> I believe I am exactly in the framework described in this paper, but I guess there is still some crucial information that I don't understand... >> >> This is my story : >> >> - It's a single-subject study >> >> - I want to compare two sets of trials observed in different conditions. >> >> - The 2 sets of trials are exactly the same size, so my coherence estimate won't be biased by the "unequal sample size problem". >> >> - I just want to compare for 1 channel pair, for 1 frequency bin [6Hz 10Hz], so I guess the Multiple Comparison problem won't affect my analysis too much (either in the spatial or the spectral dimension). >> >> Based on the paper, I could refer myself to the point "2.7.1. A non parametric satistical test for a single signal pair and a single frequency bin". >> >> - Since my interest is in the coherence difference for a single signal pair, I can choose [|C1(f)|-|C2(f)|] as a test statistic. >> >> - And I can perform the montecarlo simulation. >> >> My question is the following : How can I implement the nonparametric test of the coherence difference between my 2 conditions with the fieldtrip functions ? >> >> This is what I did : >> >> 1) Extract and preprocess the signal from my condition 1. >> >> 2) freq1= ft_freqanalysis(cfg, signal1) (with cfg.method='mtmfft', cfg.output='powandcsd') → >> >> 3) coh1= ft_connectivityanalysis(cfg, freq1) >> >> I did the same thing for the other condition → coh2. >> >> And then for the statistics : >> >> cfg = []; >> >> cfg.statistic = 'diff'; (% because the statistic test than I chose is the difference [|C1(f)|-|C2(f)|]) >> >> cfg.parameter='cohspctrm'; >> >> cfg.method = 'montecarlo'; >> >> cfg.numrandomization = 1000; >> >> cfg.ivar = 1; >> >> cfg.alpha=0.05; >> >> cfg.tail=0; >> >> cfg.correcttail='alpha'; >> >> stat=ft_freqstatistics(cfg, coh1, coh2); >> >> And it gives me the following error : >> >> Error using ft_checkconfig (line 153) >> >> The field cfg.design is required. >> >> Here, I really don't understand why I'm asked for the design matrix... When doing the statistics for the Power, I understood that the design matrix was telling which trial belonged to the condition 1 and which trial belonged to the condition 2. But here, it doesn't make any sense because my coherence was calculated by averaging on the trials... >> >> Does the design matrix mean something differently here ? Or maybe I forgot one parameter to put in the cfg ? >> >> Any help will be appreciated ! >> >> Thanks a lot for your time, >> >> Laetitia Lalla >> >> PhD student in Neurosciences >> >> INMED, Marseille, France >> >> _______________________________________________ >> 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 -------------- next part -------------- An HTML attachment was scrubbed... URL: From rmontefusco at med.uchile.cl Mon Apr 4 14:17:12 2016 From: rmontefusco at med.uchile.cl (Rodrigo Montefusco) Date: Mon, 4 Apr 2016 09:17:12 -0300 Subject: [FieldTrip] Question about coherence statistics In-Reply-To: <17c319aeab6f35a621fb193e8b051792@inserm.fr> References: <2595287eebb0aeacfe5761a9de10de24@inserm.fr> <68a5ba763224075e6d9ec9aa7684221a@inserm.fr> <815A9820E75FBC4F96B7CD3A8089D11C378AE3E0@exprd04.hosting.ru.nl> <815A9820E75FBC4F96B7CD3A8089D11C378AE4DA@exprd04.hosting.ru.nl> <17c319aeab6f35a621fb193e8b051792@inserm.fr> Message-ID: Hi Laetitia, What you may try is to perform a "manual" permutation of your conditions before calculation of the coherence, and subtract the values of both randomized conditions... do that many....many many many times (1000 or above depending on your alpha...but as you have not many trials, do the math on how many you will need)...and you will end up with a distribution of difference coherence values. Then,based on your hypothesis, you can set a percentile threshold. Then subtract your original coherence values and check if they are under or over the threshold. If somebody find this is not correct, please let me know with an explanation! :) Best regards. YOGUI ps: best mail list ever! On Mon, Apr 4, 2016 at 6:45 AM, wrote: > Hey Tineke, > > Thank you very much ! It's all clear now. I was stuck with the list of > statistics described in the "help" of freqstatistics and I did not even > though of browsing the ft_statfun_XXX functions. I'm gonna try this right > away. > > Have a nice day, > > > > Laetitia Lalla > > PhD student in Neurosciences > > INMED, Marseille, France > > > > On 01-04-2016 12:03, Snijders, T.M. (Tineke) wrote: > > Hi Laetitia, > > Indeed, as 'coh' doesn't have the trial information anymore after > ft_connectivityanalysis, you can't use it as input for ft_freqstatistics if > you only have one subject. > > Indeed, giving 'cohspctrm' as parameter with your freq data doesn't work > as 'cohspctrm' is not in your freq data. The cfg.parameter specifies what > data to use for the randomization, so that parameter should be in the data > you give as input. > > You can use the freq data as input for freq_statistics, but then you have > to change your cfg.statistic. This is the statistical function that is > called after shuffling your trials - in your case after shuffling your > trials the coherence has to be computed and the difference between > conditions calculated. As far as I know, if you set your cfg.statistic to > 'diff_itc', it will compute the difference in the inter-trial coherence > between two conditions (looking at the phase consistency over trials). > > Best, > Tineke > > ------------------------------ > *From:* laetitia.lalla at inserm.fr [laetitia.lalla at inserm.fr] > *Sent:* Thursday, March 31, 2016 3:22 PM > *To:* FieldTrip discussion list > *Cc:* Snijders, T.M. (Tineke) > *Subject:* Re: [FieldTrip] Question about coherence statistics > > > Dear Tineke, > > thank you very much for your fast answer ! I'm not sure I understand what > you mean though... Maybe i did not express myself correctly. I do have > individual trial data : I have 26 observations for condition 1 and 26 > observations for condition 2. > > They appear : > > - In my structure "data" (output of ft_preprocessing) : data.trial is a > cell {1 x nbtrials} (in my case : {1, 26}) > > - in my structure "freq" (output of ft_freqanalysis) : freq.powspctrm is a > matrix of dimension : nbtrials X nbchannel X nbfreq (in my case 26x2x25) > > But I don't have this information anymore in the structure "coh" (output > of ft_connectivityanalysis) : coh.cospctrm is a matrix of dimension > nbchannelcmb x nbfreq (in my case 1x25) since the coherence is calculated > by averaging over trials... > > > > You may mean I should give the "freq" structures as inputs to the fonction > ft_freqstatistics ? > > I just tried that : I created a structure data_all by concatenated > data1.trial and data2.trial (and every other appropriate attribute). I took > the Time Frequency Representation with ft_freqanalysis (with > keeptrials='yes') to obtain a structure TFR_all (following this tutorial : > http://www.fieldtriptoolbox.org/tutorial/natmeg/statistics This is > actually how I did the statistics for the Power). > > But then, if I give this as an input to ft_freqstatistics, like this : > > cfg = []; > cfg.statistic = 'diff'; > cfg.parameter='cohspctrm'; > cfg.design= [ones(1,nbtrial)) 2*ones(1, nbtrial))]; %same nb of trials for > both condition > cfg.method = 'montecarlo'; > cfg.numrandomization = 1000; > cfg.ivar = 1; > cfg.alpha=0.05; > cfg.tail=0; > cfg.correcttail='alpha'; > >> stat=ft_freqstatistics(cfg, FR_alltrials); > > I have the following error : > > Error using getdimord (line 15) > field "cohspctrm" not present in data > > which makes a lot of sense, since I did not gave coherence as an input... > I gave Frequency representations.. I was hoping that maybe the function > would calculate the coherence itself for the statistics ? ^^ But it's > clearly not the way to go. > > > > Could you be a bit more explicit about what you meant ? > > > > Thanks a lot. > > Best, > > Laetitia Lalla > > PhD student in Neurosciences > > INMED, Marseille, France > > > > > > On 31-03-2016 13:47, Snijders, T.M. (Tineke) wrote: > > Hi Laetitia, > > If you only have one subject you do need individual trial data, otherwise > you can't do statistics like this. > You need multiple observations (either subjects or trials). > > Best, > Tineke > > ------------------------------ > *From:* fieldtrip-bounces at science.ru.nl [fieldtrip-bounces at science.ru.nl] > on behalf of laetitia.lalla at inserm.fr [laetitia.lalla at inserm.fr] > *Sent:* Thursday, March 31, 2016 1:11 PM > *To:* fieldtrip at science.ru.nl > *Subject:* [FieldTrip] Question about coherence statistics > > > Dear FielTrip community, > > Sorry to bother you again... > > I have a question about the statistical testing to assess coherence > differences and the related paper by E Maris, JM Schoffelen and P Fries > (Journal of Neuroscience Methods, 2007) > > I believe I am exactly in the framework described in this paper, but I > guess there is still some crucial information that I don't understand... > > > > This is my story : > > - It's a single-subject study > > - I want to compare two sets of trials observed in different conditions. > > - The 2 sets of trials are exactly the same size, so my coherence estimate > won't be biased by the "unequal sample size problem". > > - I just want to compare for 1 channel pair, for 1 frequency bin [6Hz > 10Hz], so I guess the Multiple Comparison problem won't affect my analysis > too much (either in the spatial or the spectral dimension). > > > > Based on the paper, I could refer myself to the point "2.7.1. A non > parametric satistical test for a single signal pair and a single frequency > bin". > > - Since my interest is in the coherence difference for a single signal > pair, I can choose [|C1(f)|-|C2(f)|] as a test statistic. > > - And I can perform the montecarlo simulation. > > > > My question is the following : How can I implement the nonparametric test > of the coherence difference between my 2 conditions with the fieldtrip > functions ? > > > > This is what I did : > > 1) Extract and preprocess the signal from my condition 1. > > 2) freq1= ft_freqanalysis(cfg, signal1) (with cfg.method='mtmfft', > cfg.output='powandcsd') → > > 3) coh1= ft_connectivityanalysis(cfg, freq1) > > > > I did the same thing for the other condition → coh2. > > > > And then for the statistics : > > cfg = []; > > cfg.statistic = 'diff'; (% because the statistic test than I chose is the > difference [|C1(f)|-|C2(f)|]) > > cfg.parameter='cohspctrm'; > > cfg.method = 'montecarlo'; > > cfg.numrandomization = 1000; > > cfg.ivar = 1; > > cfg.alpha=0.05; > > cfg.tail=0; > > cfg.correcttail='alpha'; > > stat=ft_freqstatistics(cfg, coh1, coh2); > > > > And it gives me the following error : > > Error using ft_checkconfig (line 153) > > The field cfg.design is required. > > > > Here, I really don't understand why I'm asked for the design matrix... > When doing the statistics for the Power, I understood that the design > matrix was telling which trial belonged to the condition 1 and which trial > belonged to the condition 2. But here, it doesn't make any sense because my > coherence was calculated by averaging on the trials... > > Does the design matrix mean something differently here ? Or maybe I forgot > one parameter to put in the cfg ? > > > > Any help will be appreciated ! > > > > Thanks a lot for your time, > > > > Laetitia Lalla > > PhD student in Neurosciences > > INMED, Marseille, France > > > > > > > > > _______________________________________________ > 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 > > > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From wanyu at gazzaleylab.ucsf.edu Mon Apr 4 20:15:12 2016 From: wanyu at gazzaleylab.ucsf.edu (WanYu Hsu) Date: Mon, 4 Apr 2016 11:15:12 -0700 Subject: [FieldTrip] questions about power spectrum analysis and bootstrp Message-ID: Hi community, I am recently running EEG power spectrum analysis. For some reason, I wanted to run the analysis with bootstrapped trials. Is there anyway to apply bootstrap with ft_freqanalysis? I tried adding bootstrap option in ft_sourceanalysis to ft_freqanalysis, but it doesn't work. cfg = []; cfg.foi = 2:30; cfg.method = 'mtmconvol'; cfg.taper = 'hanning'; cfg.keeptrials = 'no'; cfg.t_ftimwin = 3.2 ./ cfg.foi; cfg.toi = -0.5:0.01:0.6; cfg.output = 'powandcsd'; cfg.bootstrap = 'yes'; cfg.numbootstrap = 25; % cfg.trials = 'all'; freq2{s} = ft_freqanalysis(cfg, data_concat_TFR(s)); Any help would be appreciated. Best, WanYu Hsu -------------- next part -------------- An HTML attachment was scrubbed... URL: From gina.joue at univr.it Tue Apr 5 10:51:53 2016 From: gina.joue at univr.it (gj) Date: Tue, 5 Apr 2016 10:51:53 +0200 Subject: [FieldTrip] Error with interpn when calling, ft_sourceinterpolate In-Reply-To: References: Message-ID: <57037CA9.1030602@univr.it> Hi, I just noticed that I had messed up the message threading (no easy way to keep threading as I only receive a daily digest), and I wanted to leave feedback for future reference that the problem was indeed, as you pointed out Jan-Mathijs, because of the incompatible resolution of the template grid I was using -- once I loaded one with a different resolution (standard_sourcemodel3d10mm.mat instead of standard_sourcemodel3d5mm.mat in my case), I didn't get the error anymore. Thanks a lot, Jan-Mathijs!!! g > Message: 4 > Date: Tue, 29 Mar 2016 07:50:05 +0000 > From: "Schoffelen, J.M. (Jan Mathijs)" > To: FieldTrip discussion list > Subject: Re: [FieldTrip] fieldtrip Digest, Vol 64, Issue 32 > Message-ID: > Content-Type: text/plain; charset="utf-8" > > Hi Gina, > > That?s what I was afraid of. By replacing the .pos and .dim you made the data structure inconsistent. The number of source positions should be kept constant, i.e. you need to use a ?template grid? that is defined at the same approximate spatial resolution as your individual grids. The reason for this is that the numeric data (e.g. in source.avg.pow) should have the same number of elements as the size(source.pos,1). > > Best, > Jan-Mathijs > > ------------------------------ > > Message: 3 > Date: Tue, 29 Mar 2016 09:16:29 +0200 > From: gj > To: fieldtrip at science.ru.nl > Subject: Re: [FieldTrip] fieldtrip Digest, Vol 64, Issue 32 > Message-ID: <56FA2BCD.7010201 at univr.it> > Content-Type: text/plain; charset=windows-1252; format=flowed > > Hi Jan-Mathijs, > > Before replacing them with the values from the template grid, > source_proj.dim is 1-row matrix = [15,18,13] > and > source_proj.pos a 3510x3 matrix of doubles > > > After, it's > source_proj.dim is a 1-row matrix = [32,39,34] > and > source_proj.pos is a 42432x3 matrix of doubles > > Thanks! > Gina From maity_winky at yahoo.es Tue Apr 5 14:13:43 2016 From: maity_winky at yahoo.es (=?UTF-8?Q?Mait=C3=A9_Crespo_Garc=C3=ADa?=) Date: Tue, 5 Apr 2016 12:13:43 +0000 (UTC) Subject: [FieldTrip] questions about power spectrum analysis and bootstrp In-Reply-To: References: Message-ID: <25792913.5051433.1459858423045.JavaMail.yahoo@mail.yahoo.com> Dear WanYu Hsu, For frequency analysis, it seems to be implemented differently. You can first compute power and csd values with ft_freqanalysis and then access the bootstrap option with ft_freqstatistics calling the Montecarlo method. Would that way work for you? Best,Maite El Lunes 4 de abril de 2016 20:36, WanYu Hsu escribió: Hi community, I am recently running EEG power spectrum analysis. For some reason, I wanted to run the analysis with bootstrapped trials. Is there anyway to apply bootstrap with ft_freqanalysis? I tried adding bootstrap option in ft_sourceanalysis to ft_freqanalysis, but it doesn't work. cfg = []; cfg.foi         = 2:30; cfg.method = 'mtmconvol'; cfg.taper     = 'hanning'; cfg.keeptrials = 'no'; cfg.t_ftimwin  = 3.2 ./ cfg.foi; cfg.toi            = -0.5:0.01:0.6; cfg.output      = 'powandcsd'; cfg.bootstrap = 'yes'; cfg.numbootstrap  =  25; % cfg.trials = 'all'; freq2{s} = ft_freqanalysis(cfg, data_concat_TFR(s)); Any help would be appreciated. Best, WanYu Hsu _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From r.thomas at nin.knaw.nl Wed Apr 6 15:10:10 2016 From: r.thomas at nin.knaw.nl (Rajat Thomas) Date: Wed, 6 Apr 2016 13:10:10 +0000 Subject: [FieldTrip] FEM using Simbio Message-ID: <1459948210999.59028@nin.knaw.nl> Dear all, Has anyone used the FEM approach to Headmodels using Simbio recently? If so, I get this error: "Elements have wrong orientation or are degenerated" Any ideas? cfg = []; cfg.method ='simbio'; cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows mesh.tissyelabel vol = ft_prepare_headmodel(cfg, mesh); And; ? disp(mesh) hex: [545883x8 double] pnt: [569722x3 double] labels: [545883x1 double] tissue: [545883x1 double] tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} unit: 'mm' cfg: [1x1 struct] Any help would be highly appreciated. Rajat Rajat Mani Thomas Social Brain Lab Netherlands Institute for Neuroscience Amsterdam -------------- next part -------------- An HTML attachment was scrubbed... URL: From carsten.wolters at uni-muenster.de Wed Apr 6 16:03:09 2016 From: carsten.wolters at uni-muenster.de (Carsten Wolters) Date: Wed, 6 Apr 2016 16:03:09 +0200 Subject: [FieldTrip] FEM using Simbio In-Reply-To: <1459948210999.59028@nin.knaw.nl> References: <1459948210999.59028@nin.knaw.nl> Message-ID: <5705171D.3050306@uni-muenster.de> Dear Rajat, the element-node cards of SimBio-NeuroFEM need to follow certain orientations (see www.simbio.de). If you do not want to struggle with meshing/ordering, use the SimBio-VGRID mesher http://vgrid.simbio.de/ that follows the required ordering of nodes. You might use this mesher to produce 1mm geometry-adapted FEM meshes that show good overall performance, see http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf and http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf (latter was just accepted by NeuroImage). Best regards Carsten Am 06.04.2016 um 15:10 schrieb Rajat Thomas: > > Dear all, > > > Has anyone used the FEM approach to Headmodels using Simbio recently? > > > If so, I get this error: > > "Elements have wrong orientation or are degenerated" > > Any ideas? > > cfg = []; > > cfg.method ='simbio'; > > cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows > mesh.tissyelabel > > vol = ft_prepare_headmodel(cfg, mesh); > > > And; > > ​ > > disp(mesh) > hex: [545883x8 double] > pnt: [569722x3 double] > labels: [545883x1 double] > tissue: [545883x1 double] > tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} > unit: 'mm' > cfg: [1x1 struct] > > > Any help would be highly appreciated. > > Rajat > > > > > > > Rajat Mani Thomas > Social Brain Lab > Netherlands Institute for Neuroscience > Amsterdam > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: carsten_wolters.vcf Type: text/x-vcard Size: 402 bytes Desc: not available URL: From s.homolle at donders.ru.nl Wed Apr 6 17:13:42 2016 From: s.homolle at donders.ru.nl (Simon Homolle) Date: Wed, 6 Apr 2016 17:13:42 +0200 Subject: [FieldTrip] FEM using Simbio In-Reply-To: <1459948210999.59028@nin.knaw.nl> References: <1459948210999.59028@nin.knaw.nl> Message-ID: <41AC91C9-638C-4B4E-B19F-933D96A76249@donders.ru.nl> Dear Rajat, could you please describe how you generated your mesh? Bests, Simon Homölle PhD Candidate Donders Institute for Brain, Cognition and Behaviour Centre for Cognitive Neuroimaging Radboud University Nijmegen Phone: +31-(0)24-36-65059 > On 06 Apr 2016, at 15:10, Rajat Thomas wrote: > > Dear all, > > Has anyone used the FEM approach to Headmodels using Simbio recently? > > If so, I get this error: > "Elements have wrong orientation or are degenerated" > > Any ideas? > > cfg = []; > cfg.method ='simbio'; > cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows mesh.tissyelabel > vol = ft_prepare_headmodel(cfg, mesh); > > And; > ​ > disp(mesh) > hex: [545883x8 double] > pnt: [569722x3 double] > labels: [545883x1 double] > tissue: [545883x1 double] > tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} > unit: 'mm' > cfg: [1x1 struct] > > Any help would be highly appreciated. > > Rajat > > > > > > > Rajat Mani Thomas > Social Brain Lab > Netherlands Institute for Neuroscience > Amsterdam > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From gina.joue at univr.it Wed Apr 6 17:42:47 2016 From: gina.joue at univr.it (gj) Date: Wed, 6 Apr 2016 17:42:47 +0200 Subject: [FieldTrip] ft_source2sparse usage for EEG data Message-ID: <57052E77.5070709@univr.it> Hi FieldTrip community, Sorry for the onslaught of newbie questions. I would like to run a whole-brain network analysis on source level on a 2-sec continuous recording of EEG data. Following the tutorials (for MEG), I first run ft_source2sparse to reduce the matrix to only voxels inside the skull: >> source_sparse = ft_source2sparse(source_proj); total number of dipoles : 6804 number of dipoles inside brain: 3294 number of dipoles outside brain: 3510 When I then try to run the connectivity analysis (ft_connectivityanalysis), regardless of which connectivity method, I get the error: ---- error --- Requested 92232x92232 (126.8GB) array exceeds maximum array size preference. Creation of arrays greater than this limit may take a long time and cause MATLAB to become unresponsive. See array size limit or preference panel for more information. Error in univariate2bivariate (line 314) data.crsspctrm = (transpose(mom)*conj(mom))./nrpt; Error in ft_connectivityanalysis (line 434) [data, powindx, hasrpt] = univariate2bivariate(data, 'mom', 'crsspctrm', dtype, 'cmb', cfg.refindx, 'keeprpt', 0); ----end error--- I guess it is related to how I might have created the sourcemodel (ft_freqanalysis run with method='mtmfft', output='fourier', keeptrials='yes')? I am using FieldTrip ver.20160309. Thank you very much in advance for any help! Gina From pmetzak at gmail.com Thu Apr 7 01:47:49 2016 From: pmetzak at gmail.com (Paul Metzak) Date: Wed, 6 Apr 2016 16:47:49 -0700 Subject: [FieldTrip] TFR plotting following ft_freqbaseline Message-ID: Hello Fieldtrippers, I have a quick question about the output from my ft_freqanalysis. I ran ft_freqbaseline but when I plot the TFR using TFRmultiplot, I still have activity in the baseline period. I have included the cfg for the ft_freqanalysis call as well as the cfg for the ft_freqbaseline call and a .png from one of the sensors with this message. I took a look at the TFR plots for the pre- and post- ft_freqbaseline call and they look different so it is doing it's job but I am just wondering if activity in the baseline period represents a problem with the way I have analyzed my data thus far, or whether it is a normal result in fairly rapid MEG designs. Thanks for any information you can offer! Paul %%% ft_freqanalysis cfg %%%% tstep: 0.0500 twindow: 0.5000 fLow: 2 fHigh: 160 fstep: 2 method: 'mtmconvol' taper: 'hanning' rmvbl: 'yes' bltype: 'absolute' baseline: [-0.5000 0] trlbegin: -1 trlend: 2 conditions: [1 2 3] output: 'powandcsd' runname: 'run1' foi: [1x80 double] t_ftimwin: [80x1 double] toi: [1x51 double] %%% ft_freqbaseline cfg %%%% baseline: [-0.5000 0] baselinetype: 'absolute' -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: baseline_corr_prob.png Type: image/png Size: 10004 bytes Desc: not available URL: From carsten.wolters at uni-muenster.de Thu Apr 7 09:22:10 2016 From: carsten.wolters at uni-muenster.de (Carsten Wolters) Date: Thu, 7 Apr 2016 09:22:10 +0200 Subject: [FieldTrip] FEM using Simbio In-Reply-To: <5705171D.3050306@uni-muenster.de> References: <1459948210999.59028@nin.knaw.nl> <5705171D.3050306@uni-muenster.de> Message-ID: <57060AA2.8040804@uni-muenster.de> Dear Rajat, if you want to use another meshing tool than VGRID, the element-node-ordering of SimBio-NeuroFEM can be downloaded here: http://www.sci.utah.edu/~wolters/SimBio/SimBioNeuroFEMElementNodeOrdering0001.pdf For regular cubic elements and geometry-adapted cubic elements, please see the ordering of x23. I hope this will finally fully answer your question. Best regards Carsten Am 06.04.2016 um 16:03 schrieb Carsten Wolters: > Dear Rajat, > > the element-node cards of SimBio-NeuroFEM need to follow certain > orientations (see www.simbio.de). > > If you do not want to struggle with meshing/ordering, use the > SimBio-VGRID mesher > http://vgrid.simbio.de/ > that follows the required ordering of nodes. You might use this mesher > to produce 1mm geometry-adapted FEM meshes > that show good overall performance, see > http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf > and > http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf > (latter was just accepted by NeuroImage). > > Best regards > Carsten > > Am 06.04.2016 um 15:10 schrieb Rajat Thomas: >> >> Dear all, >> >> >> Has anyone used the FEM approach to Headmodels using Simbio recently? >> >> >> If so, I get this error: >> >> "Elements have wrong orientation or are degenerated" >> >> Any ideas? >> >> cfg = []; >> >> cfg.method ='simbio'; >> >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows >> mesh.tissyelabel >> >> vol = ft_prepare_headmodel(cfg, mesh); >> >> >> And; >> >> ​ >> >> disp(mesh) >> hex: [545883x8 double] >> pnt: [569722x3 double] >> labels: [545883x1 double] >> tissue: [545883x1 double] >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >> unit: 'mm' >> cfg: [1x1 struct] >> >> >> Any help would be highly appreciated. >> >> Rajat >> >> >> >> >> >> >> Rajat Mani Thomas >> Social Brain Lab >> Netherlands Institute for Neuroscience >> Amsterdam >> >> >> _______________________________________________ >> 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 -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: carsten_wolters.vcf Type: text/x-vcard Size: 402 bytes Desc: not available URL: From j.herring at donders.ru.nl Thu Apr 7 10:35:41 2016 From: j.herring at donders.ru.nl (Herring, J.D. (Jim)) Date: Thu, 7 Apr 2016 08:35:41 +0000 Subject: [FieldTrip] TFR plotting following ft_freqbaseline In-Reply-To: References: Message-ID: <3D00B7615FB58D46A0B49B9AD67A33EB3D98D61D@exprd01.hosting.ru.nl> Dear Paul, You can check whether the baseline correction worked by seeing whether the mean in the baseline per frequency is zero. If your frequency data is contained in the structure ‘freq’ you could do something like the following: baseline = [-.5 0]; channel_idx = find(strcmp(freq.label,’MLO11’)); time_idx = find(freq.time>=baseline(1)&freq.time<=baseline(2)); mean_baseline = nanmean(freq.powspctrm(channel_idx,:,time_idx),3); ‘mean_baseline’ should be roughly around zero for all frequencies. I suspect that the positive activity at/slightly before zero cancels the negative activity around -500 to -400. Here it is important to realize that whenever you are calculating a time-frequency analysis you are moving a sliding time-window over your data. The value at time-point zero therefore represent the power at that particular frequency from minus to plus half of the chosen window length. Given that your time-window is 500ms, the data at time-point zero therefore reflects the power from [-250 – 250ms]. It is therefore very likely that it contains stimulus-related activity. If you want to be sure that your baseline data does not represent any stimulus-related activity you should choose a baseline period earlier than, or at -250 ms (ie. Half your sliding time window size). Best, Jim From: fieldtrip-bounces at science.ru.nl [mailto:fieldtrip-bounces at science.ru.nl] On Behalf Of Paul Metzak Sent: Thursday, April 07, 2016 1:48 AM To: fieldtrip at science.ru.nl Subject: [FieldTrip] TFR plotting following ft_freqbaseline Hello Fieldtrippers, I have a quick question about the output from my ft_freqanalysis. I ran ft_freqbaseline but when I plot the TFR using TFRmultiplot, I still have activity in the baseline period. I have included the cfg for the ft_freqanalysis call as well as the cfg for the ft_freqbaseline call and a .png from one of the sensors with this message. I took a look at the TFR plots for the pre- and post- ft_freqbaseline call and they look different so it is doing it's job but I am just wondering if activity in the baseline period represents a problem with the way I have analyzed my data thus far, or whether it is a normal result in fairly rapid MEG designs. Thanks for any information you can offer! Paul %%% ft_freqanalysis cfg %%%% tstep: 0.0500 twindow: 0.5000 fLow: 2 fHigh: 160 fstep: 2 method: 'mtmconvol' taper: 'hanning' rmvbl: 'yes' bltype: 'absolute' baseline: [-0.5000 0] trlbegin: -1 trlend: 2 conditions: [1 2 3] output: 'powandcsd' runname: 'run1' foi: [1x80 double] t_ftimwin: [80x1 double] toi: [1x51 double] %%% ft_freqbaseline cfg %%%% baseline: [-0.5000 0] baselinetype: 'absolute' -------------- next part -------------- An HTML attachment was scrubbed... URL: From j.vorwerk at uni-muenster.de Thu Apr 7 14:25:42 2016 From: j.vorwerk at uni-muenster.de (Johannes Vorwerk) Date: Thu, 7 Apr 2016 14:25:42 +0200 Subject: [FieldTrip] FEM using Simbio In-Reply-To: <5705171D.3050306@uni-muenster.de> References: <1459948210999.59028@nin.knaw.nl> <5705171D.3050306@uni-muenster.de> Message-ID: <435735E3-7D87-4DD6-A2C1-E2BBFBBF4B44@googlemail.com> Hi, this question was already answered in this thread http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html If ft_volumereslice is not applied before the mesh generation, the afterwards applied transformation might flip the directions of the mesh, leading to the described error. Best, Johannes > Am 06.04.2016 um 16:03 schrieb Carsten Wolters : > > Dear Rajat, > > the element-node cards of SimBio-NeuroFEM need to follow certain orientations (see www.simbio.de ). > > If you do not want to struggle with meshing/ordering, use the SimBio-VGRID mesher > http://vgrid.simbio.de/ > that follows the required ordering of nodes. You might use this mesher to produce 1mm geometry-adapted FEM meshes > that show good overall performance, see > http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf > and > http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf > (latter was just accepted by NeuroImage). > > Best regards > Carsten > > Am 06.04.2016 um 15:10 schrieb Rajat Thomas: >> Dear all, >> >> Has anyone used the FEM approach to Headmodels using Simbio recently? >> >> If so, I get this error: >> "Elements have wrong orientation or are degenerated" >> >> Any ideas? >> >> cfg = []; >> cfg.method ='simbio'; >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows mesh.tissyelabel >> vol = ft_prepare_headmodel(cfg, mesh); >> >> And; >> ​ >> disp(mesh) >> hex: [545883x8 double] >> pnt: [569722x3 double] >> labels: [545883x1 double] >> tissue: [545883x1 double] >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >> unit: 'mm' >> cfg: [1x1 struct] >> >> Any help would be highly appreciated. >> >> Rajat >> >> >> >> >> >> >> Rajat Mani Thomas >> Social Brain Lab >> Netherlands Institute for Neuroscience >> Amsterdam >> >> >> _______________________________________________ >> 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 -------------- next part -------------- An HTML attachment was scrubbed... URL: From michelic72 at gmail.com Thu Apr 7 17:36:37 2016 From: michelic72 at gmail.com (Cristiano Micheli) Date: Thu, 7 Apr 2016 17:36:37 +0200 Subject: [FieldTrip] FEM using Simbio In-Reply-To: <1459948210999.59028@nin.knaw.nl> References: <1459948210999.59028@nin.knaw.nl> Message-ID: Hi Rajat My guess is that the orientations of your hexahedrons are not correct. According to a low-level file's internal rules, elements' orientations have to abide strict rules (not sure what exactly the contraints are in this case though...). I had same problems when for example the triangular boundaries used to define the 3d hexahedral mesh were not topologically correct, to start with. Admittedly this approach requires a lot of technical expertise. Can I ask you what do you need a FEM model for? Regards Cris Micheli On Wed, Apr 6, 2016 at 3:10 PM, Rajat Thomas wrote: > Dear all, > > > Has anyone used the FEM approach to Headmodels using Simbio recently? > > > If so, I get this error: > "Elements have wrong orientation or are degenerated" > > Any ideas? > > cfg = []; > > cfg.method ='simbio'; > > cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows > mesh.tissyelabel > > vol = ft_prepare_headmodel(cfg, mesh); > > > And; > > ​ > disp(mesh) > hex: [545883x8 double] > pnt: [569722x3 double] > labels: [545883x1 double] > tissue: [545883x1 double] > tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} > unit: 'mm' > cfg: [1x1 struct] > > > Any help would be highly appreciated. > > Rajat > > > > > > > Rajat Mani Thomas > Social Brain Lab > Netherlands Institute for Neuroscience > Amsterdam > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From giovannipellegrino at gmail.com Thu Apr 7 21:02:05 2016 From: giovannipellegrino at gmail.com (Giovanni Pellegrino) Date: Thu, 7 Apr 2016 15:02:05 -0400 Subject: [FieldTrip] Dipole fitting Message-ID: Dear Fieldtrippers, Do you know if the FieldTrip Dipole Fitting has been compared to the CTF, Elekta, BESA or Curry? Are you aware of any study on this topic? Thanks in advance for your help Giovanni -- Giovanni Pellegrino, MD Multimodal Functional Imaging Laboratory Montreal Neurological Institute, McGill University Address: 332 Duff Medical Building, 3775 rue University, Montreal, QC, H3A 2B4, Canada Phone: (514) 398–1678 Fax: (514) 398–7461 Email: giovannipellegrino at gmail.com, giovanni.pellegrino2 at mcgill.ca Homepage: http://www.bic.mni.mcgill.ca/ResearchLabsMFIL/PeopleGiovanni -------------- next part -------------- An HTML attachment was scrubbed... URL: From ole.jensen at donders.ru.nl Fri Apr 8 09:23:46 2016 From: ole.jensen at donders.ru.nl (Ole Jensen) Date: Fri, 8 Apr 2016 09:23:46 +0200 Subject: [FieldTrip] Birmingham-Illinois BRIDGE Fellowships Message-ID: <57075C82.8030309@donders.ru.nl> Dear all, I would like to point you to a set of Birmingham-Illinois BRIDGE Fellowships providing some exciting research and career prospects: http://www.birminghamillinoisbridge.org/index.php/fellows/ In particular the areas 'Cognition and Ageing' and 'Brain Trauma' could be relevant for candidates with EEG/MEG expertise. All the best, Ole -- Prof. dr. Ole Jensen http://www.neuosc.com From laetitia.lalla at inserm.fr Fri Apr 8 10:27:58 2016 From: laetitia.lalla at inserm.fr (laetitia.lalla at inserm.fr) Date: Fri, 08 Apr 2016 10:27:58 +0200 Subject: [FieldTrip] Using FieldTrip to analyse LFP recordings in rat In-Reply-To: References: <2595287eebb0aeacfe5761a9de10de24@inserm.fr> <68a5ba763224075e6d9ec9aa7684221a@inserm.fr> <815A9820E75FBC4F96B7CD3A8089D11C378AE3E0@exprd04.hosting.ru.nl> <815A9820E75FBC4F96B7CD3A8089D11C378AE4DA@exprd04.hosting.ru.nl> <17c319aeab6f35a621fb193e8b051792@inserm.fr> Message-ID: <628babdc107aebd4cc7588ea87ce5ea6@inserm.fr> Hello everyone, my name is Laetitia and I'm a Phd student in Marseille (France). I'm doing in-vivo recording in freely-moving rats : I implant them with 2 electrodes deep into 2 different regions of the brain. I'm studying the Local Field Potentials and I want to use FieldTrip to analyse the data. To simplify : - I have 2 rats. - Each rat did 20 sessions of the task (on 20 different days). - Each session consists of 20 trials of condition 1 and 20 trials of condition 2. I have 2 questions. 1) I have the feeling it would be meaningless to do "source reconstruction" because my electrodes are already deep inside my "source" and the LFP I am recording is very local. (My electrodes have 32 channels separated by 20-200 µm. The LFP is very very similar across all the channels, so I averaged over the 32 channels to have one signal for each region.) However, I see that 2 different functions exist for the statistics : FT_FREQSTATISTICS AND FT_SOURCESTATISTICS. So far, I've been using ft_freqstatistics but I encounter some issues (for exemple, doing monte-carlo permutation test to assess the imaginary coherence). I thought of computing it manually, but I'm thinking that maybe more stuff are implemented in ft_sourcestatisctics ? → Are these 2 functions fundamentally different or do they call the same sub-fonctions (and my problem has actually nothing to do with that) ? 2) I'm a bit confused with the vocabulary from EEG and MEG studies (I'm not used to it yet...). From what I understood, in human studies, you can do comparison for a single subject (across trials) or across subjects. But I have 3 levels of comparisons in my design : - WITHIN A SESSION, I WANT TO COMPARE ACROSS TRIALS (the 20 trials of condition 1 VS the 20 trials of condition 2). - WITHIN A RAT, I WANT TO COMPARE ACROSS SESSIONS (between the 2 conditions) - then - in the very end - ACROSS RATS. But I have only 2 rats so far, so I will deal with this later. I'm a bit confused when reading the tutorials and the mailing list, especially when it comes to the statistics... For example : this is from an email from 2013 by Eric Maris about "Nonparametric statistical testing of phase coherence" (http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006401.html) "To compare coherence between conditions across subjects (instead of trials), you need a different statfun: depsamplesT (for a within-subjects design; subjects have participated in all conditions) or indepsamplesT (for a between-subjects design; subjects have participated in only one condition)." → If I want to compare across sessions (for a same rat), can I actually consider that my different sessions are "subjects"? And then compare coherence "across subjects" would be doing it "across sessions" ? And I would be in a "within-subject design" since my sessions involve the 2 conditions every time ? I realise that it may be very confusing... I hope you will understand my problem ! And if anyone already applied fieldtrip functions to do statistics on a different framework that the usual EEG/MEG, please let me know ! Thanks a lot, Laetitia Lalla PhD Student in Neuroscience INMED, Marseille, France -------------- next part -------------- An HTML attachment was scrubbed... URL: From anne.urai at gmail.com Fri Apr 8 21:40:12 2016 From: anne.urai at gmail.com (Anne Urai) Date: Fri, 8 Apr 2016 21:40:12 +0200 Subject: [FieldTrip] ft_channelrepair with channel absent from data In-Reply-To: <6B298E85-A270-4D51-9219-F74A1C4B4AEE@donders.ru.nl> References: <50B23369.5020105@fcdonders.ru.nl> <50B33A53.2000701@donders.ru.nl> <6B298E85-A270-4D51-9219-F74A1C4B4AEE@donders.ru.nl> Message-ID: Dear FieldTrippers, I head a similar problem with interpolating missing channels from a CTF275 system. Since I couldn't find a final answer on the mailing list, I thought I'd share my solution. Specifically, giving both a cfg.layout and a cfg.neighbours input into ft_channelrepair avoids ft_fetch_sens getting the grad structure from the data (from which the channels that were not recorded are missing). With this setting, the sensors that are needed are defined based on the layout from the fieldtrip/templates directory, which is complete. Happy interpolating!  cfg = [];  cfg.layout = 'CTF275';  cfg.method = 'template';  neighbours = ft_prepare_neighbours(cfg);    cfg = [];  cfg.neighbours = neighbours;  cfg.method = 'spline'; % spline can handle missing grad struct  cfg.layout = 'CTF275'; % use this rather than grad structure to find sens info    % find missing channels in this dataset  cfg.missingchannel = {neighbours((~ismember({neighbours(:).label}, data.label))).label};  data = ft_channelrepair(cfg,data);  assert(length(data.label) == 275, 'CTF275 not completely interpolated!'); —  Anne E. Urai, MSc PhD student | Institut für Neurophysiologie und Pathophysiologie  Universitätsklinikum Hamburg-Eppendorf | Martinistrasse 52, 20246 | Hamburg, Germany  www.anneurai.net / @AnneEUrai From: Linsey Roijendijk Reply: FieldTrip discussion list Date: 20 December 2012 at 18:44:31 To: FieldTrip discussion list Subject:  Re: [FieldTrip] ft_channelrepair with channel absent from data Correction: I made a mistake in my e-mail, I meant the spherical spline interpolation method, because that's the one Jorn said should work. On Dec 20, 2012, at 6:31 PM, Linsey Roijendijk wrote: Hi all, I have also been trying to reinterpolate MEG channels that were never recorded with the nearest neighbour interpolation method, however when calling the method (in the same way Tom also used it) the function seems to do something, however it did not interpolate the missing sensors.  There were still 273 sensors instead of 275.  Do I need to give along a special cfg.grad or do something else? Thanks in advance, Linsey On Nov 26, 2012, at 10:45 AM, Jörn M. Horschig wrote:q Hey Tom, I guess I have several questions all at once: 1) Is it actually possible to reinterpolate MEG channels that were never recorded - eg because the channels were deactivated when the acquisition took place? Should work, but only with the SSI (=spherical spline interpolation) method. For the nearest neighbour interpolation, the function constructs a list of neuighbouring and constructs a weighted average. The function, however, wants to weigh each sensor according to its distance from the sensor to be reconstructed. That information can only be found in the grad structure, but in the grad structure there are only sensors which were recorded, thus the distance from a missing sensor cannot be measured because its position is missing in the grad structure. SSI should work though, cause it relies on a different rationale. 2) What might be causing the error I'm seeing? Since you have 301 channels rather than 275, my suspicion is that you include reference gradiometers. This should not fail in principle, though... maybe I can drop by your office to check it out? Got some time right now? 3) Where is ft_fetch_sens? It's a private function, can be found in FieldTrip/private. You have to cd to that directory in order for Matlab to find it (the idea behind private function is that there are only visible for higher-level function and 'hidden' for all other functions). Best, Jörn Thanks for help with any of the above! Best, Tom -- Tom Marshall, MSc. Neuronal Oscillations Group, Donders Centre for Cognitive Neuroimaging tel: +31(0)243668487 email: t.marshall at fcdonders.ru.nl postal: PO Box 9101, 6500HB, Nijmegen, The Netherlands visiting: Kapittelweg 29, 6525EN, Nijmegen, The Netherlands _______________________________________________ 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 -- Linsey Roijendijk MSc. Donders Institute for Brain, Cognition and Behaviour Centre for Neuroscience dept. of Biophysics Radboud University Nijmegen Montessorilaan 3, Room B.02.34 P.O.Box 9104 6500 HE Nijmegen The Netherlands Tel: +31(0)24 3612616 L.Roijendijk at donders.ru.nl _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -- Linsey Roijendijk MSc. Donders Institute for Brain, Cognition and Behaviour Centre for Neuroscience dept. of Biophysics Radboud University Nijmegen Montessorilaan 3, Room B.02.34 P.O.Box 9104 6500 HE Nijmegen The Netherlands Tel: +31(0)24 3612616 L.Roijendijk at donders.ru.nl _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From Max.Cantor at Colorado.EDU Fri Apr 8 23:02:17 2016 From: Max.Cantor at Colorado.EDU (Max Cantor) Date: Fri, 8 Apr 2016 15:02:17 -0600 Subject: [FieldTrip] TFR mask stats question; Baselined vs unbaselined statistics question Message-ID: Hi fieldtrippers, I have two unrelated stats questions, but I figured I'd post them together: 1. I've run within subjects permutation statistics testing the difference between an anomaly and control condition for three different language conditions; preposition, morphosyntax, and semantics. The code is nearly identical for both my ERPs and TFRs, except that when I plot my ERPs with cfg.maskparameter = 'mask', cfg.parameter = 'stat', and cfg.maskalpha = 0.025, it seems to multiplot just fine, whereas when I try to do the same for the TFRs, my multiplotted plots are blank, but when I comment out the mask, the stat plots are fine. I'll attach the code, but is there something I'm doing obviously wrong? Also, am I correct that my maskalpha should correspond to my alpha, and not my cluster alpha? This is the TFR code, but the ERP code is the exact same except for with timelocked data as the input and ft_timelockstatistics as the function. cfg = []; cfg.method = 'montecarlo'; cfg.statistic = 'depsamplesT'; cfg.correctm = 'cluster'; cfg.clusteralpha = 0.05; cfg.clusterstatistic = 'maxsum'; cfg.minnbchan = 2; cfg.neighbours = neighbours; cfg.tail = 0; cfg.clustertail = 0; cfg.alpha = 0.025; cfg.numrandomization = 1000; nsubj = length(tot_tfr2_bl{1}); design = zeros(2,2*nsubj); for i = 1:nsubj design(1,i) = i; end for i = 1:nsubj design(1,nsubj+i) = i; end design(2,1:nsubj) = 1; design(2,nsubj+1:2*nsubj) = 2; cfg.design = design; cfg.uvar = 1; cfg.ivar = 2; % Anomaly vs Control stat_tfr{1} = ft_freqstatistics(cfg, tot_tfr2_bl{1}{:}, tot_tfr2_bl{2}{:}); % Preposition stat_tfr{2} = ft_freqstatistics(cfg, tot_tfr2_bl{3}{:}, tot_tfr2_bl{4}{:}); % Semantics stat_tfr{3} = ft_freqstatistics(cfg, tot_tfr2_bl{5}{:}, tot_tfr2_bl{6}{:}); % Morphosyntax This is the plotting code. Again, it is virtually the same for the ERPs except the non-stats configurations would be what makes sense for ERPs. % Anomaly vs Control TFR stats multiplot cfg = []; cfg.xlim = [-0.2 1]; cfg.zlim = [-3 3]; % proportion from baseline cfg.layout = [max_dir '/quickcap64.mat']; cfg.maskparameter = 'mask'; cfg.parameter = 'stat'; cfg.maskalpha = 0.025; ft_multiplotTFR(cfg, stat_tfr{1}); title('Preposition'); ft_multiplotTFR(cfg, stat_tfr{3}); title('Semantic'); ft_multiplotTFR(cfg, stat_tfr{5}); title('Morphosyntactic'); 2. The second question is about analyzing baselined vs unbaselined data. I've seen in the tutorials that there is a somewhat different method for analyzing trial vs baseline period. However, what I've done instead (for both ERP and TFR), is use the same within-subjects statistics as with anomaly vs control, except with the inputs being baselined vs unbaselined ERPs or TFRs, e.g. Baselined Preposition Anomaly vs Unbaselined Preposition Anomaly, etc. I understand that the proposed method and my method are not testing the same thing exactly, but is this a reasonable way of testing the effect of the baselining anyway? Thanks, Max -- Max Cantor Graduate Student Cognitive Neuroscience of Language Lab University of Colorado Boulder -------------- next part -------------- An HTML attachment was scrubbed... URL: From laetitia.lalla at inserm.fr Sun Apr 10 18:36:56 2016 From: laetitia.lalla at inserm.fr (laetitia.lalla at inserm.fr) Date: Sun, 10 Apr 2016 18:36:56 +0200 Subject: [FieldTrip] Implementation of statistical testing for imaginary coherence differences in FieldTrip In-Reply-To: <815A9820E75FBC4F96B7CD3A8089D11C378AE4DA@exprd04.hosting.ru.nl> References: <2595287eebb0aeacfe5761a9de10de24@inserm.fr> <68a5ba763224075e6d9ec9aa7684221a@inserm.fr>, <815A9820E75FBC4F96B7CD3A8089D11C378AE3E0@exprd04.hosting.ru.nl>, <815A9820E75FBC4F96B7CD3A8089D11C378AE4DA@exprd04.hosting.ru.nl> Message-ID: Dear FieldTrip community, I'm a PhD student in Marseille studying LFPs of freely-moving rats from 2 different regions of the brain. Right now, I'm looking at the imaginary part of the coherency, and I'm interested in the difference in iCoh between 2 conditions (trial and baseline). I searched the old FieldTrip emails and I found this conversation about the imaginary part of the coherency and its statistical testing : http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006402.html If I understood correctly, and based on what Jörn M. Horschig and Eric Maris wrote in April 2013, there was no straightforward implementation of the statistical testing of the differences in the imaginary coherence (between 2 conditions) in FieldTrip at that time. (Jörn wrote "You could have a look at Guido Nolte's paper on imaginary coherence and look it up in the methods section how he is computing it" and Eric wrote : "For a single-subject study, you would have to write your own statfun"). Is this still the case ? Or maybe this is more straightforward now (maybe with new Fieldtrip functions) ? if not, has anyone already tried some similar testing with Fieldtrip or just with Matlab ? Thank you very much for all the help you're providing! Best, Laetitia -------------- next part -------------- An HTML attachment was scrubbed... URL: From gina.joue at univr.it Mon Apr 11 14:37:54 2016 From: gina.joue at univr.it (gj) Date: Mon, 11 Apr 2016 14:37:54 +0200 Subject: [FieldTrip] ft_source2sparse usage for EEG data In-Reply-To: References: Message-ID: <570B9AA2.9050000@univr.it> Hi, Sorry for bumping this message about exceeding the max array size when trying to do a whole brain network analysis with ft_connectivityanalysis, but I am at a loss....Any help (even generally related to FieldTrip connectivity analysis tutorials/scripts specifically for EEG data) very much appreciated! Thanks! Gina From jan.schoffelen at donders.ru.nl Mon Apr 11 15:15:16 2016 From: jan.schoffelen at donders.ru.nl (Schoffelen, J.M. (Jan Mathijs)) Date: Mon, 11 Apr 2016 13:15:16 +0000 Subject: [FieldTrip] ft_source2sparse usage for EEG data References: Message-ID: <096A2A53-E33F-491C-B90F-FBF48172F10B@donders.ru.nl> Hi Gina, A dimensionality of 92232 ( ^ 2) suggests that you have 28 times the number of inside dipoles. I suspect a interaction between FieldTrip’s (perhaps occassionally sloppy) internal data bookkeeping and your specification of the input data/cfg. Where does this factor of 28 come from? Best, Jan-Mathijs > On 11 Apr 2016, at 14:37, gj wrote: > > Hi, > > Sorry for bumping this message about exceeding the max array size when trying to do a whole brain network analysis with ft_connectivityanalysis, but I am at a loss....Any help (even generally related to FieldTrip connectivity analysis tutorials/scripts specifically for EEG data) very much appreciated! > > Thanks! > Gina > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip From assaf.harel at wright.edu Mon Apr 11 15:31:32 2016 From: assaf.harel at wright.edu (Harel, Assaf) Date: Mon, 11 Apr 2016 13:31:32 +0000 Subject: [FieldTrip] Postdoc Position in Human Neuroscience and Visual Cognition Lab Wright State University Message-ID: Human Neuroscience and Visual Cognition Lab Department of Psychology Wright State University A post-doc position is now available at the Human Neuroscience and Visual Cognition Lab at the Department of Psychology, Wright State University. The lab is headed by Dr. Assaf Harel and investigates high-level vision and its neural substrates. We are particularly interested in how visual recognition occurs in real-world settings and adopt a neuroergonomic approach to study the applied aspects of high-level vision. For this purpose, we employ a diversity of cognitive neuroscience methods, including EEG, fMRI, psychophysics, and eye tracking. Research topics include, but are not limited to the following areas: visual expertise, object and scene recognition, categorization and perceptual learning. The position is fully funded for two years. The successful candidate will hold a PhD in Cognitive Neuroscience, Cognitive Psychology, Neurobiology, Computer Science, or any other related discipline by the start date of the position. Strong background and familiarity with fMRI or EEG research is required. Experience in computer programming, especially with Matlab is highly encouraged and will be considered a strong advantage. For more information on this position contact Dr. Assaf Harel: assaf.harel at wright.edu. Applicants should visit the following link to upload CV, statement of research, and three letters of reference: https://jobs.wright.edu/postings/8517 The Department of Psychology is housed in the College of Science and Mathematics, offers a Ph.D. in Human Factors and Industrial/ Organizational Psychology, and has 3 undergraduate concentration areas: (1) Cognition and Perception, (2) Industrial/ Organizational, and (3) Behavioral Neuroscience. Wright State University was recently ranked among the "Best in the Midwest" universities by The Princeton Review, listed among 260 Best National Universities in the annual "America's Best Colleges" rankings by U.S. News and World Report, and ranked fourth nationally among universities with limited numbers of doctoral programs in the Faculty Scholarly Productivity Index. Wright State University is an Equal Opportunity/Affirmative Action Employer. -------------- next part -------------- An HTML attachment was scrubbed... URL: From elinicolaisen at gmail.com Mon Apr 11 16:21:52 2016 From: elinicolaisen at gmail.com (Eliana Nicolaisen) Date: Mon, 11 Apr 2016 11:21:52 -0300 Subject: [FieldTrip] Grand average with deleted channels Message-ID: Dear all, I'm trying to make an ERP grand average using version 20150301. In some subjects I deleted bad channels. Those channels were replaced for NaNs. When I make the grand average using ft_timelockaverage, the grand average is composed only for the common channels across subjects. In other words, in channels deleated at least in one subject the grand average is NaN. This is because ft_timelockanalysis in this version calculates the average making a sum and dividng into degrees of freedom: *grandavg.avg = reshape(sum(avgmat, 1), datsiz)./ResultDOF; * (in line 187 of revision '$Id: ft_timelockgrandaverage.m 10194 2015-02-11 09:08:16Z roboos $') However, I tried version 20121014 that my colleague uses. In this version ft_timelockedanalysis makes a mean: *ResultGrandavg = mean(avgmat, 1);* (in line 183 of revision '$Id: ft_timelockgrandaverage.m 6750 2012-10-13 15:07:32Z roboos $') In the version 20121014 is easy to make a correction that calculates a grand average taking into account NaNs (just changing mean for nanmean). However, in version 20150301 making a similar correction seems more complicated. Question 1: Why version 20150301 calculates average using sum and division instead of using nanmean? Question 2: Do someone have a suggestion about how to change version 20150301? Any comment would be greatly appreciated. Kind regards, Eliana Nicolaisen -------------- next part -------------- An HTML attachment was scrubbed... URL: From gina.joue at univr.it Tue Apr 12 10:41:19 2016 From: gina.joue at univr.it (gj) Date: Tue, 12 Apr 2016 10:41:19 +0200 Subject: [FieldTrip] ft_source2sparse usage for EEG data In-Reply-To: <570B9AA2.9050000@univr.it> References: <570B9AA2.9050000@univr.it> Message-ID: <570CB4AF.6030401@univr.it> Thank you for your help, Jan Mathijs! These are all the related steps I did leading up to the ft_source2sparse call, in case. My input EEG data to FieldTrip are 2 seconds of passive visual stimulation, preprocessed and averaged across all trials per condition per subject in another software. Thank you! g ------------- begin snippet -------------- cfg = []; cfg.method = 'mtmfft'; cfg.output = 'fourier'; cfg.keeptrials = 'yes'; cfg.tapsmofrq = 2; cfg.foi = 12; fft = ft_freqanalysis(cfg, data); cfg = []; cfg.output = {'brain','skull','scalp'}; mri_seg = ft_volumesegment(cfg, mri); % mri from standard_mri.mat (mm) cfg=[]; cfg.tissue={'brain','skull','scalp'}; cfg.numvertices = [3000 1600 800]; mesh_hd=ft_prepare_mesh(cfg,mri_seg); cfg = []; cfg.method = 'bemcp'; headmodel = ft_prepare_headmodel(cfg, mesh_hd); cfg = []; cfg.grid.warpmni = 'yes'; cfg.grid.template = template_grid; % standard_sourcemodel3d10mm.mat cfg.grid.nonlinear = 'yes'; cfg.mri = mri; sourcemodel = ft_prepare_sourcemodel(cfg); cfg = []; cfg.elec = elecR; % elec realigned to standard_bem.mat cfg.headmodel = headmodel; % output from ft_prepare_headmodel cfg.grid = sourcemodel; % output from ft_prepare_sourcemodel lf = ft_prepare_leadfield(cfg); cfg = []; cfg.frequency = fft.freq; cfg.elec = elecR; cfg.method = 'eloreta'; cfg.grid = lf; cfg.vol = vol; % from standard_bem.mat cfg.keeptrials = 'yes'; %cfg.rawtrial = 'yes'; source = ft_sourceanalysis(cfg, fft); cfg = []; cfg.projectmom = 'yes'; source_proj = ft_sourcedescriptives(cfg,source); ------------- end snippet -------------- From ronny.ibrahim at mq.edu.au Tue Apr 12 11:44:44 2016 From: ronny.ibrahim at mq.edu.au (Ronny Ibrahim) Date: Tue, 12 Apr 2016 09:44:44 +0000 Subject: [FieldTrip] Averaging 4D spatio-temporospectral data (trials x channels x frequencies x time) Message-ID: Dear Fellow fieldtrip users, I was wondering whether there is any function which let's me to average my 4D (trials x channels x frequencies x time) time-frequency structure along the trials dimension. I have tried to look into ft_freqgrandaverage function but it won't let me do it. I had set the keeptrials configuration to 'yes' with the aim of representing my data in the relative percentage change format by using the ft_freqbaseline to represent my data in the 'relchange' (percent change format) in which I would like to average. Many thank's in advance for your kind help. Kind Regards, Ronny -------------- next part -------------- An HTML attachment was scrubbed... URL: From maity_winky at yahoo.es Tue Apr 12 13:43:45 2016 From: maity_winky at yahoo.es (=?UTF-8?Q?Mait=C3=A9_Crespo_Garc=C3=ADa?=) Date: Tue, 12 Apr 2016 11:43:45 +0000 (UTC) Subject: [FieldTrip] Averaging 4D spatio-temporospectral data (trials x channels x frequencies x time) In-Reply-To: References: Message-ID: <24058211.2420001.1460461425906.JavaMail.yahoo@mail.yahoo.com> Hi Ronny, try the ft_freqdescriptives. In this tutorial  (http://www.fieldtriptoolbox.org/tutorial/cluster_permutation_freq) it says you can do it. Best,Maite cfg = []; freqFIC_planar_cmb = ft_freqdescriptives(cfg, freqFIC_planar_cmb); El Martes 12 de abril de 2016 12:12, Ronny Ibrahim escribió: Dear Fellow fieldtrip users,I was wondering whether there is any function which let's me to average my  4D (trials x channels x frequencies x time) time-frequency structure along the trials dimension. I have tried to look into ft_freqgrandaverage function but it won't let me do it. I had set the keeptrials configuration to 'yes' with the aim of representing my data in the relative percentage change format by using the ft_freqbaseline to represent my data in the 'relchange' (percent change format) in which I would like to average. Many thank's in advance for your kind help. Kind Regards, Ronny   _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From zsuzsanna.nemecz at gmail.com Wed Apr 13 14:02:08 2016 From: zsuzsanna.nemecz at gmail.com (Zsuzsanna Nemecz) Date: Wed, 13 Apr 2016 14:02:08 +0200 Subject: [FieldTrip] FEM: Missing SIMBIO toolbox Message-ID: Hi, I think the Simbio toolbox is missing in fieldtrip-20160407 and -20160412. I tried generating a FEM volume conduction model and got the following error message in Matlab: Error using ft_hastoolbox (line 485) the SIMBIO toolbox is not installed, see https://www.mrt.uni-jena.de/simbio/index.php/Main_Page I checked in the filedtrip/external directory and the Simbio folder was indeed missing. I solved the problem by downloading an older version ( 2016 March 19th), but I thought it's worth posting anyway for your information. Best Zsuzsanna -------------- next part -------------- An HTML attachment was scrubbed... URL: From r.thomas at nin.knaw.nl Wed Apr 13 16:25:51 2016 From: r.thomas at nin.knaw.nl (Rajat Thomas) Date: Wed, 13 Apr 2016 14:25:51 +0000 Subject: [FieldTrip] Simbio works with ft_volumereslice but leadfield In-Reply-To: References: Message-ID: <1460557552027.85876@nin.knaw.nl> Dear all, Last week I asked for help with Simbio and after following the suggestion of volume reslicing magically the simbio based headmodel was created. But my leadfield calculations are taking way too long. It is a 128^3 grid and am running it on my desktop. (2.4 GHz, plenty of memory 32GB) Could anyone give me a rough ball park on how long it should take to create a leadfield? Thank you. Rajat Rajat Mani Thomas Social Brain Lab Netherlands Institute for Neuroscience Amsterdam ________________________________________ From: fieldtrip-bounces at science.ru.nl on behalf of fieldtrip-request at science.ru.nl Sent: 08 April 2016 12:00 To: fieldtrip at science.ru.nl Subject: fieldtrip Digest, Vol 65, Issue 7 Send fieldtrip mailing list submissions to fieldtrip at science.ru.nl To subscribe or unsubscribe via the World Wide Web, visit http://mailman.science.ru.nl/mailman/listinfo/fieldtrip or, via email, send a message with subject or body 'help' to fieldtrip-request at science.ru.nl You can reach the person managing the list at fieldtrip-owner at science.ru.nl When replying, please edit your Subject line so it is more specific than "Re: Contents of fieldtrip digest..." Today's Topics: 1. Re: FEM using Simbio (Johannes Vorwerk) 2. Re: FEM using Simbio (Cristiano Micheli) 3. Dipole fitting (Giovanni Pellegrino) 4. Birmingham-Illinois BRIDGE Fellowships (Ole Jensen) 5. Using FieldTrip to analyse LFP recordings in rat (laetitia.lalla at inserm.fr) ---------------------------------------------------------------------- Message: 1 Date: Thu, 7 Apr 2016 14:25:42 +0200 From: Johannes Vorwerk To: FieldTrip discussion list Subject: Re: [FieldTrip] FEM using Simbio Message-ID: <435735E3-7D87-4DD6-A2C1-E2BBFBBF4B44 at googlemail.com> Content-Type: text/plain; charset="utf-8" Hi, this question was already answered in this thread http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html If ft_volumereslice is not applied before the mesh generation, the afterwards applied transformation might flip the directions of the mesh, leading to the described error. Best, Johannes > Am 06.04.2016 um 16:03 schrieb Carsten Wolters : > > Dear Rajat, > > the element-node cards of SimBio-NeuroFEM need to follow certain orientations (see www.simbio.de ). > > If you do not want to struggle with meshing/ordering, use the SimBio-VGRID mesher > http://vgrid.simbio.de/ > that follows the required ordering of nodes. You might use this mesher to produce 1mm geometry-adapted FEM meshes > that show good overall performance, see > http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf > and > http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf > (latter was just accepted by NeuroImage). > > Best regards > Carsten > > Am 06.04.2016 um 15:10 schrieb Rajat Thomas: >> Dear all, >> >> Has anyone used the FEM approach to Headmodels using Simbio recently? >> >> If so, I get this error: >> "Elements have wrong orientation or are degenerated" >> >> Any ideas? >> >> cfg = []; >> cfg.method ='simbio'; >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows mesh.tissyelabel >> vol = ft_prepare_headmodel(cfg, mesh); >> >> And; >> ? >> disp(mesh) >> hex: [545883x8 double] >> pnt: [569722x3 double] >> labels: [545883x1 double] >> tissue: [545883x1 double] >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >> unit: 'mm' >> cfg: [1x1 struct] >> >> Any help would be highly appreciated. >> >> Rajat >> >> >> >> >> >> >> Rajat Mani Thomas >> Social Brain Lab >> Netherlands Institute for Neuroscience >> Amsterdam >> >> >> _______________________________________________ >> 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 -------------- next part -------------- An HTML attachment was scrubbed... URL: ------------------------------ Message: 2 Date: Thu, 7 Apr 2016 17:36:37 +0200 From: Cristiano Micheli To: FieldTrip discussion list Subject: Re: [FieldTrip] FEM using Simbio Message-ID: Content-Type: text/plain; charset="utf-8" Hi Rajat My guess is that the orientations of your hexahedrons are not correct. According to a low-level file's internal rules, elements' orientations have to abide strict rules (not sure what exactly the contraints are in this case though...). I had same problems when for example the triangular boundaries used to define the 3d hexahedral mesh were not topologically correct, to start with. Admittedly this approach requires a lot of technical expertise. Can I ask you what do you need a FEM model for? Regards Cris Micheli On Wed, Apr 6, 2016 at 3:10 PM, Rajat Thomas wrote: > Dear all, > > > Has anyone used the FEM approach to Headmodels using Simbio recently? > > > If so, I get this error: > "Elements have wrong orientation or are degenerated" > > Any ideas? > > cfg = []; > > cfg.method ='simbio'; > > cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows > mesh.tissyelabel > > vol = ft_prepare_headmodel(cfg, mesh); > > > And; > > ? > disp(mesh) > hex: [545883x8 double] > pnt: [569722x3 double] > labels: [545883x1 double] > tissue: [545883x1 double] > tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} > unit: 'mm' > cfg: [1x1 struct] > > > Any help would be highly appreciated. > > Rajat > > > > > > > Rajat Mani Thomas > Social Brain Lab > Netherlands Institute for Neuroscience > Amsterdam > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: ------------------------------ Message: 3 Date: Thu, 7 Apr 2016 15:02:05 -0400 From: Giovanni Pellegrino To: fieldtrip at science.ru.nl Subject: [FieldTrip] Dipole fitting Message-ID: Content-Type: text/plain; charset="utf-8" Dear Fieldtrippers, Do you know if the FieldTrip Dipole Fitting has been compared to the CTF, Elekta, BESA or Curry? Are you aware of any study on this topic? Thanks in advance for your help Giovanni -- Giovanni Pellegrino, MD Multimodal Functional Imaging Laboratory Montreal Neurological Institute, McGill University Address: 332 Duff Medical Building, 3775 rue University, Montreal, QC, H3A 2B4, Canada Phone: (514) 398?1678 Fax: (514) 398?7461 Email: giovannipellegrino at gmail.com, giovanni.pellegrino2 at mcgill.ca Homepage: http://www.bic.mni.mcgill.ca/ResearchLabsMFIL/PeopleGiovanni -------------- next part -------------- An HTML attachment was scrubbed... URL: ------------------------------ Message: 4 Date: Fri, 8 Apr 2016 09:23:46 +0200 From: Ole Jensen To: fieldtrip at science.ru.nl Subject: [FieldTrip] Birmingham-Illinois BRIDGE Fellowships Message-ID: <57075C82.8030309 at donders.ru.nl> Content-Type: text/plain; charset=utf-8; format=flowed Dear all, I would like to point you to a set of Birmingham-Illinois BRIDGE Fellowships providing some exciting research and career prospects: http://www.birminghamillinoisbridge.org/index.php/fellows/ In particular the areas 'Cognition and Ageing' and 'Brain Trauma' could be relevant for candidates with EEG/MEG expertise. All the best, Ole -- Prof. dr. Ole Jensen http://www.neuosc.com ------------------------------ Message: 5 Date: Fri, 08 Apr 2016 10:27:58 +0200 From: laetitia.lalla at inserm.fr To: fieldtrip at science.ru.nl Subject: [FieldTrip] Using FieldTrip to analyse LFP recordings in rat Message-ID: <628babdc107aebd4cc7588ea87ce5ea6 at inserm.fr> Content-Type: text/plain; charset="utf-8" Hello everyone, my name is Laetitia and I'm a Phd student in Marseille (France). I'm doing in-vivo recording in freely-moving rats : I implant them with 2 electrodes deep into 2 different regions of the brain. I'm studying the Local Field Potentials and I want to use FieldTrip to analyse the data. To simplify : - I have 2 rats. - Each rat did 20 sessions of the task (on 20 different days). - Each session consists of 20 trials of condition 1 and 20 trials of condition 2. I have 2 questions. 1) I have the feeling it would be meaningless to do "source reconstruction" because my electrodes are already deep inside my "source" and the LFP I am recording is very local. (My electrodes have 32 channels separated by 20-200 ?m. The LFP is very very similar across all the channels, so I averaged over the 32 channels to have one signal for each region.) However, I see that 2 different functions exist for the statistics : FT_FREQSTATISTICS AND FT_SOURCESTATISTICS. So far, I've been using ft_freqstatistics but I encounter some issues (for exemple, doing monte-carlo permutation test to assess the imaginary coherence). I thought of computing it manually, but I'm thinking that maybe more stuff are implemented in ft_sourcestatisctics ? ? Are these 2 functions fundamentally different or do they call the same sub-fonctions (and my problem has actually nothing to do with that) ? 2) I'm a bit confused with the vocabulary from EEG and MEG studies (I'm not used to it yet...). From what I understood, in human studies, you can do comparison for a single subject (across trials) or across subjects. But I have 3 levels of comparisons in my design : - WITHIN A SESSION, I WANT TO COMPARE ACROSS TRIALS (the 20 trials of condition 1 VS the 20 trials of condition 2). - WITHIN A RAT, I WANT TO COMPARE ACROSS SESSIONS (between the 2 conditions) - then - in the very end - ACROSS RATS. But I have only 2 rats so far, so I will deal with this later. I'm a bit confused when reading the tutorials and the mailing list, especially when it comes to the statistics... For example : this is from an email from 2013 by Eric Maris about "Nonparametric statistical testing of phase coherence" (http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006401.html) "To compare coherence between conditions across subjects (instead of trials), you need a different statfun: depsamplesT (for a within-subjects design; subjects have participated in all conditions) or indepsamplesT (for a between-subjects design; subjects have participated in only one condition)." ? If I want to compare across sessions (for a same rat), can I actually consider that my different sessions are "subjects"? And then compare coherence "across subjects" would be doing it "across sessions" ? And I would be in a "within-subject design" since my sessions involve the 2 conditions every time ? I realise that it may be very confusing... I hope you will understand my problem ! And if anyone already applied fieldtrip functions to do statistics on a different framework that the usual EEG/MEG, please let me know ! Thanks a lot, Laetitia Lalla PhD Student in Neuroscience INMED, Marseille, France -------------- next part -------------- An HTML attachment was scrubbed... URL: ------------------------------ _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl http://mailman.science.ru.nl/mailman/listinfo/fieldtrip End of fieldtrip Digest, Vol 65, Issue 7 **************************************** From icelandhouse at gmail.com Wed Apr 13 19:35:17 2016 From: icelandhouse at gmail.com (Maris Skujevskis) Date: Wed, 13 Apr 2016 19:35:17 +0200 Subject: [FieldTrip] Correlated sources: LCMV, MNE, dipole fitting Message-ID: Dear Fieldtrip community, I am trying to localize neural sources of the primary somatosensory response using the LCMV beamformer on an ERP dataset. In my experiment the subjects are stimulated bilaterally - both the left and the right index finger simultaneously receive an identical tactile half a second stimulus. The LCMV beamformer fails to detect two distinct early cortical sources (left and right S1), instead I get a single rather central source (along the lines of Van Veen et al., 1997, Fig.2(f) ). My question is: -is it expected that MNE fares better than LCMV when two sources are correlated? (i.e. would MNE be more likely to detect both right and left S1)? -or would dipole fitting be the preferred method for obtaining an accurate estimate of left/right S1 location? Any suggestions will be appreciated! Thanks! Maris On Wed, Apr 13, 2016 at 12:00 PM, wrote: > Send fieldtrip mailing list submissions to > fieldtrip at science.ru.nl > > To subscribe or unsubscribe via the World Wide Web, visit > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > or, via email, send a message with subject or body 'help' to > fieldtrip-request at science.ru.nl > > You can reach the person managing the list at > fieldtrip-owner at science.ru.nl > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of fieldtrip digest..." > > > Today's Topics: > > 1. Re: Averaging 4D spatio-temporospectral data (trials x > channels x frequencies x time) (Mait? Crespo Garc?a) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Tue, 12 Apr 2016 11:43:45 +0000 (UTC) > From: Mait? Crespo Garc?a > To: FieldTrip discussion list > Subject: Re: [FieldTrip] Averaging 4D spatio-temporospectral data > (trials x channels x frequencies x time) > Message-ID: > <24058211.2420001.1460461425906.JavaMail.yahoo at mail.yahoo.com> > Content-Type: text/plain; charset="utf-8" > > Hi Ronny, > try the ft_freqdescriptives. In this tutorial? ( > http://www.fieldtriptoolbox.org/tutorial/cluster_permutation_freq) it > says you can do it. > Best,Maite > > cfg = []; > freqFIC_planar_cmb = ft_freqdescriptives(cfg, freqFIC_planar_cmb); > > > > El Martes 12 de abril de 2016 12:12, Ronny Ibrahim < > ronny.ibrahim at mq.edu.au> escribi?: > > > Dear Fellow > fieldtrip users,I was wondering whether there is any function which let's > me to?average my ?4D (trials?x channels x frequencies x time) > time-frequency?structure along the trials dimension. I have tried to look > into ft_freqgrandaverage function but it won't let me do it. I had set?the > keeptrials configuration to 'yes' with the aim of representing my data in > the relative percentage change format by using the?ft_freqbaseline to > represent my data in the 'relchange' (percent change format) in?which I > would like to average. > Many thank's in advance for your kind help. > Kind Regards, > Ronny?? > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: < > http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160412/8f7f5099/attachment-0001.html > > > > ------------------------------ > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > End of fieldtrip Digest, Vol 65, Issue 11 > ***************************************** > -------------- next part -------------- An HTML attachment was scrubbed... URL: From gina.joue at univr.it Wed Apr 13 20:13:44 2016 From: gina.joue at univr.it (gj) Date: Wed, 13 Apr 2016 20:13:44 +0200 Subject: [FieldTrip] source reconstruction + noise bias in center of head Message-ID: <570E8C58.6080709@univr.it> Hi FieldTrip community, I tried doing source analysis of EEG data using method "eloreta." For some participants, the sources found were where we expected, but for some participants, the strongest power is in the center of the brain (and some on the skull...). What can I do in this case/what should I doublecheck? We don't have structural MRIs for each participant but coregistered the electrodes to a template brain. I actually tried using DICS to do the source analysis in order to estimate the noise, but 1. there is high power in almost the entire brain 2. the noise estimated is all 0's or NAs. Thanks in advance for any help! Gina From julian.keil at gmail.com Thu Apr 14 09:48:05 2016 From: julian.keil at gmail.com (Julian Keil) Date: Thu, 14 Apr 2016 09:48:05 +0200 Subject: [FieldTrip] Simbio works with ft_volumereslice but leadfield In-Reply-To: <1460557552027.85876@nin.knaw.nl> References: <1460557552027.85876@nin.knaw.nl> Message-ID: Hi Rajat, what do you mean by "way too long"? Have you tried setting the resolution of the mesh in the call to ft_prepare_mesh prior to ft_prepare_headmodel? Setting it to cfg.resolution = 5 (which changes the mesh resolution from the default 1mm to 5mm) greatly sped up the mesh preparation and leadfield computation in my case. Please beware however that I use a rather old FT-Version as I don't have a current Matlab Version, so the functionality might have changed. Good Luck, Julian ******************** Dr. Julian Keil AG Multisensorische Integration Psychiatrische Universitätsklinik der Charité im St. Hedwig-Krankenhaus Große Hamburger Straße 5-11, Haus 2 10115 Berlin Telefon: +49-30-2311-1879 Fax: +49-30-2311-2209 http://psy-ccm.charite.de/forschung/bildgebung/ag_multisensorische_integration Am 13.04.2016 um 16:25 schrieb Rajat Thomas: > Dear all, > > Last week I asked for help with Simbio and after following the suggestion of volume reslicing magically the > simbio based headmodel was created. > > But my leadfield calculations are taking way too long. > It is a 128^3 grid and am running it on my desktop. (2.4 GHz, plenty of memory 32GB) > > Could anyone give me a rough ball park on how long it should take to create a leadfield? > > Thank you. > Rajat > > > > Rajat Mani Thomas > Social Brain Lab > Netherlands Institute for Neuroscience > Amsterdam > > ________________________________________ > From: fieldtrip-bounces at science.ru.nl on behalf of fieldtrip-request at science.ru.nl > Sent: 08 April 2016 12:00 > To: fieldtrip at science.ru.nl > Subject: fieldtrip Digest, Vol 65, Issue 7 > > Send fieldtrip mailing list submissions to > fieldtrip at science.ru.nl > > To subscribe or unsubscribe via the World Wide Web, visit > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > or, via email, send a message with subject or body 'help' to > fieldtrip-request at science.ru.nl > > You can reach the person managing the list at > fieldtrip-owner at science.ru.nl > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of fieldtrip digest..." > > > Today's Topics: > > 1. Re: FEM using Simbio (Johannes Vorwerk) > 2. Re: FEM using Simbio (Cristiano Micheli) > 3. Dipole fitting (Giovanni Pellegrino) > 4. Birmingham-Illinois BRIDGE Fellowships (Ole Jensen) > 5. Using FieldTrip to analyse LFP recordings in rat > (laetitia.lalla at inserm.fr) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Thu, 7 Apr 2016 14:25:42 +0200 > From: Johannes Vorwerk > To: FieldTrip discussion list > Subject: Re: [FieldTrip] FEM using Simbio > Message-ID: <435735E3-7D87-4DD6-A2C1-E2BBFBBF4B44 at googlemail.com> > Content-Type: text/plain; charset="utf-8" > > Hi, > > this question was already answered in this thread > > http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html > > If ft_volumereslice is not applied before the mesh generation, the afterwards applied transformation might flip the directions of the mesh, leading to the described error. > > Best, > Johannes > >> Am 06.04.2016 um 16:03 schrieb Carsten Wolters : >> >> Dear Rajat, >> >> the element-node cards of SimBio-NeuroFEM need to follow certain orientations (see www.simbio.de ). >> >> If you do not want to struggle with meshing/ordering, use the SimBio-VGRID mesher >> http://vgrid.simbio.de/ >> that follows the required ordering of nodes. You might use this mesher to produce 1mm geometry-adapted FEM meshes >> that show good overall performance, see >> http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf >> and >> http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf >> (latter was just accepted by NeuroImage). >> >> Best regards >> Carsten >> >> Am 06.04.2016 um 15:10 schrieb Rajat Thomas: >>> Dear all, >>> >>> Has anyone used the FEM approach to Headmodels using Simbio recently? >>> >>> If so, I get this error: >>> "Elements have wrong orientation or are degenerated" >>> >>> Any ideas? >>> >>> cfg = []; >>> cfg.method ='simbio'; >>> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows mesh.tissyelabel >>> vol = ft_prepare_headmodel(cfg, mesh); >>> >>> And; >>> ? >>> disp(mesh) >>> hex: [545883x8 double] >>> pnt: [569722x3 double] >>> labels: [545883x1 double] >>> tissue: [545883x1 double] >>> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >>> unit: 'mm' >>> cfg: [1x1 struct] >>> >>> Any help would be highly appreciated. >>> >>> Rajat >>> >>> >>> >>> >>> >>> >>> Rajat Mani Thomas >>> Social Brain Lab >>> Netherlands Institute for Neuroscience >>> Amsterdam >>> >>> >>> _______________________________________________ >>> 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 > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > Message: 2 > Date: Thu, 7 Apr 2016 17:36:37 +0200 > From: Cristiano Micheli > To: FieldTrip discussion list > Subject: Re: [FieldTrip] FEM using Simbio > Message-ID: > > Content-Type: text/plain; charset="utf-8" > > Hi Rajat > > My guess is that the orientations of your hexahedrons are not correct. > According to a low-level file's internal rules, elements' orientations have > to abide strict rules (not sure what exactly the contraints are in this > case though...). > I had same problems when for example the triangular boundaries used to > define the 3d hexahedral mesh were not topologically correct, to start with. > Admittedly this approach requires a lot of technical expertise. > Can I ask you what do you need a FEM model for? > > Regards > Cris Micheli > > > > > On Wed, Apr 6, 2016 at 3:10 PM, Rajat Thomas wrote: > >> Dear all, >> >> >> Has anyone used the FEM approach to Headmodels using Simbio recently? >> >> >> If so, I get this error: >> "Elements have wrong orientation or are degenerated" >> >> Any ideas? >> >> cfg = []; >> >> cfg.method ='simbio'; >> >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows >> mesh.tissyelabel >> >> vol = ft_prepare_headmodel(cfg, mesh); >> >> >> And; >> >> ? >> disp(mesh) >> hex: [545883x8 double] >> pnt: [569722x3 double] >> labels: [545883x1 double] >> tissue: [545883x1 double] >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >> unit: 'mm' >> cfg: [1x1 struct] >> >> >> Any help would be highly appreciated. >> >> Rajat >> >> >> >> >> >> >> Rajat Mani Thomas >> Social Brain Lab >> Netherlands Institute for Neuroscience >> Amsterdam >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > Message: 3 > Date: Thu, 7 Apr 2016 15:02:05 -0400 > From: Giovanni Pellegrino > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Dipole fitting > Message-ID: > > Content-Type: text/plain; charset="utf-8" > > Dear Fieldtrippers, > > Do you know if the FieldTrip Dipole Fitting has been compared to the CTF, > Elekta, BESA or Curry? Are you aware of any study on this topic? > > Thanks in advance for your help > > Giovanni > > -- > Giovanni Pellegrino, MD > Multimodal Functional Imaging Laboratory > Montreal Neurological Institute, McGill University > Address: 332 Duff Medical Building, 3775 rue University, Montreal, QC, H3A > 2B4, Canada > Phone: (514) 398?1678 > Fax: (514) 398?7461 > Email: giovannipellegrino at gmail.com, giovanni.pellegrino2 at mcgill.ca > Homepage: http://www.bic.mni.mcgill.ca/ResearchLabsMFIL/PeopleGiovanni > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > Message: 4 > Date: Fri, 8 Apr 2016 09:23:46 +0200 > From: Ole Jensen > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Birmingham-Illinois BRIDGE Fellowships > Message-ID: <57075C82.8030309 at donders.ru.nl> > Content-Type: text/plain; charset=utf-8; format=flowed > > Dear all, > > I would like to point you to a set of Birmingham-Illinois BRIDGE > Fellowships providing some exciting research and career prospects: > http://www.birminghamillinoisbridge.org/index.php/fellows/ > > In particular the areas 'Cognition and Ageing' and 'Brain Trauma' could > be relevant for candidates with EEG/MEG expertise. > > All the best, > > Ole > > -- > Prof. dr. Ole Jensen > http://www.neuosc.com > > > > ------------------------------ > > Message: 5 > Date: Fri, 08 Apr 2016 10:27:58 +0200 > From: laetitia.lalla at inserm.fr > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Using FieldTrip to analyse LFP recordings in rat > Message-ID: <628babdc107aebd4cc7588ea87ce5ea6 at inserm.fr> > Content-Type: text/plain; charset="utf-8" > > > > Hello everyone, > > my name is Laetitia and I'm a Phd student in Marseille (France). I'm > doing in-vivo recording in freely-moving rats : I implant them with 2 > electrodes deep into 2 different regions of the brain. I'm studying the > Local Field Potentials and I want to use FieldTrip to analyse the data. > > To simplify : > > - I have 2 rats. > > - Each rat did 20 sessions of the task (on 20 different days). > > - Each session consists of 20 trials of condition 1 and 20 trials of > condition 2. > > I have 2 questions. > > 1) I have the feeling it would be meaningless to do "source > reconstruction" because my electrodes are already deep inside my > "source" and the LFP I am recording is very local. (My electrodes have > 32 channels separated by 20-200 ?m. The LFP is very very similar across > all the channels, so I averaged over the 32 channels to have one signal > for each region.) > > However, I see that 2 different functions exist for the statistics : > FT_FREQSTATISTICS AND FT_SOURCESTATISTICS. So far, I've been using > ft_freqstatistics but I encounter some issues (for exemple, doing > monte-carlo permutation test to assess the imaginary coherence). I > thought of computing it manually, but I'm thinking that maybe more stuff > are implemented in ft_sourcestatisctics ? > > ? Are these 2 functions fundamentally different or do they call the same > sub-fonctions (and my problem has actually nothing to do with that) ? > > 2) I'm a bit confused with the vocabulary from EEG and MEG studies (I'm > not used to it yet...). From what I understood, in human studies, you > can do comparison for a single subject (across trials) or across > subjects. But I have 3 levels of comparisons in my design : > > - WITHIN A SESSION, I WANT TO COMPARE ACROSS TRIALS (the 20 trials of > condition 1 VS the 20 trials of condition 2). > > - WITHIN A RAT, I WANT TO COMPARE ACROSS SESSIONS (between the 2 > conditions) > > - then - in the very end - ACROSS RATS. But I have only 2 rats so far, > so I will deal with this later. > > I'm a bit confused when reading the tutorials and the mailing list, > especially when it comes to the statistics... For example : this is from > an email from 2013 by Eric Maris about "Nonparametric statistical > testing of phase coherence" > (http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006401.html) > "To compare coherence between conditions across subjects (instead of > trials), you need a different statfun: depsamplesT (for a > within-subjects design; subjects have participated in all conditions) or > indepsamplesT (for a between-subjects design; subjects have participated > in only one condition)." > > ? If I want to compare across sessions (for a same rat), can I actually > consider that my different sessions are "subjects"? And then compare > coherence "across subjects" would be doing it "across sessions" ? And I > would be in a "within-subject design" since my sessions involve the 2 > conditions every time ? > > I realise that it may be very confusing... I hope you will understand my > problem ! > > And if anyone already applied fieldtrip functions to do statistics on a > different framework that the usual EEG/MEG, please let me know ! > > Thanks a lot, > > Laetitia Lalla > > PhD Student in Neuroscience > > INMED, Marseille, France > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > End of fieldtrip Digest, Vol 65, Issue 7 > **************************************** > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 495 bytes Desc: Message signed with OpenPGP using GPGMail URL: From deb.desideri at gmail.com Thu Apr 14 10:21:08 2016 From: deb.desideri at gmail.com (Debora Desideri) Date: Thu, 14 Apr 2016 10:21:08 +0200 Subject: [FieldTrip] Simbio works with ft_volumereslice but leadfield In-Reply-To: <1460557552027.85876@nin.knaw.nl> References: <1460557552027.85876@nin.knaw.nl> Message-ID: Dear Rajat, I am also using Simbio and I usually run the leadfield calculation overnight since it takes approximatelly 12-15 hours for 64 EEG channels with a grid of 6 mm resolution ( 2.60 GHz, 32 GB RAM). I don't know whether there is a way to speed the process up. Maybe we just need to be patient, or work on a very powerful machine. Best, Debora On Wed, Apr 13, 2016 at 4:25 PM, Rajat Thomas wrote: > Dear all, > > Last week I asked for help with Simbio and after following the suggestion > of volume reslicing magically the > simbio based headmodel was created. > > But my leadfield calculations are taking way too long. > It is a 128^3 grid and am running it on my desktop. (2.4 GHz, plenty of > memory 32GB) > > Could anyone give me a rough ball park on how long it should take to > create a leadfield? > > Thank you. > Rajat > > > > Rajat Mani Thomas > Social Brain Lab > Netherlands Institute for Neuroscience > Amsterdam > > ________________________________________ > From: fieldtrip-bounces at science.ru.nl > on behalf of fieldtrip-request at science.ru.nl < > fieldtrip-request at science.ru.nl> > Sent: 08 April 2016 12:00 > To: fieldtrip at science.ru.nl > Subject: fieldtrip Digest, Vol 65, Issue 7 > > Send fieldtrip mailing list submissions to > fieldtrip at science.ru.nl > > To subscribe or unsubscribe via the World Wide Web, visit > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > or, via email, send a message with subject or body 'help' to > fieldtrip-request at science.ru.nl > > You can reach the person managing the list at > fieldtrip-owner at science.ru.nl > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of fieldtrip digest..." > > > Today's Topics: > > 1. Re: FEM using Simbio (Johannes Vorwerk) > 2. Re: FEM using Simbio (Cristiano Micheli) > 3. Dipole fitting (Giovanni Pellegrino) > 4. Birmingham-Illinois BRIDGE Fellowships (Ole Jensen) > 5. Using FieldTrip to analyse LFP recordings in rat > (laetitia.lalla at inserm.fr) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Thu, 7 Apr 2016 14:25:42 +0200 > From: Johannes Vorwerk > To: FieldTrip discussion list > Subject: Re: [FieldTrip] FEM using Simbio > Message-ID: <435735E3-7D87-4DD6-A2C1-E2BBFBBF4B44 at googlemail.com> > Content-Type: text/plain; charset="utf-8" > > Hi, > > this question was already answered in this thread > > http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html < > http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html> > > If ft_volumereslice is not applied before the mesh generation, the > afterwards applied transformation might flip the directions of the mesh, > leading to the described error. > > Best, > Johannes > > > Am 06.04.2016 um 16:03 schrieb Carsten Wolters < > carsten.wolters at uni-muenster.de>: > > > > Dear Rajat, > > > > the element-node cards of SimBio-NeuroFEM need to follow certain > orientations (see www.simbio.de ). > > > > If you do not want to struggle with meshing/ordering, use the > SimBio-VGRID mesher > > http://vgrid.simbio.de/ > > that follows the required ordering of nodes. You might use this mesher > to produce 1mm geometry-adapted FEM meshes > > that show good overall performance, see > > > http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf > < > http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf > > > > and > > > http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf > < > http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf > > > > (latter was just accepted by NeuroImage). > > > > Best regards > > Carsten > > > > Am 06.04.2016 um 15:10 schrieb Rajat Thomas: > >> Dear all, > >> > >> Has anyone used the FEM approach to Headmodels using Simbio recently? > >> > >> If so, I get this error: > >> "Elements have wrong orientation or are degenerated" > >> > >> Any ideas? > >> > >> cfg = []; > >> cfg.method ='simbio'; > >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows > mesh.tissyelabel > >> vol = ft_prepare_headmodel(cfg, mesh); > >> > >> And; > >> ? > >> disp(mesh) > >> hex: [545883x8 double] > >> pnt: [569722x3 double] > >> labels: [545883x1 double] > >> tissue: [545883x1 double] > >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} > >> unit: 'mm' > >> cfg: [1x1 struct] > >> > >> Any help would be highly appreciated. > >> > >> Rajat > >> > >> > >> > >> > >> > >> > >> Rajat Mani Thomas > >> Social Brain Lab > >> Netherlands Institute for Neuroscience > >> Amsterdam > >> > >> > >> _______________________________________________ > >> fieldtrip mailing list > >> fieldtrip at donders.ru.nl > >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip < > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip> > > _______________________________________________ > > fieldtrip mailing list > > fieldtrip at donders.ru.nl > > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip < > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip> > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: < > http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160407/2ea995ee/attachment-0001.html > > > > ------------------------------ > > Message: 2 > Date: Thu, 7 Apr 2016 17:36:37 +0200 > From: Cristiano Micheli > To: FieldTrip discussion list > Subject: Re: [FieldTrip] FEM using Simbio > Message-ID: > < > CADW7XCAQONsZ_ujPhkffskZ+j-mnHnAzunS68CdKU6MLSosUPA at mail.gmail.com> > Content-Type: text/plain; charset="utf-8" > > Hi Rajat > > My guess is that the orientations of your hexahedrons are not correct. > According to a low-level file's internal rules, elements' orientations have > to abide strict rules (not sure what exactly the contraints are in this > case though...). > I had same problems when for example the triangular boundaries used to > define the 3d hexahedral mesh were not topologically correct, to start > with. > Admittedly this approach requires a lot of technical expertise. > Can I ask you what do you need a FEM model for? > > Regards > Cris Micheli > > > > > On Wed, Apr 6, 2016 at 3:10 PM, Rajat Thomas wrote: > > > Dear all, > > > > > > Has anyone used the FEM approach to Headmodels using Simbio recently? > > > > > > If so, I get this error: > > "Elements have wrong orientation or are degenerated" > > > > Any ideas? > > > > cfg = []; > > > > cfg.method ='simbio'; > > > > cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows > > mesh.tissyelabel > > > > vol = ft_prepare_headmodel(cfg, mesh); > > > > > > And; > > > > ? > > disp(mesh) > > hex: [545883x8 double] > > pnt: [569722x3 double] > > labels: [545883x1 double] > > tissue: [545883x1 double] > > tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} > > unit: 'mm' > > cfg: [1x1 struct] > > > > > > Any help would be highly appreciated. > > > > Rajat > > > > > > > > > > > > > > Rajat Mani Thomas > > Social Brain Lab > > Netherlands Institute for Neuroscience > > Amsterdam > > > > _______________________________________________ > > fieldtrip mailing list > > fieldtrip at donders.ru.nl > > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: < > http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160407/4adfe55a/attachment-0001.html > > > > ------------------------------ > > Message: 3 > Date: Thu, 7 Apr 2016 15:02:05 -0400 > From: Giovanni Pellegrino > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Dipole fitting > Message-ID: > u8GDw at mail.gmail.com> > Content-Type: text/plain; charset="utf-8" > > Dear Fieldtrippers, > > Do you know if the FieldTrip Dipole Fitting has been compared to the CTF, > Elekta, BESA or Curry? Are you aware of any study on this topic? > > Thanks in advance for your help > > Giovanni > > -- > Giovanni Pellegrino, MD > Multimodal Functional Imaging Laboratory > Montreal Neurological Institute, McGill University > Address: 332 Duff Medical Building, 3775 rue University, Montreal, QC, H3A > 2B4, Canada > Phone: (514) 398?1678 > Fax: (514) 398?7461 > Email: giovannipellegrino at gmail.com, giovanni.pellegrino2 at mcgill.ca > Homepage: http://www.bic.mni.mcgill.ca/ResearchLabsMFIL/PeopleGiovanni > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: < > http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160407/d01144bd/attachment-0001.html > > > > ------------------------------ > > Message: 4 > Date: Fri, 8 Apr 2016 09:23:46 +0200 > From: Ole Jensen > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Birmingham-Illinois BRIDGE Fellowships > Message-ID: <57075C82.8030309 at donders.ru.nl> > Content-Type: text/plain; charset=utf-8; format=flowed > > Dear all, > > I would like to point you to a set of Birmingham-Illinois BRIDGE > Fellowships providing some exciting research and career prospects: > http://www.birminghamillinoisbridge.org/index.php/fellows/ > > In particular the areas 'Cognition and Ageing' and 'Brain Trauma' could > be relevant for candidates with EEG/MEG expertise. > > All the best, > > Ole > > -- > Prof. dr. Ole Jensen > http://www.neuosc.com > > > > ------------------------------ > > Message: 5 > Date: Fri, 08 Apr 2016 10:27:58 +0200 > From: laetitia.lalla at inserm.fr > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Using FieldTrip to analyse LFP recordings in rat > Message-ID: <628babdc107aebd4cc7588ea87ce5ea6 at inserm.fr> > Content-Type: text/plain; charset="utf-8" > > > > Hello everyone, > > my name is Laetitia and I'm a Phd student in Marseille (France). I'm > doing in-vivo recording in freely-moving rats : I implant them with 2 > electrodes deep into 2 different regions of the brain. I'm studying the > Local Field Potentials and I want to use FieldTrip to analyse the data. > > To simplify : > > - I have 2 rats. > > - Each rat did 20 sessions of the task (on 20 different days). > > - Each session consists of 20 trials of condition 1 and 20 trials of > condition 2. > > I have 2 questions. > > 1) I have the feeling it would be meaningless to do "source > reconstruction" because my electrodes are already deep inside my > "source" and the LFP I am recording is very local. (My electrodes have > 32 channels separated by 20-200 ?m. The LFP is very very similar across > all the channels, so I averaged over the 32 channels to have one signal > for each region.) > > However, I see that 2 different functions exist for the statistics : > FT_FREQSTATISTICS AND FT_SOURCESTATISTICS. So far, I've been using > ft_freqstatistics but I encounter some issues (for exemple, doing > monte-carlo permutation test to assess the imaginary coherence). I > thought of computing it manually, but I'm thinking that maybe more stuff > are implemented in ft_sourcestatisctics ? > > ? Are these 2 functions fundamentally different or do they call the same > sub-fonctions (and my problem has actually nothing to do with that) ? > > 2) I'm a bit confused with the vocabulary from EEG and MEG studies (I'm > not used to it yet...). From what I understood, in human studies, you > can do comparison for a single subject (across trials) or across > subjects. But I have 3 levels of comparisons in my design : > > - WITHIN A SESSION, I WANT TO COMPARE ACROSS TRIALS (the 20 trials of > condition 1 VS the 20 trials of condition 2). > > - WITHIN A RAT, I WANT TO COMPARE ACROSS SESSIONS (between the 2 > conditions) > > - then - in the very end - ACROSS RATS. But I have only 2 rats so far, > so I will deal with this later. > > I'm a bit confused when reading the tutorials and the mailing list, > especially when it comes to the statistics... For example : this is from > an email from 2013 by Eric Maris about "Nonparametric statistical > testing of phase coherence" > (http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006401.html) > "To compare coherence between conditions across subjects (instead of > trials), you need a different statfun: depsamplesT (for a > within-subjects design; subjects have participated in all conditions) or > indepsamplesT (for a between-subjects design; subjects have participated > in only one condition)." > > ? If I want to compare across sessions (for a same rat), can I actually > consider that my different sessions are "subjects"? And then compare > coherence "across subjects" would be doing it "across sessions" ? And I > would be in a "within-subject design" since my sessions involve the 2 > conditions every time ? > > I realise that it may be very confusing... I hope you will understand my > problem ! > > And if anyone already applied fieldtrip functions to do statistics on a > different framework that the usual EEG/MEG, please let me know ! > > Thanks a lot, > > Laetitia Lalla > > PhD Student in Neuroscience > > INMED, Marseille, France > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: < > http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160408/2aed96c1/attachment-0001.html > > > > ------------------------------ > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > End of fieldtrip Digest, Vol 65, Issue 7 > **************************************** > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -- Debora Desideri, PhD Student BNP Lab - Neurology Department University Hospital Tübingen Eberhard Karls University Tübingen Hoppe-Seyler Str. 3 D-72076 Tübingen Tel: +49 7071/29 80478 -------------- next part -------------- An HTML attachment was scrubbed... URL: From carsten.wolters at uni-muenster.de Thu Apr 14 11:26:48 2016 From: carsten.wolters at uni-muenster.de (Carsten Wolters) Date: Thu, 14 Apr 2016 11:26:48 +0200 Subject: [FieldTrip] Simbio works with ft_volumereslice but leadfield In-Reply-To: <1460557552027.85876@nin.knaw.nl> References: <1460557552027.85876@nin.knaw.nl> Message-ID: <570F6258.50305@uni-muenster.de> Dear Rajat, we will need a little bit more informations where you are stuck or where the calculations are way too long? In ft_prepare_headmodel the FEM stiffness matrix is computed, which should not take much time. In ft_prepare_sourcemodel, a so-called FE transfer matrix is computed. To do so, for each electrode (but reference) a FEM linear equation system needs to be solved. The time for it thus scales with your number of electrodes. A fully-populated matrix will be resulting that has "number of electrodes -1" many rows and "number of FE nodes" many columns. For a reasonable number of electrodes and with your big memory (32 GB), this should not cause any trouble, but ft_prepare_sourcemodel might be the computationally most expensive step (but has to be done only once for a given FE model and electrode setup, so just start it in the evening). Once the transfer matrix is computed, each FEM forward computation is extremenly fast and therefore also the setup of the leadfield matrix with ft_prepare_leadfield. This should be the case, because for each source, only a right-hand-side in the size "number of FE nodes", but with only about 30 nonzeros, has to be computed and multiplied with the transfer matrix, which takes all together only milliseconds. So a 128^3 grid should not cause any trouble, as long as the transfer matrix fits in the memory (which should also be the case with 32GB), so that the computer doesn't need to swap. Best regards Carsten Am 13.04.2016 um 16:25 schrieb Rajat Thomas: > Dear all, > > Last week I asked for help with Simbio and after following the suggestion of volume reslicing magically the > simbio based headmodel was created. > > But my leadfield calculations are taking way too long. > It is a 128^3 grid and am running it on my desktop. (2.4 GHz, plenty of memory 32GB) > > Could anyone give me a rough ball park on how long it should take to create a leadfield? > > Thank you. > Rajat > > > > Rajat Mani Thomas > Social Brain Lab > Netherlands Institute for Neuroscience > Amsterdam > > ________________________________________ > From: fieldtrip-bounces at science.ru.nl on behalf of fieldtrip-request at science.ru.nl > Sent: 08 April 2016 12:00 > To: fieldtrip at science.ru.nl > Subject: fieldtrip Digest, Vol 65, Issue 7 > > Send fieldtrip mailing list submissions to > fieldtrip at science.ru.nl > > To subscribe or unsubscribe via the World Wide Web, visit > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > or, via email, send a message with subject or body 'help' to > fieldtrip-request at science.ru.nl > > You can reach the person managing the list at > fieldtrip-owner at science.ru.nl > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of fieldtrip digest..." > > > Today's Topics: > > 1. Re: FEM using Simbio (Johannes Vorwerk) > 2. Re: FEM using Simbio (Cristiano Micheli) > 3. Dipole fitting (Giovanni Pellegrino) > 4. Birmingham-Illinois BRIDGE Fellowships (Ole Jensen) > 5. Using FieldTrip to analyse LFP recordings in rat > (laetitia.lalla at inserm.fr) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Thu, 7 Apr 2016 14:25:42 +0200 > From: Johannes Vorwerk > To: FieldTrip discussion list > Subject: Re: [FieldTrip] FEM using Simbio > Message-ID: <435735E3-7D87-4DD6-A2C1-E2BBFBBF4B44 at googlemail.com> > Content-Type: text/plain; charset="utf-8" > > Hi, > > this question was already answered in this thread > > http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html > > If ft_volumereslice is not applied before the mesh generation, the afterwards applied transformation might flip the directions of the mesh, leading to the described error. > > Best, > Johannes > >> Am 06.04.2016 um 16:03 schrieb Carsten Wolters : >> >> Dear Rajat, >> >> the element-node cards of SimBio-NeuroFEM need to follow certain orientations (see www.simbio.de ). >> >> If you do not want to struggle with meshing/ordering, use the SimBio-VGRID mesher >> http://vgrid.simbio.de/ >> that follows the required ordering of nodes. You might use this mesher to produce 1mm geometry-adapted FEM meshes >> that show good overall performance, see >> http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf >> and >> http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf >> (latter was just accepted by NeuroImage). >> >> Best regards >> Carsten >> >> Am 06.04.2016 um 15:10 schrieb Rajat Thomas: >>> Dear all, >>> >>> Has anyone used the FEM approach to Headmodels using Simbio recently? >>> >>> If so, I get this error: >>> "Elements have wrong orientation or are degenerated" >>> >>> Any ideas? >>> >>> cfg = []; >>> cfg.method ='simbio'; >>> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows mesh.tissyelabel >>> vol = ft_prepare_headmodel(cfg, mesh); >>> >>> And; >>> ? >>> disp(mesh) >>> hex: [545883x8 double] >>> pnt: [569722x3 double] >>> labels: [545883x1 double] >>> tissue: [545883x1 double] >>> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >>> unit: 'mm' >>> cfg: [1x1 struct] >>> >>> Any help would be highly appreciated. >>> >>> Rajat >>> >>> >>> >>> >>> >>> >>> Rajat Mani Thomas >>> Social Brain Lab >>> Netherlands Institute for Neuroscience >>> Amsterdam >>> >>> >>> _______________________________________________ >>> 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 > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > Message: 2 > Date: Thu, 7 Apr 2016 17:36:37 +0200 > From: Cristiano Micheli > To: FieldTrip discussion list > Subject: Re: [FieldTrip] FEM using Simbio > Message-ID: > > Content-Type: text/plain; charset="utf-8" > > Hi Rajat > > My guess is that the orientations of your hexahedrons are not correct. > According to a low-level file's internal rules, elements' orientations have > to abide strict rules (not sure what exactly the contraints are in this > case though...). > I had same problems when for example the triangular boundaries used to > define the 3d hexahedral mesh were not topologically correct, to start with. > Admittedly this approach requires a lot of technical expertise. > Can I ask you what do you need a FEM model for? > > Regards > Cris Micheli > > > > > On Wed, Apr 6, 2016 at 3:10 PM, Rajat Thomas wrote: > >> Dear all, >> >> >> Has anyone used the FEM approach to Headmodels using Simbio recently? >> >> >> If so, I get this error: >> "Elements have wrong orientation or are degenerated" >> >> Any ideas? >> >> cfg = []; >> >> cfg.method ='simbio'; >> >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows >> mesh.tissyelabel >> >> vol = ft_prepare_headmodel(cfg, mesh); >> >> >> And; >> >> ? >> disp(mesh) >> hex: [545883x8 double] >> pnt: [569722x3 double] >> labels: [545883x1 double] >> tissue: [545883x1 double] >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >> unit: 'mm' >> cfg: [1x1 struct] >> >> >> Any help would be highly appreciated. >> >> Rajat >> >> >> >> >> >> >> Rajat Mani Thomas >> Social Brain Lab >> Netherlands Institute for Neuroscience >> Amsterdam >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > Message: 3 > Date: Thu, 7 Apr 2016 15:02:05 -0400 > From: Giovanni Pellegrino > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Dipole fitting > Message-ID: > > Content-Type: text/plain; charset="utf-8" > > Dear Fieldtrippers, > > Do you know if the FieldTrip Dipole Fitting has been compared to the CTF, > Elekta, BESA or Curry? Are you aware of any study on this topic? > > Thanks in advance for your help > > Giovanni > > -- > Giovanni Pellegrino, MD > Multimodal Functional Imaging Laboratory > Montreal Neurological Institute, McGill University > Address: 332 Duff Medical Building, 3775 rue University, Montreal, QC, H3A > 2B4, Canada > Phone: (514) 398?1678 > Fax: (514) 398?7461 > Email: giovannipellegrino at gmail.com, giovanni.pellegrino2 at mcgill.ca > Homepage: http://www.bic.mni.mcgill.ca/ResearchLabsMFIL/PeopleGiovanni > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > Message: 4 > Date: Fri, 8 Apr 2016 09:23:46 +0200 > From: Ole Jensen > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Birmingham-Illinois BRIDGE Fellowships > Message-ID: <57075C82.8030309 at donders.ru.nl> > Content-Type: text/plain; charset=utf-8; format=flowed > > Dear all, > > I would like to point you to a set of Birmingham-Illinois BRIDGE > Fellowships providing some exciting research and career prospects: > http://www.birminghamillinoisbridge.org/index.php/fellows/ > > In particular the areas 'Cognition and Ageing' and 'Brain Trauma' could > be relevant for candidates with EEG/MEG expertise. > > All the best, > > Ole > > -- > Prof. dr. Ole Jensen > http://www.neuosc.com > > > > ------------------------------ > > Message: 5 > Date: Fri, 08 Apr 2016 10:27:58 +0200 > From: laetitia.lalla at inserm.fr > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Using FieldTrip to analyse LFP recordings in rat > Message-ID: <628babdc107aebd4cc7588ea87ce5ea6 at inserm.fr> > Content-Type: text/plain; charset="utf-8" > > > > Hello everyone, > > my name is Laetitia and I'm a Phd student in Marseille (France). I'm > doing in-vivo recording in freely-moving rats : I implant them with 2 > electrodes deep into 2 different regions of the brain. I'm studying the > Local Field Potentials and I want to use FieldTrip to analyse the data. > > To simplify : > > - I have 2 rats. > > - Each rat did 20 sessions of the task (on 20 different days). > > - Each session consists of 20 trials of condition 1 and 20 trials of > condition 2. > > I have 2 questions. > > 1) I have the feeling it would be meaningless to do "source > reconstruction" because my electrodes are already deep inside my > "source" and the LFP I am recording is very local. (My electrodes have > 32 channels separated by 20-200 ?m. The LFP is very very similar across > all the channels, so I averaged over the 32 channels to have one signal > for each region.) > > However, I see that 2 different functions exist for the statistics : > FT_FREQSTATISTICS AND FT_SOURCESTATISTICS. So far, I've been using > ft_freqstatistics but I encounter some issues (for exemple, doingIch werde nachfragen. Es wird doch immer in ft_prepare_sourcemodel > die Transfermatrix gerechnet, sodass > > in ft_prepare_leadfield nur noch Multiplikationen dieser > Transfermatrix mit den vielen rechten Seiten > > gerechnet wird, was ja schnell gehen sollte. Ich frage, wo es > hakt. > > > monte-carlo permutation test to assess the imaginary coherence). I > thought of computing it manually, but I'm thinking that maybe more stuff > are implemented in ft_sourcestatisctics ? > > ? Are these 2 functions fundamentally different or do they call the same > sub-fonctions (and my problem has actually nothing to do with that) ? > > 2) I'm a bit confused with the vocabulary from EEG and MEG studies (I'm > not used to it yet...). From what I understood, in human studies, you > can do comparison for a single subject (across trials) or across > subjects. But I have 3 levels of comparisons in my design : > > - WITHIN A SESSION, I WANT TO COMPARE ACROSS TRIALS (the 20 trials of > condition 1 VS the 20 trials of condition 2). > > - WITHIN A RAT, I WANT TO COMPARE ACROSS SESSIONS (between the 2 > conditions) > > - then - in the very end - ACROSS RATS. But I have only 2 rats so far, > so I will deal with this later. > > I'm a bit confused when reading the tutorials and the mailing list, > especially when it comes to the statistics... For example : this is from > an email from 2013 by Eric Maris about "Nonparametric statistical > testing of phase coherence" > (http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006401.html) > "To compare coherence between conditions across subjects (instead of > trials), you need a different statfun: depsamplesT (for a > within-subjects design; subjects have participated in all conditions) or > indepsamplesT (for a between-subjects design; subjects have participated > in only one condition)." > > ? If I want to compare across sessions (for a same rat), can I actually > consider that my different sessions are "subjects"? And then compare > coherence "across subjects" would be doing it "across sessions" ? And I > would be in a "within-subject design" since my sessions involve the 2 > conditions every time ? > > I realise that it may be very confusing... I hope you will understand my > problem ! > > And if anyone already applied fieldtrip functions to do statistics on a > different framework that the usual EEG/MEG, please let me know ! > > Thanks a lot, > > Laetitia Lalla > > PhD Student in Neuroscience > > INMED, Marseille, France > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > End of fieldtrip Digest, Vol 65, Issue 7 > **************************************** > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- A non-text attachment was scrubbed... Name: carsten_wolters.vcf Type: text/x-vcard Size: 402 bytes Desc: not available URL: From erin.white at sickkids.ca Thu Apr 14 20:26:37 2016 From: erin.white at sickkids.ca (Erin White) Date: Thu, 14 Apr 2016 18:26:37 +0000 Subject: [FieldTrip] Grand average with deleted channels In-Reply-To: References: Message-ID: <0D4EE8880DEE3047BEC905C0EC463F8C3E52629B@SKMBXX03.sickkids.ca> Dear Eliana, One option for you would be, rather than deleting the bad channels, to interpolate what their activity would be from the average of surrounding channels. You can do this with FT_CHANNELREPAIR and it's pretty straightforward http://www.fieldtriptoolbox.org/reference/channelrepair Good luck with it! Erin ---------------------------------------------------- Erin White, PhD Post-Doctoral Research Fellow Neurosciences and Mental Health The Hospital for Sick Children 555 University Avenue Toronto, Ontario Canada Telephone: (647)834-7813 ________________________________ From: fieldtrip-bounces at science.ru.nl [fieldtrip-bounces at science.ru.nl] on behalf of Eliana Nicolaisen [elinicolaisen at gmail.com] Sent: April 11, 2016 10:21 AM To: fieldtrip at science.ru.nl Subject: [FieldTrip] Grand average with deleted channels Dear all, I'm trying to make an ERP grand average using version 20150301. In some subjects I deleted bad channels. Those channels were replaced for NaNs. When I make the grand average using ft_timelockaverage, the grand average is composed only for the common channels across subjects. In other words, in channels deleated at least in one subject the grand average is NaN. This is because ft_timelockanalysis in this version calculates the average making a sum and dividng into degrees of freedom: grandavg.avg = reshape(sum(avgmat, 1), datsiz)./ResultDOF; (in line 187 of revision '$Id: ft_timelockgrandaverage.m 10194 2015-02-11 09:08:16Z roboos $') However, I tried version 20121014 that my colleague uses. In this version ft_timelockedanalysis makes a mean: ResultGrandavg = mean(avgmat, 1); (in line 183 of revision '$Id: ft_timelockgrandaverage.m 6750 2012-10-13 15:07:32Z roboos $') In the version 20121014 is easy to make a correction that calculates a grand average taking into account NaNs (just changing mean for nanmean). However, in version 20150301 making a similar correction seems more complicated. Question 1: Why version 20150301 calculates average using sum and division instead of using nanmean? Question 2: Do someone have a suggestion about how to change version 20150301? Any comment would be greatly appreciated. Kind regards, Eliana Nicolaisen ________________________________ This e-mail may contain confidential, personal and/or health information(information which may be subject to legal restrictions on use, retention and/or disclosure) for the sole use of the intended recipient. Any review or distribution by anyone other than the person for whom it was originally intended is strictly prohibited. If you have received this e-mail in error, please contact the sender and delete all copies. -------------- next part -------------- An HTML attachment was scrubbed... URL: From j.vorwerk at uni-muenster.de Thu Apr 14 23:28:46 2016 From: j.vorwerk at uni-muenster.de (Johannes Vorwerk) Date: Thu, 14 Apr 2016 15:28:46 -0600 Subject: [FieldTrip] Simbio works with ft_volumereslice but leadfield In-Reply-To: References: <1460557552027.85876@nin.knaw.nl> Message-ID: <82D66CB4-DE42-409C-B350-E5DA0984A07E@googlemail.com> Hi Debora, could you indicate which part of the computation is the most time consuming, i.e., calculation of the transfer matrix or the subsequent computation of the dipole solutions? Principally, it should be possible to parallelize many of these steps, however, this wasn’t added to the checked-in code yet for reasons of stability/compatibility. Best, Johannes > Am 14.04.2016 um 02:21 schrieb Debora Desideri : > > Dear Rajat, > I am also using Simbio and I usually run the leadfield calculation overnight since it takes approximatelly 12-15 hours for 64 EEG channels with a grid of 6 mm resolution ( 2.60 GHz, 32 GB RAM). > I don't know whether there is a way to speed the process up. Maybe we just need to be patient, or work on a very powerful machine. > > Best, > Debora > > > On Wed, Apr 13, 2016 at 4:25 PM, Rajat Thomas > wrote: > Dear all, > > Last week I asked for help with Simbio and after following the suggestion of volume reslicing magically the > simbio based headmodel was created. > > But my leadfield calculations are taking way too long. > It is a 128^3 grid and am running it on my desktop. (2.4 GHz, plenty of memory 32GB) > > Could anyone give me a rough ball park on how long it should take to create a leadfield? > > Thank you. > Rajat > > > > Rajat Mani Thomas > Social Brain Lab > Netherlands Institute for Neuroscience > Amsterdam > > ________________________________________ > From: fieldtrip-bounces at science.ru.nl > on behalf of fieldtrip-request at science.ru.nl > > Sent: 08 April 2016 12:00 > To: fieldtrip at science.ru.nl > Subject: fieldtrip Digest, Vol 65, Issue 7 > > Send fieldtrip mailing list submissions to > fieldtrip at science.ru.nl > > To subscribe or unsubscribe via the World Wide Web, visit > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > or, via email, send a message with subject or body 'help' to > fieldtrip-request at science.ru.nl > > You can reach the person managing the list at > fieldtrip-owner at science.ru.nl > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of fieldtrip digest..." > > > Today's Topics: > > 1. Re: FEM using Simbio (Johannes Vorwerk) > 2. Re: FEM using Simbio (Cristiano Micheli) > 3. Dipole fitting (Giovanni Pellegrino) > 4. Birmingham-Illinois BRIDGE Fellowships (Ole Jensen) > 5. Using FieldTrip to analyse LFP recordings in rat > (laetitia.lalla at inserm.fr ) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Thu, 7 Apr 2016 14:25:42 +0200 > From: Johannes Vorwerk > > To: FieldTrip discussion list > > Subject: Re: [FieldTrip] FEM using Simbio > Message-ID: <435735E3-7D87-4DD6-A2C1-E2BBFBBF4B44 at googlemail.com > > Content-Type: text/plain; charset="utf-8" > > Hi, > > this question was already answered in this thread > > http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html > > > If ft_volumereslice is not applied before the mesh generation, the afterwards applied transformation might flip the directions of the mesh, leading to the described error. > > Best, > Johannes > > > Am 06.04.2016 um 16:03 schrieb Carsten Wolters >: > > > > Dear Rajat, > > > > the element-node cards of SimBio-NeuroFEM need to follow certain orientations (see www.simbio.de >). > > > > If you do not want to struggle with meshing/ordering, use the SimBio-VGRID mesher > > http://vgrid.simbio.de/ > > > that follows the required ordering of nodes. You might use this mesher to produce 1mm geometry-adapted FEM meshes > > that show good overall performance, see > > http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf > > > and > > http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf > > > (latter was just accepted by NeuroImage). > > > > Best regards > > Carsten > > > > Am 06.04.2016 um 15:10 schrieb Rajat Thomas: > >> Dear all, > >> > >> Has anyone used the FEM approach to Headmodels using Simbio recently? > >> > >> If so, I get this error: > >> "Elements have wrong orientation or are degenerated" > >> > >> Any ideas? > >> > >> cfg = []; > >> cfg.method ='simbio'; > >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows mesh.tissyelabel > >> vol = ft_prepare_headmodel(cfg, mesh); > >> > >> And; > >> ? > >> disp(mesh) > >> hex: [545883x8 double] > >> pnt: [569722x3 double] > >> labels: [545883x1 double] > >> tissue: [545883x1 double] > >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} > >> unit: 'mm' > >> cfg: [1x1 struct] > >> > >> Any help would be highly appreciated. > >> > >> Rajat > >> > >> > >> > >> > >> > >> > >> Rajat Mani Thomas > >> Social Brain Lab > >> Netherlands Institute for Neuroscience > >> Amsterdam > >> > >> > >> _______________________________________________ > >> 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 > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > > ------------------------------ > > Message: 2 > Date: Thu, 7 Apr 2016 17:36:37 +0200 > From: Cristiano Micheli > > To: FieldTrip discussion list > > Subject: Re: [FieldTrip] FEM using Simbio > Message-ID: > > > Content-Type: text/plain; charset="utf-8" > > Hi Rajat > > My guess is that the orientations of your hexahedrons are not correct. > According to a low-level file's internal rules, elements' orientations have > to abide strict rules (not sure what exactly the contraints are in this > case though...). > I had same problems when for example the triangular boundaries used to > define the 3d hexahedral mesh were not topologically correct, to start with. > Admittedly this approach requires a lot of technical expertise. > Can I ask you what do you need a FEM model for? > > Regards > Cris Micheli > > > > > On Wed, Apr 6, 2016 at 3:10 PM, Rajat Thomas > wrote: > > > Dear all, > > > > > > Has anyone used the FEM approach to Headmodels using Simbio recently? > > > > > > If so, I get this error: > > "Elements have wrong orientation or are degenerated" > > > > Any ideas? > > > > cfg = []; > > > > cfg.method ='simbio'; > > > > cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows > > mesh.tissyelabel > > > > vol = ft_prepare_headmodel(cfg, mesh); > > > > > > And; > > > > ? > > disp(mesh) > > hex: [545883x8 double] > > pnt: [569722x3 double] > > labels: [545883x1 double] > > tissue: [545883x1 double] > > tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} > > unit: 'mm' > > cfg: [1x1 struct] > > > > > > Any help would be highly appreciated. > > > > Rajat > > > > > > > > > > > > > > Rajat Mani Thomas > > Social Brain Lab > > Netherlands Institute for Neuroscience > > Amsterdam > > > > _______________________________________________ > > fieldtrip mailing list > > fieldtrip at donders.ru.nl > > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > > ------------------------------ > > Message: 3 > Date: Thu, 7 Apr 2016 15:02:05 -0400 > From: Giovanni Pellegrino > > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Dipole fitting > Message-ID: > > > Content-Type: text/plain; charset="utf-8" > > Dear Fieldtrippers, > > Do you know if the FieldTrip Dipole Fitting has been compared to the CTF, > Elekta, BESA or Curry? Are you aware of any study on this topic? > > Thanks in advance for your help > > Giovanni > > -- > Giovanni Pellegrino, MD > Multimodal Functional Imaging Laboratory > Montreal Neurological Institute, McGill University > Address: 332 Duff Medical Building, 3775 rue University, Montreal, QC, H3A > 2B4, Canada > Phone: (514) 398?1678 > Fax: (514) 398?7461 > Email: giovannipellegrino at gmail.com , giovanni.pellegrino2 at mcgill.ca > Homepage: http://www.bic.mni.mcgill.ca/ResearchLabsMFIL/PeopleGiovanni > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > > ------------------------------ > > Message: 4 > Date: Fri, 8 Apr 2016 09:23:46 +0200 > From: Ole Jensen > > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Birmingham-Illinois BRIDGE Fellowships > Message-ID: <57075C82.8030309 at donders.ru.nl > > Content-Type: text/plain; charset=utf-8; format=flowed > > Dear all, > > I would like to point you to a set of Birmingham-Illinois BRIDGE > Fellowships providing some exciting research and career prospects: > http://www.birminghamillinoisbridge.org/index.php/fellows/ > > In particular the areas 'Cognition and Ageing' and 'Brain Trauma' could > be relevant for candidates with EEG/MEG expertise. > > All the best, > > Ole > > -- > Prof. dr. Ole Jensen > http://www.neuosc.com > > > > ------------------------------ > > Message: 5 > Date: Fri, 08 Apr 2016 10:27:58 +0200 > From: laetitia.lalla at inserm.fr > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Using FieldTrip to analyse LFP recordings in rat > Message-ID: <628babdc107aebd4cc7588ea87ce5ea6 at inserm.fr > > Content-Type: text/plain; charset="utf-8" > > > > Hello everyone, > > my name is Laetitia and I'm a Phd student in Marseille (France). I'm > doing in-vivo recording in freely-moving rats : I implant them with 2 > electrodes deep into 2 different regions of the brain. I'm studying the > Local Field Potentials and I want to use FieldTrip to analyse the data. > > To simplify : > > - I have 2 rats. > > - Each rat did 20 sessions of the task (on 20 different days). > > - Each session consists of 20 trials of condition 1 and 20 trials of > condition 2. > > I have 2 questions. > > 1) I have the feeling it would be meaningless to do "source > reconstruction" because my electrodes are already deep inside my > "source" and the LFP I am recording is very local. (My electrodes have > 32 channels separated by 20-200 ?m. The LFP is very very similar across > all the channels, so I averaged over the 32 channels to have one signal > for each region.) > > However, I see that 2 different functions exist for the statistics : > FT_FREQSTATISTICS AND FT_SOURCESTATISTICS. So far, I've been using > ft_freqstatistics but I encounter some issues (for exemple, doing > monte-carlo permutation test to assess the imaginary coherence). I > thought of computing it manually, but I'm thinking that maybe more stuff > are implemented in ft_sourcestatisctics ? > > ? Are these 2 functions fundamentally different or do they call the same > sub-fonctions (and my problem has actually nothing to do with that) ? > > 2) I'm a bit confused with the vocabulary from EEG and MEG studies (I'm > not used to it yet...). From what I understood, in human studies, you > can do comparison for a single subject (across trials) or across > subjects. But I have 3 levels of comparisons in my design : > > - WITHIN A SESSION, I WANT TO COMPARE ACROSS TRIALS (the 20 trials of > condition 1 VS the 20 trials of condition 2). > > - WITHIN A RAT, I WANT TO COMPARE ACROSS SESSIONS (between the 2 > conditions) > > - then - in the very end - ACROSS RATS. But I have only 2 rats so far, > so I will deal with this later. > > I'm a bit confused when reading the tutorials and the mailing list, > especially when it comes to the statistics... For example : this is from > an email from 2013 by Eric Maris about "Nonparametric statistical > testing of phase coherence" > (http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006401.html ) > "To compare coherence between conditions across subjects (instead of > trials), you need a different statfun: depsamplesT (for a > within-subjects design; subjects have participated in all conditions) or > indepsamplesT (for a between-subjects design; subjects have participated > in only one condition)." > > ? If I want to compare across sessions (for a same rat), can I actually > consider that my different sessions are "subjects"? And then compare > coherence "across subjects" would be doing it "across sessions" ? And I > would be in a "within-subject design" since my sessions involve the 2 > conditions every time ? > > I realise that it may be very confusing... I hope you will understand my > problem ! > > And if anyone already applied fieldtrip functions to do statistics on a > different framework that the usual EEG/MEG, please let me know ! > > Thanks a lot, > > Laetitia Lalla > > PhD Student in Neuroscience > > INMED, Marseille, France > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > > ------------------------------ > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > End of fieldtrip Digest, Vol 65, Issue 7 > **************************************** > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > > -- > > Debora Desideri, PhD Student > BNP Lab - Neurology Department > University Hospital Tübingen > Eberhard Karls University Tübingen > Hoppe-Seyler Str. 3 > D-72076 Tübingen > Tel: +49 7071/29 80478 > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From deb.desideri at gmail.com Fri Apr 15 09:55:43 2016 From: deb.desideri at gmail.com (Debora Desideri) Date: Fri, 15 Apr 2016 09:55:43 +0200 Subject: [FieldTrip] Simbio works with ft_volumereslice but leadfield In-Reply-To: <82D66CB4-DE42-409C-B350-E5DA0984A07E@googlemail.com> References: <1460557552027.85876@nin.knaw.nl> <82D66CB4-DE42-409C-B350-E5DA0984A07E@googlemail.com> Message-ID: Dear Johannes, the time consuming part is when I call ft_prepare_leadfield. The I used this precomputed leadfields for the computation of the dipole solution and this is actually quite fast. I started to use the FEM model only recently and I thought the long lasting calculation was normal. Is there a way to have a faster compuatation of leadfields? Best, Debora On Thu, Apr 14, 2016 at 11:28 PM, Johannes Vorwerk < j.vorwerk at uni-muenster.de> wrote: > Hi Debora, > > could you indicate which part of the computation is the most time > consuming, i.e., calculation of the transfer matrix or the subsequent > computation of the dipole solutions? Principally, it should be possible to > parallelize many of these steps, however, this wasn’t added to the > checked-in code yet for reasons of stability/compatibility. > > Best, > Johannes > > Am 14.04.2016 um 02:21 schrieb Debora Desideri : > > Dear Rajat, > I am also using Simbio and I usually run the leadfield calculation > overnight since it takes approximatelly 12-15 hours for 64 EEG channels > with a grid of 6 mm resolution ( 2.60 GHz, 32 GB RAM). > I don't know whether there is a way to speed the process up. Maybe we just > need to be patient, or work on a very powerful machine. > > Best, > Debora > > > On Wed, Apr 13, 2016 at 4:25 PM, Rajat Thomas > wrote: > >> Dear all, >> >> Last week I asked for help with Simbio and after following the suggestion >> of volume reslicing magically the >> simbio based headmodel was created. >> >> But my leadfield calculations are taking way too long. >> It is a 128^3 grid and am running it on my desktop. (2.4 GHz, plenty of >> memory 32GB) >> >> Could anyone give me a rough ball park on how long it should take to >> create a leadfield? >> >> Thank you. >> Rajat >> >> >> >> Rajat Mani Thomas >> Social Brain Lab >> Netherlands Institute for Neuroscience >> Amsterdam >> >> ________________________________________ >> From: fieldtrip-bounces at science.ru.nl >> on behalf of fieldtrip-request at science.ru.nl < >> fieldtrip-request at science.ru.nl> >> Sent: 08 April 2016 12:00 >> To: fieldtrip at science.ru.nl >> Subject: fieldtrip Digest, Vol 65, Issue 7 >> >> Send fieldtrip mailing list submissions to >> fieldtrip at science.ru.nl >> >> To subscribe or unsubscribe via the World Wide Web, visit >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> or, via email, send a message with subject or body 'help' to >> fieldtrip-request at science.ru.nl >> >> You can reach the person managing the list at >> fieldtrip-owner at science.ru.nl >> >> When replying, please edit your Subject line so it is more specific >> than "Re: Contents of fieldtrip digest..." >> >> >> Today's Topics: >> >> 1. Re: FEM using Simbio (Johannes Vorwerk) >> 2. Re: FEM using Simbio (Cristiano Micheli) >> 3. Dipole fitting (Giovanni Pellegrino) >> 4. Birmingham-Illinois BRIDGE Fellowships (Ole Jensen) >> 5. Using FieldTrip to analyse LFP recordings in rat >> (laetitia.lalla at inserm.fr) >> >> >> ---------------------------------------------------------------------- >> >> Message: 1 >> Date: Thu, 7 Apr 2016 14:25:42 +0200 >> From: Johannes Vorwerk >> To: FieldTrip discussion list >> Subject: Re: [FieldTrip] FEM using Simbio >> Message-ID: <435735E3-7D87-4DD6-A2C1-E2BBFBBF4B44 at googlemail.com> >> Content-Type: text/plain; charset="utf-8" >> >> Hi, >> >> this question was already answered in this thread >> >> http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html < >> http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html> >> >> If ft_volumereslice is not applied before the mesh generation, the >> afterwards applied transformation might flip the directions of the mesh, >> leading to the described error. >> >> Best, >> Johannes >> >> > Am 06.04.2016 um 16:03 schrieb Carsten Wolters < >> carsten.wolters at uni-muenster.de>: >> > >> > Dear Rajat, >> > >> > the element-node cards of SimBio-NeuroFEM need to follow certain >> orientations (see www.simbio.de ). >> > >> > If you do not want to struggle with meshing/ordering, use the >> SimBio-VGRID mesher >> > http://vgrid.simbio.de/ >> > that follows the required ordering of nodes. You might use this mesher >> to produce 1mm geometry-adapted FEM meshes >> > that show good overall performance, see >> > >> http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf >> < >> http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf >> > >> > and >> > >> http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf >> < >> http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf >> > >> > (latter was just accepted by NeuroImage). >> > >> > Best regards >> > Carsten >> > >> > Am 06.04.2016 um 15:10 schrieb Rajat Thomas: >> >> Dear all, >> >> >> >> Has anyone used the FEM approach to Headmodels using Simbio recently? >> >> >> >> If so, I get this error: >> >> "Elements have wrong orientation or are degenerated" >> >> >> >> Any ideas? >> >> >> >> cfg = []; >> >> cfg.method ='simbio'; >> >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows >> mesh.tissyelabel >> >> vol = ft_prepare_headmodel(cfg, mesh); >> >> >> >> And; >> >> ? >> >> disp(mesh) >> >> hex: [545883x8 double] >> >> pnt: [569722x3 double] >> >> labels: [545883x1 double] >> >> tissue: [545883x1 double] >> >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >> >> unit: 'mm' >> >> cfg: [1x1 struct] >> >> >> >> Any help would be highly appreciated. >> >> >> >> Rajat >> >> >> >> >> >> >> >> >> >> >> >> >> >> Rajat Mani Thomas >> >> Social Brain Lab >> >> Netherlands Institute for Neuroscience >> >> Amsterdam >> >> >> >> >> >> _______________________________________________ >> >> fieldtrip mailing list >> >> fieldtrip at donders.ru.nl >> >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip < >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip> >> > _______________________________________________ >> > fieldtrip mailing list >> > fieldtrip at donders.ru.nl >> > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip < >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip> >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> URL: < >> http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160407/2ea995ee/attachment-0001.html >> > >> >> ------------------------------ >> >> Message: 2 >> Date: Thu, 7 Apr 2016 17:36:37 +0200 >> From: Cristiano Micheli >> To: FieldTrip discussion list >> Subject: Re: [FieldTrip] FEM using Simbio >> Message-ID: >> < >> CADW7XCAQONsZ_ujPhkffskZ+j-mnHnAzunS68CdKU6MLSosUPA at mail.gmail.com> >> Content-Type: text/plain; charset="utf-8" >> >> Hi Rajat >> >> My guess is that the orientations of your hexahedrons are not correct. >> According to a low-level file's internal rules, elements' orientations >> have >> to abide strict rules (not sure what exactly the contraints are in this >> case though...). >> I had same problems when for example the triangular boundaries used to >> define the 3d hexahedral mesh were not topologically correct, to start >> with. >> Admittedly this approach requires a lot of technical expertise. >> Can I ask you what do you need a FEM model for? >> >> Regards >> Cris Micheli >> >> >> >> >> On Wed, Apr 6, 2016 at 3:10 PM, Rajat Thomas >> wrote: >> >> > Dear all, >> > >> > >> > Has anyone used the FEM approach to Headmodels using Simbio recently? >> > >> > >> > If so, I get this error: >> > "Elements have wrong orientation or are degenerated" >> > >> > Any ideas? >> > >> > cfg = []; >> > >> > cfg.method ='simbio'; >> > >> > cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows >> > mesh.tissyelabel >> > >> > vol = ft_prepare_headmodel(cfg, mesh); >> > >> > >> > And; >> > >> > ? >> > disp(mesh) >> > hex: [545883x8 double] >> > pnt: [569722x3 double] >> > labels: [545883x1 double] >> > tissue: [545883x1 double] >> > tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >> > unit: 'mm' >> > cfg: [1x1 struct] >> > >> > >> > Any help would be highly appreciated. >> > >> > Rajat >> > >> > >> > >> > >> > >> > >> > Rajat Mani Thomas >> > Social Brain Lab >> > Netherlands Institute for Neuroscience >> > Amsterdam >> > >> > _______________________________________________ >> > fieldtrip mailing list >> > fieldtrip at donders.ru.nl >> > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> > >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> URL: < >> http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160407/4adfe55a/attachment-0001.html >> > >> >> ------------------------------ >> >> Message: 3 >> Date: Thu, 7 Apr 2016 15:02:05 -0400 >> From: Giovanni Pellegrino >> To: fieldtrip at science.ru.nl >> Subject: [FieldTrip] Dipole fitting >> Message-ID: >> > u8GDw at mail.gmail.com> >> Content-Type: text/plain; charset="utf-8" >> >> Dear Fieldtrippers, >> >> Do you know if the FieldTrip Dipole Fitting has been compared to the CTF, >> Elekta, BESA or Curry? Are you aware of any study on this topic? >> >> Thanks in advance for your help >> >> Giovanni >> >> -- >> Giovanni Pellegrino, MD >> Multimodal Functional Imaging Laboratory >> Montreal Neurological Institute, McGill University >> Address: 332 Duff Medical Building, 3775 rue University, Montreal, QC, H3A >> 2B4, Canada >> Phone: (514) 398?1678 >> Fax: (514) 398?7461 >> Email: giovannipellegrino at gmail.com, giovanni.pellegrino2 at mcgill.ca >> Homepage: http://www.bic.mni.mcgill.ca/ResearchLabsMFIL/PeopleGiovanni >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> URL: < >> http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160407/d01144bd/attachment-0001.html >> > >> >> ------------------------------ >> >> Message: 4 >> Date: Fri, 8 Apr 2016 09:23:46 +0200 >> From: Ole Jensen >> To: fieldtrip at science.ru.nl >> Subject: [FieldTrip] Birmingham-Illinois BRIDGE Fellowships >> Message-ID: <57075C82.8030309 at donders.ru.nl> >> Content-Type: text/plain; charset=utf-8; format=flowed >> >> Dear all, >> >> I would like to point you to a set of Birmingham-Illinois BRIDGE >> Fellowships providing some exciting research and career prospects: >> http://www.birminghamillinoisbridge.org/index.php/fellows/ >> >> In particular the areas 'Cognition and Ageing' and 'Brain Trauma' could >> be relevant for candidates with EEG/MEG expertise. >> >> All the best, >> >> Ole >> >> -- >> Prof. dr. Ole Jensen >> http://www.neuosc.com >> >> >> >> ------------------------------ >> >> Message: 5 >> Date: Fri, 08 Apr 2016 10:27:58 +0200 >> From: laetitia.lalla at inserm.fr >> To: fieldtrip at science.ru.nl >> Subject: [FieldTrip] Using FieldTrip to analyse LFP recordings in rat >> Message-ID: <628babdc107aebd4cc7588ea87ce5ea6 at inserm.fr> >> Content-Type: text/plain; charset="utf-8" >> >> >> >> Hello everyone, >> >> my name is Laetitia and I'm a Phd student in Marseille (France). I'm >> doing in-vivo recording in freely-moving rats : I implant them with 2 >> electrodes deep into 2 different regions of the brain. I'm studying the >> Local Field Potentials and I want to use FieldTrip to analyse the data. >> >> To simplify : >> >> - I have 2 rats. >> >> - Each rat did 20 sessions of the task (on 20 different days). >> >> - Each session consists of 20 trials of condition 1 and 20 trials of >> condition 2. >> >> I have 2 questions. >> >> 1) I have the feeling it would be meaningless to do "source >> reconstruction" because my electrodes are already deep inside my >> "source" and the LFP I am recording is very local. (My electrodes have >> 32 channels separated by 20-200 ?m. The LFP is very very similar across >> all the channels, so I averaged over the 32 channels to have one signal >> for each region.) >> >> However, I see that 2 different functions exist for the statistics : >> FT_FREQSTATISTICS AND FT_SOURCESTATISTICS. So far, I've been using >> ft_freqstatistics but I encounter some issues (for exemple, doing >> monte-carlo permutation test to assess the imaginary coherence). I >> thought of computing it manually, but I'm thinking that maybe more stuff >> are implemented in ft_sourcestatisctics ? >> >> ? Are these 2 functions fundamentally different or do they call the same >> sub-fonctions (and my problem has actually nothing to do with that) ? >> >> 2) I'm a bit confused with the vocabulary from EEG and MEG studies (I'm >> not used to it yet...). From what I understood, in human studies, you >> can do comparison for a single subject (across trials) or across >> subjects. But I have 3 levels of comparisons in my design : >> >> - WITHIN A SESSION, I WANT TO COMPARE ACROSS TRIALS (the 20 trials of >> condition 1 VS the 20 trials of condition 2). >> >> - WITHIN A RAT, I WANT TO COMPARE ACROSS SESSIONS (between the 2 >> conditions) >> >> - then - in the very end - ACROSS RATS. But I have only 2 rats so far, >> so I will deal with this later. >> >> I'm a bit confused when reading the tutorials and the mailing list, >> especially when it comes to the statistics... For example : this is from >> an email from 2013 by Eric Maris about "Nonparametric statistical >> testing of phase coherence" >> (http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006401.html) >> "To compare coherence between conditions across subjects (instead of >> trials), you need a different statfun: depsamplesT (for a >> within-subjects design; subjects have participated in all conditions) or >> indepsamplesT (for a between-subjects design; subjects have participated >> in only one condition)." >> >> ? If I want to compare across sessions (for a same rat), can I actually >> consider that my different sessions are "subjects"? And then compare >> coherence "across subjects" would be doing it "across sessions" ? And I >> would be in a "within-subject design" since my sessions involve the 2 >> conditions every time ? >> >> I realise that it may be very confusing... I hope you will understand my >> problem ! >> >> And if anyone already applied fieldtrip functions to do statistics on a >> different framework that the usual EEG/MEG, please let me know ! >> >> Thanks a lot, >> >> Laetitia Lalla >> >> PhD Student in Neuroscience >> >> INMED, Marseille, France >> >> >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> URL: < >> http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160408/2aed96c1/attachment-0001.html >> > >> >> ------------------------------ >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> >> End of fieldtrip Digest, Vol 65, Issue 7 >> **************************************** >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> > > > > -- > > Debora Desideri, PhD Student > BNP Lab - Neurology Department > University Hospital Tübingen > Eberhard Karls University Tübingen > Hoppe-Seyler Str. 3 > D-72076 Tübingen > Tel: +49 7071/29 80478 > > _______________________________________________ > 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 > -- Debora Desideri, PhD Student BNP Lab - Neurology Department University Hospital Tübingen Eberhard Karls University Tübingen Hoppe-Seyler Str. 3 D-72076 Tübingen Tel: +49 7071/29 80478 -------------- next part -------------- An HTML attachment was scrubbed... URL: From Max.Cantor at Colorado.EDU Fri Apr 15 21:48:38 2016 From: Max.Cantor at Colorado.EDU (Max Cantor) Date: Fri, 15 Apr 2016 13:48:38 -0600 Subject: [FieldTrip] TFR mask stats question; Baselined vs unbaselined statistics question In-Reply-To: References: Message-ID: As a followup, I'd like to note that there was a mistake in the multiplot code in my prior post (I had in that code 1,3,5 instead of 1,2,3 as my indices for the stat cell array), and the comment for zlim was not relevant (that was for when I was plotting powspctrm, since the data were freqbaselined). Since the time I posted this, I've tried a few more things that have been somewhat successful. I have set frequency to [1 30], because gamma seemed to be very noisy and the data were bandpass filtered at [0.1 50]hz in the first place so I figured there would be no meaningful effect as high as 50hz. I have also played with the latency, testing a priori assumptions of the time window, as well as a general [0 1.8] window for TFR (and [0 1] window for ERP). Finally, I have tried the analyses using the nonparametric permutation test, but without the cluster correction (and setting cfg.alpha to 0.05 as opposed to 0.025, for the cluster statistics). When I do just the permutation test, I get the effects that I was anticipating in both ERP and TFR. It's only when I add in the cluster correction that I get no significant effects. Does anyone have an idea as to why this might be happening? Best, Max On Fri, Apr 8, 2016 at 3:02 PM, Max Cantor wrote: > Hi fieldtrippers, > > I have two unrelated stats questions, but I figured I'd post them together: > > 1. I've run within subjects permutation statistics testing the difference > between an anomaly and control condition for three different language > conditions; preposition, morphosyntax, and semantics. The code is nearly > identical for both my ERPs and TFRs, except that when I plot my ERPs with > cfg.maskparameter = 'mask', cfg.parameter = 'stat', and cfg.maskalpha = > 0.025, it seems to multiplot just fine, whereas when I try to do the same > for the TFRs, my multiplotted plots are blank, but when I comment out the > mask, the stat plots are fine. I'll attach the code, but is there something > I'm doing obviously wrong? Also, am I correct that my maskalpha should > correspond to my alpha, and not my cluster alpha? > > This is the TFR code, but the ERP code is the exact same except for with > timelocked data as the input and ft_timelockstatistics as the function. > > cfg = []; > cfg.method = 'montecarlo'; > cfg.statistic = 'depsamplesT'; > cfg.correctm = 'cluster'; > cfg.clusteralpha = 0.05; > cfg.clusterstatistic = 'maxsum'; > cfg.minnbchan = 2; > cfg.neighbours = neighbours; > cfg.tail = 0; > cfg.clustertail = 0; > cfg.alpha = 0.025; > cfg.numrandomization = 1000; > > nsubj = length(tot_tfr2_bl{1}); > design = zeros(2,2*nsubj); > for i = 1:nsubj > design(1,i) = i; > end > for i = 1:nsubj > design(1,nsubj+i) = i; > end > design(2,1:nsubj) = 1; > design(2,nsubj+1:2*nsubj) = 2; > > cfg.design = design; > cfg.uvar = 1; > cfg.ivar = 2; > > % Anomaly vs Control > stat_tfr{1} = ft_freqstatistics(cfg, tot_tfr2_bl{1}{:}, > tot_tfr2_bl{2}{:}); % Preposition > stat_tfr{2} = ft_freqstatistics(cfg, tot_tfr2_bl{3}{:}, > tot_tfr2_bl{4}{:}); % Semantics > stat_tfr{3} = ft_freqstatistics(cfg, tot_tfr2_bl{5}{:}, > tot_tfr2_bl{6}{:}); % Morphosyntax > > This is the plotting code. Again, it is virtually the same for the ERPs > except the non-stats configurations would be what makes sense for ERPs. > > % Anomaly vs Control TFR stats multiplot > > cfg = []; > cfg.xlim = [-0.2 1]; > cfg.zlim = [-3 3]; % proportion from baseline > cfg.layout = [max_dir '/quickcap64.mat']; > cfg.maskparameter = 'mask'; > cfg.parameter = 'stat'; > cfg.maskalpha = 0.025; > > ft_multiplotTFR(cfg, stat_tfr{1}); title('Preposition'); > ft_multiplotTFR(cfg, stat_tfr{3}); title('Semantic'); > ft_multiplotTFR(cfg, stat_tfr{5}); title('Morphosyntactic'); > > > 2. The second question is about analyzing baselined vs unbaselined data. > I've seen in the tutorials that there is a somewhat different method for > analyzing trial vs baseline period. However, what I've done instead (for > both ERP and TFR), is use the same within-subjects statistics as with > anomaly vs control, except with the inputs being baselined vs unbaselined > ERPs or TFRs, e.g. Baselined Preposition Anomaly vs Unbaselined Preposition > Anomaly, etc. I understand that the proposed method and my method are not > testing the same thing exactly, but is this a reasonable way of testing the > effect of the baselining anyway? > > Thanks, > > Max > > -- > Max Cantor > Graduate Student > Cognitive Neuroscience of Language Lab > University of Colorado Boulder > -- Max Cantor Graduate Student Cognitive Neuroscience of Language Lab University of Colorado Boulder -------------- next part -------------- An HTML attachment was scrubbed... URL: From j.vorwerk at uni-muenster.de Sun Apr 17 15:34:48 2016 From: j.vorwerk at uni-muenster.de (Johannes Vorwerk) Date: Sun, 17 Apr 2016 07:34:48 -0600 Subject: [FieldTrip] Simbio works with ft_volumereslice but leadfield In-Reply-To: References: <1460557552027.85876@nin.knaw.nl> <82D66CB4-DE42-409C-B350-E5DA0984A07E@googlemail.com> Message-ID: <24BC90ED-EEAA-4AAD-A0A3-0AB6E16E8108@googlemail.com> Hi, could you check if it’s the calculation of the transfer matrix (ft_prepare_vol_sens), which you can recoginze since the #electrode many equations are solved, or the call of leadfield_simbio that takes up the most time? It is normal that the matlab-code takes more time than the SimBio-standalon binary, since it includes some loops. I’ve never experienced such long computations as you did in my testings, so I didn’t think about it very much so far. One might try to find a way to formulate these parts without loops or use parallel loops at some points. Best, Johannes > Am 15.04.2016 um 01:55 schrieb Debora Desideri : > > Dear Johannes, > the time consuming part is when I call ft_prepare_leadfield. The I used this precomputed leadfields for the computation of the dipole solution and this is actually quite fast. > I started to use the FEM model only recently and I thought the long lasting calculation was normal. Is there a way to have a faster compuatation of leadfields? > > Best, > Debora > > > On Thu, Apr 14, 2016 at 11:28 PM, Johannes Vorwerk > wrote: > Hi Debora, > > could you indicate which part of the computation is the most time consuming, i.e., calculation of the transfer matrix or the subsequent computation of the dipole solutions? Principally, it should be possible to parallelize many of these steps, however, this wasn’t added to the checked-in code yet for reasons of stability/compatibility. > > Best, > Johannes > >> Am 14.04.2016 um 02:21 schrieb Debora Desideri >: >> >> Dear Rajat, >> I am also using Simbio and I usually run the leadfield calculation overnight since it takes approximatelly 12-15 hours for 64 EEG channels with a grid of 6 mm resolution ( 2.60 GHz, 32 GB RAM). >> I don't know whether there is a way to speed the process up. Maybe we just need to be patient, or work on a very powerful machine. >> >> Best, >> Debora >> >> >> On Wed, Apr 13, 2016 at 4:25 PM, Rajat Thomas > wrote: >> Dear all, >> >> Last week I asked for help with Simbio and after following the suggestion of volume reslicing magically the >> simbio based headmodel was created. >> >> But my leadfield calculations are taking way too long. >> It is a 128^3 grid and am running it on my desktop. (2.4 GHz, plenty of memory 32GB) >> >> Could anyone give me a rough ball park on how long it should take to create a leadfield? >> >> Thank you. >> Rajat >> >> >> >> Rajat Mani Thomas >> Social Brain Lab >> Netherlands Institute for Neuroscience >> Amsterdam >> >> ________________________________________ >> From: fieldtrip-bounces at science.ru.nl > on behalf of fieldtrip-request at science.ru.nl > >> Sent: 08 April 2016 12:00 >> To: fieldtrip at science.ru.nl >> Subject: fieldtrip Digest, Vol 65, Issue 7 >> >> Send fieldtrip mailing list submissions to >> fieldtrip at science.ru.nl >> >> To subscribe or unsubscribe via the World Wide Web, visit >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> or, via email, send a message with subject or body 'help' to >> fieldtrip-request at science.ru.nl >> >> You can reach the person managing the list at >> fieldtrip-owner at science.ru.nl >> >> When replying, please edit your Subject line so it is more specific >> than "Re: Contents of fieldtrip digest..." >> >> >> Today's Topics: >> >> 1. Re: FEM using Simbio (Johannes Vorwerk) >> 2. Re: FEM using Simbio (Cristiano Micheli) >> 3. Dipole fitting (Giovanni Pellegrino) >> 4. Birmingham-Illinois BRIDGE Fellowships (Ole Jensen) >> 5. Using FieldTrip to analyse LFP recordings in rat >> (laetitia.lalla at inserm.fr ) >> >> >> ---------------------------------------------------------------------- >> >> Message: 1 >> Date: Thu, 7 Apr 2016 14:25:42 +0200 >> From: Johannes Vorwerk > >> To: FieldTrip discussion list > >> Subject: Re: [FieldTrip] FEM using Simbio >> Message-ID: <435735E3-7D87-4DD6-A2C1-E2BBFBBF4B44 at googlemail.com > >> Content-Type: text/plain; charset="utf-8" >> >> Hi, >> >> this question was already answered in this thread >> >> http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html > >> >> If ft_volumereslice is not applied before the mesh generation, the afterwards applied transformation might flip the directions of the mesh, leading to the described error. >> >> Best, >> Johannes >> >> > Am 06.04.2016 um 16:03 schrieb Carsten Wolters >: >> > >> > Dear Rajat, >> > >> > the element-node cards of SimBio-NeuroFEM need to follow certain orientations (see www.simbio.de >). >> > >> > If you do not want to struggle with meshing/ordering, use the SimBio-VGRID mesher >> > http://vgrid.simbio.de/ > >> > that follows the required ordering of nodes. You might use this mesher to produce 1mm geometry-adapted FEM meshes >> > that show good overall performance, see >> > http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf > >> > and >> > http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf > >> > (latter was just accepted by NeuroImage). >> > >> > Best regards >> > Carsten >> > >> > Am 06.04.2016 um 15:10 schrieb Rajat Thomas: >> >> Dear all, >> >> >> >> Has anyone used the FEM approach to Headmodels using Simbio recently? >> >> >> >> If so, I get this error: >> >> "Elements have wrong orientation or are degenerated" >> >> >> >> Any ideas? >> >> >> >> cfg = []; >> >> cfg.method ='simbio'; >> >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows mesh.tissyelabel >> >> vol = ft_prepare_headmodel(cfg, mesh); >> >> >> >> And; >> >> ? >> >> disp(mesh) >> >> hex: [545883x8 double] >> >> pnt: [569722x3 double] >> >> labels: [545883x1 double] >> >> tissue: [545883x1 double] >> >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >> >> unit: 'mm' >> >> cfg: [1x1 struct] >> >> >> >> Any help would be highly appreciated. >> >> >> >> Rajat >> >> >> >> >> >> >> >> >> >> >> >> >> >> Rajat Mani Thomas >> >> Social Brain Lab >> >> Netherlands Institute for Neuroscience >> >> Amsterdam >> >> >> >> >> >> _______________________________________________ >> >> 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 > >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> URL: > >> >> ------------------------------ >> >> Message: 2 >> Date: Thu, 7 Apr 2016 17:36:37 +0200 >> From: Cristiano Micheli > >> To: FieldTrip discussion list > >> Subject: Re: [FieldTrip] FEM using Simbio >> Message-ID: >> > >> Content-Type: text/plain; charset="utf-8" >> >> Hi Rajat >> >> My guess is that the orientations of your hexahedrons are not correct. >> According to a low-level file's internal rules, elements' orientations have >> to abide strict rules (not sure what exactly the contraints are in this >> case though...). >> I had same problems when for example the triangular boundaries used to >> define the 3d hexahedral mesh were not topologically correct, to start with. >> Admittedly this approach requires a lot of technical expertise. >> Can I ask you what do you need a FEM model for? >> >> Regards >> Cris Micheli >> >> >> >> >> On Wed, Apr 6, 2016 at 3:10 PM, Rajat Thomas > wrote: >> >> > Dear all, >> > >> > >> > Has anyone used the FEM approach to Headmodels using Simbio recently? >> > >> > >> > If so, I get this error: >> > "Elements have wrong orientation or are degenerated" >> > >> > Any ideas? >> > >> > cfg = []; >> > >> > cfg.method ='simbio'; >> > >> > cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows >> > mesh.tissyelabel >> > >> > vol = ft_prepare_headmodel(cfg, mesh); >> > >> > >> > And; >> > >> > ? >> > disp(mesh) >> > hex: [545883x8 double] >> > pnt: [569722x3 double] >> > labels: [545883x1 double] >> > tissue: [545883x1 double] >> > tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >> > unit: 'mm' >> > cfg: [1x1 struct] >> > >> > >> > Any help would be highly appreciated. >> > >> > Rajat >> > >> > >> > >> > >> > >> > >> > Rajat Mani Thomas >> > Social Brain Lab >> > Netherlands Institute for Neuroscience >> > Amsterdam >> > >> > _______________________________________________ >> > fieldtrip mailing list >> > fieldtrip at donders.ru.nl >> > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> > >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> URL: > >> >> ------------------------------ >> >> Message: 3 >> Date: Thu, 7 Apr 2016 15:02:05 -0400 >> From: Giovanni Pellegrino > >> To: fieldtrip at science.ru.nl >> Subject: [FieldTrip] Dipole fitting >> Message-ID: >> > >> Content-Type: text/plain; charset="utf-8" >> >> Dear Fieldtrippers, >> >> Do you know if the FieldTrip Dipole Fitting has been compared to the CTF, >> Elekta, BESA or Curry? Are you aware of any study on this topic? >> >> Thanks in advance for your help >> >> Giovanni >> >> -- >> Giovanni Pellegrino, MD >> Multimodal Functional Imaging Laboratory >> Montreal Neurological Institute, McGill University >> Address: 332 Duff Medical Building, 3775 rue University, Montreal, QC, H3A >> 2B4, Canada >> Phone: (514) 398?1678 >> Fax: (514) 398?7461 >> Email: giovannipellegrino at gmail.com , giovanni.pellegrino2 at mcgill.ca >> Homepage: http://www.bic.mni.mcgill.ca/ResearchLabsMFIL/PeopleGiovanni >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> URL: > >> >> ------------------------------ >> >> Message: 4 >> Date: Fri, 8 Apr 2016 09:23:46 +0200 >> From: Ole Jensen > >> To: fieldtrip at science.ru.nl >> Subject: [FieldTrip] Birmingham-Illinois BRIDGE Fellowships >> Message-ID: <57075C82.8030309 at donders.ru.nl > >> Content-Type: text/plain; charset=utf-8; format=flowed >> >> Dear all, >> >> I would like to point you to a set of Birmingham-Illinois BRIDGE >> Fellowships providing some exciting research and career prospects: >> http://www.birminghamillinoisbridge.org/index.php/fellows/ >> >> In particular the areas 'Cognition and Ageing' and 'Brain Trauma' could >> be relevant for candidates with EEG/MEG expertise. >> >> All the best, >> >> Ole >> >> -- >> Prof. dr. Ole Jensen >> http://www.neuosc.com >> >> >> >> ------------------------------ >> >> Message: 5 >> Date: Fri, 08 Apr 2016 10:27:58 +0200 >> From: laetitia.lalla at inserm.fr >> To: fieldtrip at science.ru.nl >> Subject: [FieldTrip] Using FieldTrip to analyse LFP recordings in rat >> Message-ID: <628babdc107aebd4cc7588ea87ce5ea6 at inserm.fr > >> Content-Type: text/plain; charset="utf-8" >> >> >> >> Hello everyone, >> >> my name is Laetitia and I'm a Phd student in Marseille (France). I'm >> doing in-vivo recording in freely-moving rats : I implant them with 2 >> electrodes deep into 2 different regions of the brain. I'm studying the >> Local Field Potentials and I want to use FieldTrip to analyse the data. >> >> To simplify : >> >> - I have 2 rats. >> >> - Each rat did 20 sessions of the task (on 20 different days). >> >> - Each session consists of 20 trials of condition 1 and 20 trials of >> condition 2. >> >> I have 2 questions. >> >> 1) I have the feeling it would be meaningless to do "source >> reconstruction" because my electrodes are already deep inside my >> "source" and the LFP I am recording is very local. (My electrodes have >> 32 channels separated by 20-200 ?m. The LFP is very very similar across >> all the channels, so I averaged over the 32 channels to have one signal >> for each region.) >> >> However, I see that 2 different functions exist for the statistics : >> FT_FREQSTATISTICS AND FT_SOURCESTATISTICS. So far, I've been using >> ft_freqstatistics but I encounter some issues (for exemple, doing >> monte-carlo permutation test to assess the imaginary coherence). I >> thought of computing it manually, but I'm thinking that maybe more stuff >> are implemented in ft_sourcestatisctics ? >> >> ? Are these 2 functions fundamentally different or do they call the same >> sub-fonctions (and my problem has actually nothing to do with that) ? >> >> 2) I'm a bit confused with the vocabulary from EEG and MEG studies (I'm >> not used to it yet...). From what I understood, in human studies, you >> can do comparison for a single subject (across trials) or across >> subjects. But I have 3 levels of comparisons in my design : >> >> - WITHIN A SESSION, I WANT TO COMPARE ACROSS TRIALS (the 20 trials of >> condition 1 VS the 20 trials of condition 2). >> >> - WITHIN A RAT, I WANT TO COMPARE ACROSS SESSIONS (between the 2 >> conditions) >> >> - then - in the very end - ACROSS RATS. But I have only 2 rats so far, >> so I will deal with this later. >> >> I'm a bit confused when reading the tutorials and the mailing list, >> especially when it comes to the statistics... For example : this is from >> an email from 2013 by Eric Maris about "Nonparametric statistical >> testing of phase coherence" >> (http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006401.html ) >> "To compare coherence between conditions across subjects (instead of >> trials), you need a different statfun: depsamplesT (for a >> within-subjects design; subjects have participated in all conditions) or >> indepsamplesT (for a between-subjects design; subjects have participated >> in only one condition)." >> >> ? If I want to compare across sessions (for a same rat), can I actually >> consider that my different sessions are "subjects"? And then compare >> coherence "across subjects" would be doing it "across sessions" ? And I >> would be in a "within-subject design" since my sessions involve the 2 >> conditions every time ? >> >> I realise that it may be very confusing... I hope you will understand my >> problem ! >> >> And if anyone already applied fieldtrip functions to do statistics on a >> different framework that the usual EEG/MEG, please let me know ! >> >> Thanks a lot, >> >> Laetitia Lalla >> >> PhD Student in Neuroscience >> >> INMED, Marseille, France >> >> >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> URL: > >> >> ------------------------------ >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> >> End of fieldtrip Digest, Vol 65, Issue 7 >> **************************************** >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> >> >> >> -- >> >> Debora Desideri, PhD Student >> BNP Lab - Neurology Department >> University Hospital Tübingen >> Eberhard Karls University Tübingen >> Hoppe-Seyler Str. 3 >> D-72076 Tübingen >> Tel: +49 7071/29 80478 >> >> _______________________________________________ >> 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 > > > > -- > > Debora Desideri, PhD Student > BNP Lab - Neurology Department > University Hospital Tübingen > Eberhard Karls University Tübingen > Hoppe-Seyler Str. 3 > D-72076 Tübingen > Tel: +49 7071/29 80478 > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From deb.desideri at gmail.com Sun Apr 17 21:08:32 2016 From: deb.desideri at gmail.com (Debora Desideri) Date: Sun, 17 Apr 2016 21:08:32 +0200 Subject: [FieldTrip] Simbio works with ft_volumereslice but leadfield In-Reply-To: <24BC90ED-EEAA-4AAD-A0A3-0AB6E16E8108@googlemail.com> References: <1460557552027.85876@nin.knaw.nl> <82D66CB4-DE42-409C-B350-E5DA0984A07E@googlemail.com> <24BC90ED-EEAA-4AAD-A0A3-0AB6E16E8108@googlemail.com> Message-ID: Dear Johannes, yes, the calculation of the transfer matrix is actually the part that takes so long (ft_prepare_vol_sens). But as you point out, it is maybe just a not efficient matlab implementation... Best, Debora On Sun, Apr 17, 2016 at 3:34 PM, Johannes Vorwerk wrote: > Hi, > > could you check if it’s the calculation of the transfer matrix > (ft_prepare_vol_sens), which you can recoginze since the #electrode many > equations are solved, or the call of leadfield_simbio that takes up the > most time? > > It is normal that the matlab-code takes more time than the > SimBio-standalon binary, since it includes some loops. I’ve never > experienced such long computations as you did in my testings, so I didn’t > think about it very much so far. One might try to find a way to formulate > these parts without loops or use parallel loops at some points. > > Best, > Johannes > > Am 15.04.2016 um 01:55 schrieb Debora Desideri : > > Dear Johannes, > the time consuming part is when I call ft_prepare_leadfield. The I used > this precomputed leadfields for the computation of the dipole solution and > this is actually quite fast. > I started to use the FEM model only recently and I thought the long > lasting calculation was normal. Is there a way to have a faster > compuatation of leadfields? > > Best, > Debora > > > On Thu, Apr 14, 2016 at 11:28 PM, Johannes Vorwerk < > j.vorwerk at uni-muenster.de> wrote: > >> Hi Debora, >> >> could you indicate which part of the computation is the most time >> consuming, i.e., calculation of the transfer matrix or the subsequent >> computation of the dipole solutions? Principally, it should be possible to >> parallelize many of these steps, however, this wasn’t added to the >> checked-in code yet for reasons of stability/compatibility. >> >> Best, >> Johannes >> >> Am 14.04.2016 um 02:21 schrieb Debora Desideri : >> >> Dear Rajat, >> I am also using Simbio and I usually run the leadfield calculation >> overnight since it takes approximatelly 12-15 hours for 64 EEG channels >> with a grid of 6 mm resolution ( 2.60 GHz, 32 GB RAM). >> I don't know whether there is a way to speed the process up. Maybe we >> just need to be patient, or work on a very powerful machine. >> >> Best, >> Debora >> >> >> On Wed, Apr 13, 2016 at 4:25 PM, Rajat Thomas >> wrote: >> >>> Dear all, >>> >>> Last week I asked for help with Simbio and after following the >>> suggestion of volume reslicing magically the >>> simbio based headmodel was created. >>> >>> But my leadfield calculations are taking way too long. >>> It is a 128^3 grid and am running it on my desktop. (2.4 GHz, plenty of >>> memory 32GB) >>> >>> Could anyone give me a rough ball park on how long it should take to >>> create a leadfield? >>> >>> Thank you. >>> Rajat >>> >>> >>> >>> Rajat Mani Thomas >>> Social Brain Lab >>> Netherlands Institute for Neuroscience >>> Amsterdam >>> >>> ________________________________________ >>> From: fieldtrip-bounces at science.ru.nl >>> on behalf of fieldtrip-request at science.ru.nl < >>> fieldtrip-request at science.ru.nl> >>> Sent: 08 April 2016 12:00 >>> To: fieldtrip at science.ru.nl >>> Subject: fieldtrip Digest, Vol 65, Issue 7 >>> >>> Send fieldtrip mailing list submissions to >>> fieldtrip at science.ru.nl >>> >>> To subscribe or unsubscribe via the World Wide Web, visit >>> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >>> or, via email, send a message with subject or body 'help' to >>> fieldtrip-request at science.ru.nl >>> >>> You can reach the person managing the list at >>> fieldtrip-owner at science.ru.nl >>> >>> When replying, please edit your Subject line so it is more specific >>> than "Re: Contents of fieldtrip digest..." >>> >>> >>> Today's Topics: >>> >>> 1. Re: FEM using Simbio (Johannes Vorwerk) >>> 2. Re: FEM using Simbio (Cristiano Micheli) >>> 3. Dipole fitting (Giovanni Pellegrino) >>> 4. Birmingham-Illinois BRIDGE Fellowships (Ole Jensen) >>> 5. Using FieldTrip to analyse LFP recordings in rat >>> (laetitia.lalla at inserm.fr) >>> >>> >>> ---------------------------------------------------------------------- >>> >>> Message: 1 >>> Date: Thu, 7 Apr 2016 14:25:42 +0200 >>> From: Johannes Vorwerk >>> To: FieldTrip discussion list >>> Subject: Re: [FieldTrip] FEM using Simbio >>> Message-ID: <435735E3-7D87-4DD6-A2C1-E2BBFBBF4B44 at googlemail.com> >>> Content-Type: text/plain; charset="utf-8" >>> >>> Hi, >>> >>> this question was already answered in this thread >>> >>> http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html >>> >> > >>> >>> If ft_volumereslice is not applied before the mesh generation, the >>> afterwards applied transformation might flip the directions of the mesh, >>> leading to the described error. >>> >>> Best, >>> Johannes >>> >>> > Am 06.04.2016 um 16:03 schrieb Carsten Wolters < >>> carsten.wolters at uni-muenster.de>: >>> > >>> > Dear Rajat, >>> > >>> > the element-node cards of SimBio-NeuroFEM need to follow certain >>> orientations (see www.simbio.de ). >>> > >>> > If you do not want to struggle with meshing/ordering, use the >>> SimBio-VGRID mesher >>> > http://vgrid.simbio.de/ >>> > that follows the required ordering of nodes. You might use this mesher >>> to produce 1mm geometry-adapted FEM meshes >>> > that show good overall performance, see >>> > >>> http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf >>> < >>> http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf >>> > >>> > and >>> > >>> http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf >>> < >>> http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf >>> > >>> > (latter was just accepted by NeuroImage). >>> > >>> > Best regards >>> > Carsten >>> > >>> > Am 06.04.2016 um 15:10 schrieb Rajat Thomas: >>> >> Dear all, >>> >> >>> >> Has anyone used the FEM approach to Headmodels using Simbio recently? >>> >> >>> >> If so, I get this error: >>> >> "Elements have wrong orientation or are degenerated" >>> >> >>> >> Any ideas? >>> >> >>> >> cfg = []; >>> >> cfg.method ='simbio'; >>> >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows >>> mesh.tissyelabel >>> >> vol = ft_prepare_headmodel(cfg, mesh); >>> >> >>> >> And; >>> >> ? >>> >> disp(mesh) >>> >> hex: [545883x8 double] >>> >> pnt: [569722x3 double] >>> >> labels: [545883x1 double] >>> >> tissue: [545883x1 double] >>> >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >>> >> unit: 'mm' >>> >> cfg: [1x1 struct] >>> >> >>> >> Any help would be highly appreciated. >>> >> >>> >> Rajat >>> >> >>> >> >>> >> >>> >> >>> >> >>> >> >>> >> Rajat Mani Thomas >>> >> Social Brain Lab >>> >> Netherlands Institute for Neuroscience >>> >> Amsterdam >>> >> >>> >> >>> >> _______________________________________________ >>> >> fieldtrip mailing list >>> >> fieldtrip at donders.ru.nl >>> >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip < >>> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip> >>> > _______________________________________________ >>> > fieldtrip mailing list >>> > fieldtrip at donders.ru.nl >>> > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip < >>> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip> >>> -------------- next part -------------- >>> An HTML attachment was scrubbed... >>> URL: < >>> http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160407/2ea995ee/attachment-0001.html >>> > >>> >>> ------------------------------ >>> >>> Message: 2 >>> Date: Thu, 7 Apr 2016 17:36:37 +0200 >>> From: Cristiano Micheli >>> To: FieldTrip discussion list >>> Subject: Re: [FieldTrip] FEM using Simbio >>> Message-ID: >>> < >>> CADW7XCAQONsZ_ujPhkffskZ+j-mnHnAzunS68CdKU6MLSosUPA at mail.gmail.com> >>> Content-Type: text/plain; charset="utf-8" >>> >>> Hi Rajat >>> >>> My guess is that the orientations of your hexahedrons are not correct. >>> According to a low-level file's internal rules, elements' orientations >>> have >>> to abide strict rules (not sure what exactly the contraints are in this >>> case though...). >>> I had same problems when for example the triangular boundaries used to >>> define the 3d hexahedral mesh were not topologically correct, to start >>> with. >>> Admittedly this approach requires a lot of technical expertise. >>> Can I ask you what do you need a FEM model for? >>> >>> Regards >>> Cris Micheli >>> >>> >>> >>> >>> On Wed, Apr 6, 2016 at 3:10 PM, Rajat Thomas >>> wrote: >>> >>> > Dear all, >>> > >>> > >>> > Has anyone used the FEM approach to Headmodels using Simbio recently? >>> > >>> > >>> > If so, I get this error: >>> > "Elements have wrong orientation or are degenerated" >>> > >>> > Any ideas? >>> > >>> > cfg = []; >>> > >>> > cfg.method ='simbio'; >>> > >>> > cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows >>> > mesh.tissyelabel >>> > >>> > vol = ft_prepare_headmodel(cfg, mesh); >>> > >>> > >>> > And; >>> > >>> > ? >>> > disp(mesh) >>> > hex: [545883x8 double] >>> > pnt: [569722x3 double] >>> > labels: [545883x1 double] >>> > tissue: [545883x1 double] >>> > tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >>> > unit: 'mm' >>> > cfg: [1x1 struct] >>> > >>> > >>> > Any help would be highly appreciated. >>> > >>> > Rajat >>> > >>> > >>> > >>> > >>> > >>> > >>> > Rajat Mani Thomas >>> > Social Brain Lab >>> > Netherlands Institute for Neuroscience >>> > Amsterdam >>> > >>> > _______________________________________________ >>> > fieldtrip mailing list >>> > fieldtrip at donders.ru.nl >>> > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >>> > >>> -------------- next part -------------- >>> An HTML attachment was scrubbed... >>> URL: < >>> http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160407/4adfe55a/attachment-0001.html >>> > >>> >>> ------------------------------ >>> >>> Message: 3 >>> Date: Thu, 7 Apr 2016 15:02:05 -0400 >>> From: Giovanni Pellegrino >>> To: fieldtrip at science.ru.nl >>> Subject: [FieldTrip] Dipole fitting >>> Message-ID: >>> >> u8GDw at mail.gmail.com> >>> Content-Type: text/plain; charset="utf-8" >>> >>> Dear Fieldtrippers, >>> >>> Do you know if the FieldTrip Dipole Fitting has been compared to the CTF, >>> Elekta, BESA or Curry? Are you aware of any study on this topic? >>> >>> Thanks in advance for your help >>> >>> Giovanni >>> >>> -- >>> Giovanni Pellegrino, MD >>> Multimodal Functional Imaging Laboratory >>> Montreal Neurological Institute, McGill University >>> Address: 332 Duff Medical Building, 3775 rue University, Montreal, QC, >>> H3A >>> 2B4, Canada >>> Phone: (514) 398?1678 >>> Fax: (514) 398?7461 >>> Email: giovannipellegrino at gmail.com, giovanni.pellegrino2 at mcgill.ca >>> Homepage: http://www.bic.mni.mcgill.ca/ResearchLabsMFIL/PeopleGiovanni >>> -------------- next part -------------- >>> An HTML attachment was scrubbed... >>> URL: < >>> http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160407/d01144bd/attachment-0001.html >>> > >>> >>> ------------------------------ >>> >>> Message: 4 >>> Date: Fri, 8 Apr 2016 09:23:46 +0200 >>> From: Ole Jensen >>> To: fieldtrip at science.ru.nl >>> Subject: [FieldTrip] Birmingham-Illinois BRIDGE Fellowships >>> Message-ID: <57075C82.8030309 at donders.ru.nl> >>> Content-Type: text/plain; charset=utf-8; format=flowed >>> >>> Dear all, >>> >>> I would like to point you to a set of Birmingham-Illinois BRIDGE >>> Fellowships providing some exciting research and career prospects: >>> http://www.birminghamillinoisbridge.org/index.php/fellows/ >>> >>> In particular the areas 'Cognition and Ageing' and 'Brain Trauma' could >>> be relevant for candidates with EEG/MEG expertise. >>> >>> All the best, >>> >>> Ole >>> >>> -- >>> Prof. dr. Ole Jensen >>> http://www.neuosc.com >>> >>> >>> >>> ------------------------------ >>> >>> Message: 5 >>> Date: Fri, 08 Apr 2016 10:27:58 +0200 >>> From: laetitia.lalla at inserm.fr >>> To: fieldtrip at science.ru.nl >>> Subject: [FieldTrip] Using FieldTrip to analyse LFP recordings in rat >>> Message-ID: <628babdc107aebd4cc7588ea87ce5ea6 at inserm.fr> >>> Content-Type: text/plain; charset="utf-8" >>> >>> >>> >>> Hello everyone, >>> >>> my name is Laetitia and I'm a Phd student in Marseille (France). I'm >>> doing in-vivo recording in freely-moving rats : I implant them with 2 >>> electrodes deep into 2 different regions of the brain. I'm studying the >>> Local Field Potentials and I want to use FieldTrip to analyse the data. >>> >>> To simplify : >>> >>> - I have 2 rats. >>> >>> - Each rat did 20 sessions of the task (on 20 different days). >>> >>> - Each session consists of 20 trials of condition 1 and 20 trials of >>> condition 2. >>> >>> I have 2 questions. >>> >>> 1) I have the feeling it would be meaningless to do "source >>> reconstruction" because my electrodes are already deep inside my >>> "source" and the LFP I am recording is very local. (My electrodes have >>> 32 channels separated by 20-200 ?m. The LFP is very very similar across >>> all the channels, so I averaged over the 32 channels to have one signal >>> for each region.) >>> >>> However, I see that 2 different functions exist for the statistics : >>> FT_FREQSTATISTICS AND FT_SOURCESTATISTICS. So far, I've been using >>> ft_freqstatistics but I encounter some issues (for exemple, doing >>> monte-carlo permutation test to assess the imaginary coherence). I >>> thought of computing it manually, but I'm thinking that maybe more stuff >>> are implemented in ft_sourcestatisctics ? >>> >>> ? Are these 2 functions fundamentally different or do they call the same >>> sub-fonctions (and my problem has actually nothing to do with that) ? >>> >>> 2) I'm a bit confused with the vocabulary from EEG and MEG studies (I'm >>> not used to it yet...). From what I understood, in human studies, you >>> can do comparison for a single subject (across trials) or across >>> subjects. But I have 3 levels of comparisons in my design : >>> >>> - WITHIN A SESSION, I WANT TO COMPARE ACROSS TRIALS (the 20 trials of >>> condition 1 VS the 20 trials of condition 2). >>> >>> - WITHIN A RAT, I WANT TO COMPARE ACROSS SESSIONS (between the 2 >>> conditions) >>> >>> - then - in the very end - ACROSS RATS. But I have only 2 rats so far, >>> so I will deal with this later. >>> >>> I'm a bit confused when reading the tutorials and the mailing list, >>> especially when it comes to the statistics... For example : this is from >>> an email from 2013 by Eric Maris about "Nonparametric statistical >>> testing of phase coherence" >>> (http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006401.html >>> ) >>> "To compare coherence between conditions across subjects (instead of >>> trials), you need a different statfun: depsamplesT (for a >>> within-subjects design; subjects have participated in all conditions) or >>> indepsamplesT (for a between-subjects design; subjects have participated >>> in only one condition)." >>> >>> ? If I want to compare across sessions (for a same rat), can I actually >>> consider that my different sessions are "subjects"? And then compare >>> coherence "across subjects" would be doing it "across sessions" ? And I >>> would be in a "within-subject design" since my sessions involve the 2 >>> conditions every time ? >>> >>> I realise that it may be very confusing... I hope you will understand my >>> problem ! >>> >>> And if anyone already applied fieldtrip functions to do statistics on a >>> different framework that the usual EEG/MEG, please let me know ! >>> >>> Thanks a lot, >>> >>> Laetitia Lalla >>> >>> PhD Student in Neuroscience >>> >>> INMED, Marseille, France >>> >>> >>> -------------- next part -------------- >>> An HTML attachment was scrubbed... >>> URL: < >>> http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160408/2aed96c1/attachment-0001.html >>> > >>> >>> ------------------------------ >>> >>> _______________________________________________ >>> fieldtrip mailing list >>> fieldtrip at donders.ru.nl >>> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >>> >>> End of fieldtrip Digest, Vol 65, Issue 7 >>> **************************************** >>> >>> _______________________________________________ >>> fieldtrip mailing list >>> fieldtrip at donders.ru.nl >>> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >>> >> >> >> >> -- >> >> Debora Desideri, PhD Student >> BNP Lab - Neurology Department >> University Hospital Tübingen >> Eberhard Karls University Tübingen >> Hoppe-Seyler Str. 3 >> D-72076 Tübingen >> Tel: +49 7071/29 80478 >> >> _______________________________________________ >> 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 >> > > > > -- > > Debora Desideri, PhD Student > BNP Lab - Neurology Department > University Hospital Tübingen > Eberhard Karls University Tübingen > Hoppe-Seyler Str. 3 > D-72076 Tübingen > Tel: +49 7071/29 80478 > > _______________________________________________ > 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 > -- Debora Desideri, PhD Student BNP Lab - Neurology Department University Hospital Tübingen Eberhard Karls University Tübingen Hoppe-Seyler Str. 3 D-72076 Tübingen Tel: +49 7071/29 80478 -------------- next part -------------- An HTML attachment was scrubbed... URL: From icelandhouse at gmail.com Mon Apr 18 10:45:33 2016 From: icelandhouse at gmail.com (Maris Skujevskis) Date: Mon, 18 Apr 2016 10:45:33 +0200 Subject: [FieldTrip] fieldtrip Digest, Vol 65, Issue 14 In-Reply-To: References: Message-ID: Dear Fieldtrip users, When constructing an EEG forward model, the function ft_prepare_sourcemodel has an option cfg.inwardshift. When plotting the grid of the source model over the brain volume, I get the following differences between a negative and a zero inwardshift (skull and scalp layers not shown): https://drive.google.com/file/d/0B9QSyDy3RhMIUkdxaHBPV2FtODg/view?usp=sharing >From this I conclude that a negative inward shift means that grid points that in reality are outside the brain get treated as inside the brain in the source model. Based on this observation, I have two questions: a) why could a shift be necessary? -- naively, it doesn't make sense that a grid point needs to be labeled as being in the brain when it actually is outside. b) how can a shift be justified? -- it seems that the outer grid points that get labeled as 'inside' due to the shift would have incorrect conductivity values when the leadfield matrix is calculated. This would be the case because in the volume conduction model the coordinates of those points correspond to the skull and not to the brain tissue. Any explanations/corrections of the above outline of what cfg.inwardshift does will be highly appreciated, Maris. On Sat, Apr 16, 2016 at 12:00 PM, wrote: > Send fieldtrip mailing list submissions to > fieldtrip at science.ru.nl > > To subscribe or unsubscribe via the World Wide Web, visit > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > or, via email, send a message with subject or body 'help' to > fieldtrip-request at science.ru.nl > > You can reach the person managing the list at > fieldtrip-owner at science.ru.nl > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of fieldtrip digest..." > > > Today's Topics: > > 1. Re: TFR mask stats question; Baselined vs unbaselined > statistics question (Max Cantor) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Fri, 15 Apr 2016 13:48:38 -0600 > From: Max Cantor > To: FieldTrip discussion list > Subject: Re: [FieldTrip] TFR mask stats question; Baselined vs > unbaselined statistics question > Message-ID: > < > CAOv1Hy1VumqCGBuzCpTOo7KPLDfTPXMGMoWVrhzbO2+cvqjRdQ at mail.gmail.com> > Content-Type: text/plain; charset="utf-8" > > As a followup, I'd like to note that there was a mistake in the multiplot > code in my prior post (I had in that code 1,3,5 instead of 1,2,3 as my > indices for the stat cell array), and the comment for zlim was not relevant > (that was for when I was plotting powspctrm, since the data were > freqbaselined). > > Since the time I posted this, I've tried a few more things that have been > somewhat successful. I have set frequency to [1 30], because gamma seemed > to be very noisy and the data were bandpass filtered at [0.1 50]hz in the > first place so I figured there would be no meaningful effect as high as > 50hz. I have also played with the latency, testing a priori assumptions of > the time window, as well as a general [0 1.8] window for TFR (and [0 1] > window for ERP). > > Finally, I have tried the analyses using the nonparametric permutation > test, but without the cluster correction (and setting cfg.alpha to 0.05 as > opposed to 0.025, for the cluster statistics). When I do just the > permutation test, I get the effects that I was anticipating in both ERP and > TFR. It's only when I add in the cluster correction that I get no > significant effects. > > Does anyone have an idea as to why this might be happening? > > Best, > > Max > > On Fri, Apr 8, 2016 at 3:02 PM, Max Cantor > wrote: > > > Hi fieldtrippers, > > > > I have two unrelated stats questions, but I figured I'd post them > together: > > > > 1. I've run within subjects permutation statistics testing the difference > > between an anomaly and control condition for three different language > > conditions; preposition, morphosyntax, and semantics. The code is nearly > > identical for both my ERPs and TFRs, except that when I plot my ERPs with > > cfg.maskparameter = 'mask', cfg.parameter = 'stat', and cfg.maskalpha = > > 0.025, it seems to multiplot just fine, whereas when I try to do the same > > for the TFRs, my multiplotted plots are blank, but when I comment out the > > mask, the stat plots are fine. I'll attach the code, but is there > something > > I'm doing obviously wrong? Also, am I correct that my maskalpha should > > correspond to my alpha, and not my cluster alpha? > > > > This is the TFR code, but the ERP code is the exact same except for with > > timelocked data as the input and ft_timelockstatistics as the function. > > > > cfg = []; > > cfg.method = 'montecarlo'; > > cfg.statistic = 'depsamplesT'; > > cfg.correctm = 'cluster'; > > cfg.clusteralpha = 0.05; > > cfg.clusterstatistic = 'maxsum'; > > cfg.minnbchan = 2; > > cfg.neighbours = neighbours; > > cfg.tail = 0; > > cfg.clustertail = 0; > > cfg.alpha = 0.025; > > cfg.numrandomization = 1000; > > > > nsubj = length(tot_tfr2_bl{1}); > > design = zeros(2,2*nsubj); > > for i = 1:nsubj > > design(1,i) = i; > > end > > for i = 1:nsubj > > design(1,nsubj+i) = i; > > end > > design(2,1:nsubj) = 1; > > design(2,nsubj+1:2*nsubj) = 2; > > > > cfg.design = design; > > cfg.uvar = 1; > > cfg.ivar = 2; > > > > % Anomaly vs Control > > stat_tfr{1} = ft_freqstatistics(cfg, tot_tfr2_bl{1}{:}, > > tot_tfr2_bl{2}{:}); % Preposition > > stat_tfr{2} = ft_freqstatistics(cfg, tot_tfr2_bl{3}{:}, > > tot_tfr2_bl{4}{:}); % Semantics > > stat_tfr{3} = ft_freqstatistics(cfg, tot_tfr2_bl{5}{:}, > > tot_tfr2_bl{6}{:}); % Morphosyntax > > > > This is the plotting code. Again, it is virtually the same for the ERPs > > except the non-stats configurations would be what makes sense for ERPs. > > > > % Anomaly vs Control TFR stats multiplot > > > > cfg = []; > > cfg.xlim = [-0.2 1]; > > cfg.zlim = [-3 3]; % proportion from baseline > > cfg.layout = [max_dir '/quickcap64.mat']; > > cfg.maskparameter = 'mask'; > > cfg.parameter = 'stat'; > > cfg.maskalpha = 0.025; > > > > ft_multiplotTFR(cfg, stat_tfr{1}); title('Preposition'); > > ft_multiplotTFR(cfg, stat_tfr{3}); title('Semantic'); > > ft_multiplotTFR(cfg, stat_tfr{5}); title('Morphosyntactic'); > > > > > > 2. The second question is about analyzing baselined vs unbaselined data. > > I've seen in the tutorials that there is a somewhat different method for > > analyzing trial vs baseline period. However, what I've done instead (for > > both ERP and TFR), is use the same within-subjects statistics as with > > anomaly vs control, except with the inputs being baselined vs unbaselined > > ERPs or TFRs, e.g. Baselined Preposition Anomaly vs Unbaselined > Preposition > > Anomaly, etc. I understand that the proposed method and my method are not > > testing the same thing exactly, but is this a reasonable way of testing > the > > effect of the baselining anyway? > > > > Thanks, > > > > Max > > > > -- > > Max Cantor > > Graduate Student > > Cognitive Neuroscience of Language Lab > > University of Colorado Boulder > > > > > > -- > Max Cantor > Graduate Student > Cognitive Neuroscience of Language Lab > University of Colorado Boulder > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: < > http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160415/4cd234cd/attachment-0001.html > > > > ------------------------------ > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > End of fieldtrip Digest, Vol 65, Issue 14 > ***************************************** > -------------- next part -------------- An HTML attachment was scrubbed... URL: From seymourr at aston.ac.uk Mon Apr 18 11:13:29 2016 From: seymourr at aston.ac.uk (Seymour, Robert (Research Student)) Date: Mon, 18 Apr 2016 09:13:29 +0000 Subject: [FieldTrip] Recombining Trials for Source Analysis Message-ID: Dear Fieldtrippers, I am trying to use an LCMV beamformer to project 5 minutes of resting state data to the source level. During my data cleaning procedure I segment my continuous recording into 1 second "trials" and reject those with high amplitudes (using the ft_rejectvisual summary window). However I would then like to recombine these "trials" (to make 1 long "trial") before I do ft_timelockanalysis. Is there a way to do this whilst keeping the Fieldtrip structure intact . My current code is below: % Segment into 1s chunks. Input is preprocessed variable called data. cfg = []; cfg.length = 1; cfg.overlap = 0; data_segmented = ft_redefinetrial(cfg,data); % Reject deviant trials cfg = []; cfg.method = 'summary'; cfg.keepchannel = 'yes'; cfg.channel = 'MEGMAG'; clean1 = ft_rejectvisual(cfg,data_segmented); % Now load this cfg.channel = 'MEGGRAD'; clean2 = ft_rejectvisual(cfg,clean1); data_clean_rs = clean2 clear clean1 clean2 save data_clean_rs data_clean_rs % Now to recombine trials data_clean_rs.trial = horzcat(data_clean_rs.trial{1,:}); % (This distorts the fieldtrip structure meaning ft_timelockanalysis doesn't work) Many thanks, Robert -------------- next part -------------- An HTML attachment was scrubbed... URL: From magazzinil at gmail.com Mon Apr 18 11:24:48 2016 From: magazzinil at gmail.com (Lorenzo Magazzini) Date: Mon, 18 Apr 2016 10:24:48 +0100 Subject: [FieldTrip] Recombining Trials for Source Analysis In-Reply-To: References: Message-ID: Hi Robert, I'm not sure, but my guess would be that you need to adjust the .time field in your data_clean_rs structure, so that it matches the length of the .trial field. Best wishes, Lorenzo Lorenzo Magazzini PhD Student magazzinil at cardiff.ac.uk CUBRIC Building Maindy Road Cardiff CF24 4HQ On 18 April 2016 at 10:13, Seymour, Robert (Research Student) < seymourr at aston.ac.uk> wrote: > Dear Fieldtrippers, > > > I am trying to use an LCMV beamformer to project 5 minutes of resting > state data to the source level. During my data cleaning procedure I segment > my continuous recording into 1 second "trials" and reject those with high > amplitudes (using the ft_rejectvisual summary window). However I would then > like to recombine these "trials" (to make 1 long "trial") before I do > ft_timelockanalysis. Is there a way to do this whilst keeping the Fieldtrip > structure intact . My current code is below: > > > % Segment into 1s chunks. Input is preprocessed variable called data. > > cfg = []; > > cfg.length = 1; > > cfg.overlap = 0; > > data_segmented = ft_redefinetrial(cfg,data); > > > % Reject deviant trials > > cfg = []; > > cfg.method = 'summary'; > > cfg.keepchannel = 'yes'; > > cfg.channel = 'MEGMAG'; > > clean1 = ft_rejectvisual(cfg,data_segmented); > > % Now load this > > cfg.channel = 'MEGGRAD'; > > clean2 = ft_rejectvisual(cfg,clean1); > > data_clean_rs = clean2 > > > clear clean1 clean2 > > save data_clean_rs data_clean_rs > > > % Now to recombine trials > > data_clean_rs.trial = horzcat(data_clean_rs.trial{1,:}); % (This distorts > the fieldtrip structure meaning ft_timelockanalysis doesn't work) > > > > Many thanks, > > > Robert > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From mi_mayer at gmx.de Tue Apr 19 20:07:09 2016 From: mi_mayer at gmx.de (Irene Sophia Mayer) Date: Tue, 19 Apr 2016 20:07:09 +0200 Subject: [FieldTrip] ft_channelrepair: index exceeds matrix dimensions Message-ID: An HTML attachment was scrubbed... URL: From XDu at mprc.umaryland.edu Tue Apr 19 20:38:10 2016 From: XDu at mprc.umaryland.edu (Xiaoming Du) Date: Tue, 19 Apr 2016 14:38:10 -0400 Subject: [FieldTrip] ft_channelrepair: index exceeds matrix dimensions In-Reply-To: References: Message-ID: <571642D3020000DC0001A139@MPRC.UMARYLAND.EDU> Hello, I am not a fieldtrip expert, but I happen to use ft_channelrepair recently. In you code, does the 'data' have FT9 or CP6? Are those electrodes missing or bad? If you construct neighbours based on less number of electrodes, you may still lack the neighbour-info to interpolate them. I suggest to check the dimension of neighbours and see if it contains the neighbours info for all electrodes (especially for FT9 and CP6). Also, you can try cfg.missingchannel instead of cfg.badchannel and see if that helps. p.s., in my case, I used a good data (meaning without missing or bad channels) to create the neighbours and use it for all others dataset with same type of EEG caps. Best, Xiaoming >>> "Irene Sophia Mayer" 4/19/2016 2:07 PM >>> Dear fieldtrippers, When trying to repair bad channels, I get the following error message: Index exceeds matrix dimensions. Error in ft_channelrepair (line 177) goodsensindx = a(b); Error in prepro_neu (line 129) data = ft_channelrepair(cfg,data); This seems to happen for specific channels, e.g. 'FT9' and 'CP6', but the script works fine, if I don't try to interpolate those channels. Any ideas what the problem could be? My code: cfg = []; cfg.method = 'template'; cfg.layout = 'EEG1010.lay'; cfg.feedback = 'yes'; neighbours = ft_prepare_neighbours(cfg,data); cfg = []; cfg.method = 'average'; % 'nearest', 'average', 'spline' or 'slap' (default='nearest') cfg.badchannel = bad_chan{x}; % predefined list of channels cfg.elec = ft_read_sens('path'); cfg.neighbours = neighbours; cfg.trials = 'all'; cfg.lambda = 1e-5; cfg.order = 4; data = ft_channelrepair(cfg,data); -------------- next part -------------- An HTML attachment was scrubbed... URL: From anne.urai at gmail.com Wed Apr 20 08:19:44 2016 From: anne.urai at gmail.com (Anne Urai) Date: Wed, 20 Apr 2016 08:19:44 +0200 Subject: [FieldTrip] ft_megrealign - complete CTF275 grad struct wanted Message-ID: Dear Fieldtrippers, tl;dr 1. I'm looking for a gradiometer structure that includes coils (so a subject or dummy measurement) with *all* squids present.  2. Can I rename the CTF HLC0011 etc... to {'nasX';'nasY';'nasZ';'lpaX';'lpaY';'lpaZ';'rpaX';'rpaY';'rpaZ'}? --------- 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.  After making the headmodel (and ensuring it's aligned with the gradiometers), this works quite well: % realign to template sensor positions cfg             = []; cfg.template    = {'ctf275.mat'};  cfg.headmodel   = headmodel;   % For a realistic single-shell volume conduction model based on the brain surface, you % should probably use an inward shift of about 1 cm. cfg.inwardshift  = 1; cfg.feedback     = 'no'; data2            = ft_megrealign(cfg, data); 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 ftp://ftp.fieldtriptoolbox.org/pub/fieldtrip/example/megrealign, 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. 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. 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.  In ft_headmovement (and also buried somewhere in the CTF documentation), I could find % HLC0011 HLC0012 HLC0013 x, y, z coordinates of nasion-coil in m. % HLC0021 HLC0022 HLC0023 x, y, z coordinates of lpa-coil in m. % HLC0031 HLC0032 HLC0033 x, y, z coordinates of rpa-coil in m. 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.  Thanks! —  Anne E. Urai, MSc PhD student | Institut für Neurophysiologie und Pathophysiologie  Universitätsklinikum Hamburg-Eppendorf | Martinistrasse 52, 20246 | Hamburg, Germany  www.anneurai.net / @AnneEUrai -------------- next part -------------- An HTML attachment was scrubbed... URL: From mi_mayer at gmx.de Wed Apr 20 09:07:15 2016 From: mi_mayer at gmx.de (Irene Sophia Mayer) Date: Wed, 20 Apr 2016 09:07:15 +0200 Subject: [FieldTrip] ft_channelrepair: index exceeds matrix dimensions In-Reply-To: <571642D3020000DC0001A139@MPRC.UMARYLAND.EDU> References: , <571642D3020000DC0001A139@MPRC.UMARYLAND.EDU> Message-ID: An HTML attachment was scrubbed... URL: From XDu at mprc.umaryland.edu Wed Apr 20 11:19:23 2016 From: XDu at mprc.umaryland.edu (Xiaoming Du) Date: Wed, 20 Apr 2016 05:19:23 -0400 Subject: [FieldTrip] ft_channelrepair: index exceeds matrix dimensions In-Reply-To: References: , <571642D3020000DC0001A139@MPRC.UMARYLAND.EDU> Message-ID: <5717115B020000DC0001A158@MPRC.UMARYLAND.EDU> Hi Irene, Here is the code I used: cfg = []; cfg.method = 'triangulation' cfg.senstype = 'EEG' neighbours_66 = ft_prepare_neighbours(cfg, data_intact); cfg = []; cfg.method = 'average'; cfg.neighbours = neighbours_66; cfg.missingchannel = missingChann; cfg.senstype = 'EEG'; data_clean = ft_channelrepair(cfg, data); Here is an example from Fieldtrip website http://www.fieldtriptoolbox.org/tutorial/natmeg/timefrequency?s[]=ft&s[]=channelrepair Regards, Xiaoming >>> "Irene Sophia Mayer" 4/20/2016 3:07 AM >>> Hello, The data does always have those channels, they are bad and not missing. All electrodes have neighbours assigned to them and I'm doing this on the original data without having changed anything before that. Did you use the same code as I did? Best, Irene Gesendet: Dienstag, 19. April 2016 um 20:38 Uhr Von: "Xiaoming Du" An: fieldtrip at science.ru.nl Betreff: Re: [FieldTrip] ft_channelrepair: index exceeds matrix dimensions Hello, I am not a fieldtrip expert, but I happen to use ft_channelrepair recently. In you code, does the 'data' have FT9 or CP6? Are those electrodes missing or bad? If you construct neighbours based on less number of electrodes, you may still lack the neighbour-info to interpolate them. I suggest to check the dimension of neighbours and see if it contains the neighbours info for all electrodes (especially for FT9 and CP6). Also, you can try cfg.missingchannel instead of cfg.badchannel and see if that helps. p.s., in my case, I used a good data (meaning without missing or bad channels) to create the neighbours and use it for all others dataset with same type of EEG caps. Best, Xiaoming >>> "Irene Sophia Mayer" 4/19/2016 2:07 PM >>> Dear fieldtrippers, When trying to repair bad channels, I get the following error message: Index exceeds matrix dimensions. Error in ft_channelrepair (line 177) goodsensindx = a(b); Error in prepro_neu (line 129) data = ft_channelrepair(cfg,data); This seems to happen for specific channels, e.g. 'FT9' and 'CP6', but the script works fine, if I don't try to interpolate those channels. Any ideas what the problem could be? My code: cfg = []; cfg.method = 'template'; cfg.layout = 'EEG1010.lay'; cfg.feedback = 'yes'; neighbours = ft_prepare_neighbours(cfg,data); cfg = []; cfg.method = 'average'; % 'nearest', 'average', 'spline' or 'slap' (default='nearest') cfg.badchannel = bad_chan{x}; % predefined list of channels cfg.elec = ft_read_sens('path'); cfg.neighbours = neighbours; cfg.trials = 'all'; cfg.lambda = 1e-5; cfg.order = 4; data = ft_channelrepair(cfg,data); _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From elmeri.syrjanen at gmail.com Wed Apr 20 14:05:20 2016 From: elmeri.syrjanen at gmail.com (=?UTF-8?Q?Elmeri_Syrj=C3=A4nen?=) Date: Wed, 20 Apr 2016 14:05:20 +0200 Subject: [FieldTrip] Plotting combining figures Message-ID: Dear all, I'am trying to build a figure in Matlab composed of multiple elements. For example I would like to have a upper part of the figure with mean amplitudes and CIs. The lower part of the figure would be composed of the output from ft_singleplotER and ft_clusterplot. Is this possible? So far i tried various combinations of the set(), hold and subplot() commands in Matlab. I suspect that the problem arises from that FieldTrip creates a new figure each time one of the plotting functions are called. Is there a handle to the figure that is created? It would be great if this would be possible. The advantage is obvious if it's possible to build the complete figure in Matlab with consistent font sizes etc. /elmeri -------------- next part -------------- An HTML attachment was scrubbed... URL: From fosco.bernasconi at gmail.com Wed Apr 20 14:53:32 2016 From: fosco.bernasconi at gmail.com (fosco bernasconi) Date: Wed, 20 Apr 2016 14:53:32 +0200 Subject: [FieldTrip] ft_sourceplot NaN, connectivity degree Message-ID: Dear list, I am trig to plot the connectivity degree of my beamforming sources, after interpolation. What happens, is that also the NaN values outside the headmodel are plotted (see figure below). Is there an easy fix for this? or did I do some errors in my computation? My code: cfg = []; cfg.method = 'ortho'; cfg.funparameter = 'degrees'; cfg.maskparameter = 'mask'; cfg.funcolormap = 'jet'; cfg.location = 'max'; ft_sourceplot(cfg,source_degint_S); and my data structure: source_degint_S = anatomy: [91x109x91 double] coordsys: 'spm' dim: [91 109 91] transform: [4x4 double] unit: 'mm' inside: [91x109x91 logical] degrees: [91x109x91 double] cfg: [1x1 struct] Thanks a lot in advance! fosco [image: Immagine incorporata 2] -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: Screenshot from 2016-04-20 13:38:28.png Type: image/png Size: 74696 bytes Desc: not available URL: From icelandhouse at gmail.com Wed Apr 20 17:11:24 2016 From: icelandhouse at gmail.com (Maris Skujevskis) Date: Wed, 20 Apr 2016 17:11:24 +0200 Subject: [FieldTrip] why are grid points located outside the brain? Message-ID: Dear Fieldtrip users, Can someone please explain the reason why in the tutorial http://www.fieldtriptoolbox.org/tutorial/sourcemodel (or in general, for that matter) the outer layer of grid points of the source model lie outside the brain though they are defined as being inside? This is what I am refering to: http://www.fieldtriptoolbox.org/_detail/example/mnispace/mni_fig1a.png?id=tutorial%3Asourcemodel http://www.fieldtriptoolbox.org/_detail/example/mnispace/mni_fig2b.png?id=tutorial%3Asourcemodel According to my naive understanding, this means that in this model the potential neural sources may also lie outside the brain, which makes no sense. Clearly, I am missing something here... Thanks! Maris -------------- next part -------------- An HTML attachment was scrubbed... URL: From nicholas.balderston at nih.gov Wed Apr 20 23:27:00 2016 From: nicholas.balderston at nih.gov (Balderston, Nicholas (NIH/NIMH) [F]) Date: Wed, 20 Apr 2016 21:27:00 +0000 Subject: [FieldTrip] why are grid points located outside the brain? In-Reply-To: References: Message-ID: Dear all, Thanks for the question Maris, I have been wondering the same. Along those lines, I was wondering if it is appropriate to scale the resulting beamformer grids to match the size of the MNI template after the fact? thanks, -nick ________________________________ From: Maris Skujevskis [icelandhouse at gmail.com] Sent: Wednesday, April 20, 2016 11:11 AM To: fieldtrip at science.ru.nl Subject: [FieldTrip] why are grid points located outside the brain? Dear Fieldtrip users, Can someone please explain the reason why in the tutorial http://www.fieldtriptoolbox.org/tutorial/sourcemodel (or in general, for that matter) the outer layer of grid points of the source model lie outside the brain though they are defined as being inside? This is what I am refering to: http://www.fieldtriptoolbox.org/_detail/example/mnispace/mni_fig1a.png?id=tutorial%3Asourcemodel http://www.fieldtriptoolbox.org/_detail/example/mnispace/mni_fig2b.png?id=tutorial%3Asourcemodel According to my naive understanding, this means that in this model the potential neural sources may also lie outside the brain, which makes no sense. Clearly, I am missing something here... Thanks! Maris -------------- next part -------------- An HTML attachment was scrubbed... URL: From muthuraman10 at hotmail.com Fri Apr 22 14:19:33 2016 From: muthuraman10 at hotmail.com (Muthuraman Muthuraman) Date: Fri, 22 Apr 2016 12:19:33 +0000 Subject: [FieldTrip] PhD Position on Brian Imaging in Multiple Sclerosis! Message-ID: Doctoral Student Neuroscientist with focus on brain imaging in multiple sclerosis diagnosis The medical faculty of the University of Mainz, Germany, invites applications for a PhD Student for a functional translational neuroscience (FTN) scholarship three year position to work on the Multiple sclerosis imaging with modalities like structural MRI, diffusion tensor imaging, functional magnetic resonance imaging and Electro encephalography (EEG). The successful applicant holds a Master’s degree (or equivalent) in a relevant academic area such as basic life sciences, neuropsychology, applied mathematics, computer science or biomedical engineering or similar disciplines. The working language at the institute is English. Experience with brain imaging and the analysis of brain signals is advantageous, but not essential. The applicant’s merits are assessed on the basis of the quality of Master’s level studies and thesis, previous experience with the brain imaging, motivation and research interests. The location for this research will mainly be the workgroups “Section of movement disorders, neurostimulation and neuroimaging“ of Prof. Sergiu Groppa at the Department of Neurology and “Multimodal signal processing and statistical analyses” of Prof. Muthuraman Muthuraman, both at the Focus Program Translational Neurosciences (http://www.ftn.uni-mainz.de/) and Neuroimaging Centre Mainz (http://www.ftn.nic.uni-mainz.de/). Expected close collaborations with national and international partners. The application should include a statement of research interests and reasons for applying to the project, a curriculum vitae (max. 4 pages) composed according to good scientific practice, a certificate of Master’s degree, copy of the master’s thesis and grades of Master’s level studies, the names and e-mail addresses of two referees and a proof of proficiency in English. The position will be open until filled. To apply for the position, please send the above documents as pdfs until 15.05.2016 to Prof. Sergiu Groppa, Department of Neurology, Section of movement disorders and neurostimulation, University of Mainz, Langenbeckstrasse 1, 55131 Mainz, Germany, or by Email to segroppa(at)uni-mainz.de. For additional information please contact Sergiu Groppa. -------------- next part -------------- An HTML attachment was scrubbed... URL: From 9605 at eng.asu.edu.eg Fri Apr 22 16:52:36 2016 From: 9605 at eng.asu.edu.eg (Mina Romany Meshriky) Date: Fri, 22 Apr 2016 14:52:36 +0000 Subject: [FieldTrip] FW: From a .csv data file, to a recognized dataset by fieldtrip In-Reply-To: <006c01d19ca6$65683f50$3038bdf0$@gmail.com> References: <006c01d19ca6$65683f50$3038bdf0$@gmail.com> Message-ID: Dears, My name is Mina, and I am working with event related potentials. I think my question is somehow basic but, it's been a day and I am still stuck. I am working with the Emotiv Epoc device, and I am using Labview and Matlab for real time acquisition and processing. Until recently I was using my own functions to read and process the data, however now I would like to use the fieldtrip toolbox. When I receive data from the device using Labview I store it directly to a .csv file and then start the processing on Matlab I would like to change this .csv file to a format recognized by field trip What I have separately now is 1- The data 2- The channel names 3- The channel locations 4- The markers 5- The sampling frequency Best Regards Mina Meshriky -------------- next part -------------- An HTML attachment was scrubbed... URL: From WILLIAM.DEWISPELAERE at UCDENVER.EDU Fri Apr 22 18:27:11 2016 From: WILLIAM.DEWISPELAERE at UCDENVER.EDU (Dewispelaere, William B) Date: Fri, 22 Apr 2016 16:27:11 +0000 Subject: [FieldTrip] ft_sourceinterpolate and ft_sourcestatistics outputs Message-ID: Hey all, I have a few questions about the output that results from ft_sourceinterpolate and ft_sourcestatistics. For some background, I ran ft_sourcestatistics on un-interpolated data in order to save some memory space. I then interpolated this stat output onto my realigned and resliced anatomical MRI. Everything looks alright, I just want to know: 1) Positive vs negative clusters - I'm assuming positive clusters are where condition 1 (as defined in the design matrix) is greater than condition 2 (I only have 2 conditions). Correct me if I'm wrong! 2) The 'prob' field - Before I interpolate my ft_sourcestatistics output, the 'prob' field contains the p-values for each voxel. After interpolation, I'm not sure what the 'prob' field is, since the values range from above 1 to below -1. If someone could clarify the meaning of these values, that would make my day. Thanks! Will -------------- next part -------------- An HTML attachment was scrubbed... URL: From laxmi.shaw22 at gmail.com Fri Apr 22 19:05:40 2016 From: laxmi.shaw22 at gmail.com (Laxmi Shaw) Date: Fri, 22 Apr 2016 22:35:40 +0530 Subject: [FieldTrip] Fieldtrip_issues Message-ID: Dear list, I am having an situation . I am having data in excels file which i have converted to.mat file. The file content as each columns indicates number of channels and the data points are indicates the corresponding amplitude. I want to use ft_topoplotER and ft_clusterplot,for that i need to convert .mat to structure file . How can i use topoplot in that way. Could you please help me in this regard. Thanks and Regards -- Laxmi Shaw Research Scholar(PhD) IIT Kharagpur West Bengal Ph no-08388837821 -------------- next part -------------- An HTML attachment was scrubbed... URL: From dlozanosoldevilla at gmail.com Fri Apr 22 19:27:38 2016 From: dlozanosoldevilla at gmail.com (Diego Lozano-Soldevilla) Date: Fri, 22 Apr 2016 19:27:38 +0200 Subject: [FieldTrip] Fieldtrip_issues In-Reply-To: References: Message-ID: Dear Laxmi, These two pages should definitely help you: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat http://www.fieldtriptoolbox.org/getting_started best, Diego On 22 April 2016 at 19:05, Laxmi Shaw wrote: > Dear list, > I am having an situation . I am having data in excels file which i have > converted to.mat file. The file content as each columns indicates number of > channels and the data points are indicates the corresponding amplitude. I > want to use ft_topoplotER and ft_clusterplot,for that i need to convert > .mat to structure file . How can i use topoplot in that way. Could you > please help me in this regard. > > > > > Thanks and Regards > > -- > Laxmi Shaw > Research Scholar(PhD) > IIT Kharagpur > West Bengal > Ph no-08388837821 > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From gaur-p at email.ulster.ac.uk Fri Apr 22 19:34:09 2016 From: gaur-p at email.ulster.ac.uk (Pramod Gaur) Date: Fri, 22 Apr 2016 18:34:09 +0100 Subject: [FieldTrip] Fieldtrip_issues In-Reply-To: References: Message-ID: <2099a01d19cbd$2f7b3250$8e7196f0$@email.ulster.ac.uk> Dear Users, I am newbie to fieldtrip and just wanted to analyse BCI competition IV datasets. I have seen many format are mentioned but nothing is given for GDF format. Could you please help me and point me to the correct link, so I can start working on EEG data. Best regards, Pramod From: fieldtrip-bounces at science.ru.nl [mailto:fieldtrip-bounces at science.ru.nl] On Behalf Of Diego Lozano-Soldevilla Sent: 22 April 2016 18:28 To: FieldTrip discussion list Subject: Re: [FieldTrip] Fieldtrip_issues Dear Laxmi, These two pages should definitely help you: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat http://www.fieldtriptoolbox.org/getting_started best, Diego On 22 April 2016 at 19:05, Laxmi Shaw > wrote: Dear list, I am having an situation . I am having data in excels file which i have converted to.mat file. The file content as each columns indicates number of channels and the data points are indicates the corresponding amplitude. I want to use ft_topoplotER and ft_clusterplot,for that i need to convert .mat to structure file . How can i use topoplot in that way. Could you please help me in this regard. Thanks and Regards -- Laxmi Shaw Research Scholar(PhD) IIT Kharagpur West Bengal Ph no-08388837821 _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From sauer.mpih at googlemail.com Sun Apr 24 18:36:06 2016 From: sauer.mpih at googlemail.com (Andreas Sauer) Date: Sun, 24 Apr 2016 18:36:06 +0200 Subject: [FieldTrip] Why does ft_selectdata remove "pow" from sourcedata during statistics? Message-ID: Dear all, unfortunately, I am having problems to run source statistics on ERF mismatch negativity data (recorded with a 4D system). With the following data structure as input (output from ft_sourcegrandaverage), fieldtrip gives a warning that it „could not determine dimord of „pow“ in the following data“ pow: [16x37696 double] dim: [31 38 32] inside: [37696x1 logical] pos: [37696x3 double] time: [1x900 double] cfg: [1x1 struct] and later throws an error that „field „pow“ (is) not present in data“. I checked the ft_sourcestatistic script step by step and found out that ft_selectdata removes it after being called by ft_sourcestatistics. I am using the fieldtrip version from 15/05/2015. I also tried with older versions, one from late 2014 and late 2013, but nothing worked. Unfortunately, since ft_selectdata removes the field "pow" from the data during the call to ft_sourcestatistic, I can’t put it back in to the structure. Any help with this (esp. why „pow“ is being removed) is highly appreciated! Thanks and best wishes, Andreas -- Dipl.-Psych. Andreas Sauer Max Planck Institute for Brain Research Deutschordenstraße 46 60528 Frankfurt am Main Germany T: +49 69 96769 278 F: +49 69 96769 327 Email: sauer.mpih at gmail.com www.brain.mpg.de -------------- next part -------------- An HTML attachment was scrubbed... URL: From pantev at uni-muenster.de Mon Apr 25 11:18:51 2016 From: pantev at uni-muenster.de (Christo Pantev) Date: Mon, 25 Apr 2016 11:18:51 +0200 Subject: [FieldTrip] Full Professor (W3 Position) for Biomagnetism and Biosignalanalysis with focus on Magnetoencephalography and Multimodal Imaging of Neural Systems Message-ID: Dear colleagues, The Medical Faculty of the University of Münster offers the position of a Full Professor (W3) for "Biomagnetism and Biosignalanalysis with focus on Magnetoencephalography and Multimodal Imaging of Neural Systems” at the nearest possible time. The Institute for Biomagnetism and Biosignalanalysis of the University of Münster has an excellent structure and it is “state-of-the art” equipped. Therefore I would like to encourage all qualified colleagues to apply. Furthermore, Münster is a wonderful city to live! The Medical Faculty of the University of Münster offers the position of a Full Professor (W3) for Biomagnetism and Biosignalanalysis with focus on Magnetoencephalography and Multimodal Imaging of Neural Systems at the nearest possible time. The position is an appointment as a Head of the Institute for Biomagnestism and Biosignalanalysis at the Medical Faculty Münster. The holder of this position-to-be (she/he) should have the ability to represent the discipline entirely in research and teaching as well. The candidates should have medical or natural science training and an outstanding qualification in scientific research and teaching. An internationally recognized research profile in application of Magnetoencephalography and other Neuroimaging-Methods in particular EEG, MRI/fMRI, TMS/tDCS, PET are expected. Beside the ability to formulate and solve theoretical and analytical tasks, a successful cooperation with the clinical neuro-scientific research field of the Faculty is presumed. The active collaboration with the scientific main topic oft the faculty “Neural Systems” is explicitly required. Further important criteria are excellent research- and publication-records. Likewise, convincing experience in modern scientific management, particularly in raising of national and international scientific funds, ability for collaboration, interdisciplinarity, and administrative and social competence are requirements for application. The scientific networking and close cooperation with adjacent disciplines are expected. The Medical Faculty anticipates a collaboration with existing research foci and research associations e.g. the excellence cluster “Cells in motion” (EXC 1003), the interdisciplinary clinical research center (IZKF), the center for clinical studies (ZKS), the existing research associations (SFB) and the MPI “Molecular biomedicine”. Prerequisites for the application are scientific achievements, which have been yielded within Junior-Professorship, Habilitation, or scientific work at university or non-university institutions. We point additionally on the required qualification given in § 36 of the Hochschulgesetz. The University of Münster is an equal opportunity employer and is committed to increasing the proportion of senior female academics. Consequently, we actively encourage applications by women. Female candidates with equivalent qualifications and academic achievements will be preferentially considered within the framework of the legal possibilities. We also welcome applications from candidates with severe disabilities. Disabled candidates with equivalent qualifications will be preferentially considered. Applications including the standard documents (CV, scientific career, structured publication list, raised funds) inclusively the summary of the teaching accomplishments with detailed and profound teaching concept together with reprints of the six most important publications should be submitted to the Dean of the Medical Faculty, Westfälische Wilhelms-Universität Münster, Albert-Schweitzer-Campus 1, Gebäude D3, 48149 Münster, by 27.05.2016. Please take into account the hints about Professorial Nominations at our website: www.campus.uni-muenster.de . Best regards --- Univ.-Prof. Dr. Christo Pantev Direktor des Instituts für Biomagnetismus und Biosignalanalyse WWU Münster Adjunct Professor Rotman Research Institute for Neuroscience University of Toronto, Canada Malmedyweg 15 D-48149 Münster Telefon: +49 (0)251 83 56865 (56885) fax: +49 (0)251 83 56874 E-Mail: pantev at uni-muenster.de http://biomag.uni-muenster.de -------------- next part -------------- An HTML attachment was scrubbed... URL: From j.brehm at uu.nl Mon Apr 25 15:55:53 2016 From: j.brehm at uu.nl (Brehm, J. (Julia)) Date: Mon, 25 Apr 2016 13:55:53 +0000 Subject: [FieldTrip] Problems with filterpadding in ft_artifact_zvalue Message-ID: <385DDA785CF9764B8E184EF28D01ADE05995E2@WP0046.soliscom.uu.nl> Dear list, I am currently working on implementing an automatic artifact rejection using ft_artifact_zvalue. It already works quite nicely for detecting jumps and EOG artifacts. However, when trying to detect high frequency noise I am often getting edge effects. I am already using filterpadding for the eog artifacts were it does a good job, but for the higher frequencies it suddenly almost only detects artifacts at the outermost trials (first and last) even though there are also obvious artifacts in different trials. The data is previously demeaned and filtered using a notch filter and a bandpass filter from 1-100 Hz. These are my settings for the artifact detection now: cfg = []; cfg.trl = temptrl; % all trials in this case cfg.artfctdef.zvalue.channel = channel{ch}; % single channel cfg.artfctdef.zvalue.cutoff = 3; cfg.artfctdef.zvalue.fltpadding = 0.1; cfg.artfctdef.zvalue.bpfilter = 'yes'; cfg.artfctdef.zvalue.bpfilttype = 'but'; cfg.artfctdef.zvalue.bpfreq = [70 100]; cfg.artfctdef.zvalue.bpfiltord = 2; cfg.artfctdef.zvalue.hilbert = 'yes'; cfg.artfctdef.zvalue.boxcar = 0.2; [cfg, artifact] = ft_artifact_zvalue(cfg, data); I already tried changing the settings around but that didn't do much good. Any help would be appreciated and please tell me if I am doing anything terribly wrong! Best, Julia -------------- next part -------------- An HTML attachment was scrubbed... URL: From icelandhouse at gmail.com Mon Apr 25 23:51:34 2016 From: icelandhouse at gmail.com (Maris Skujevskis) Date: Mon, 25 Apr 2016 23:51:34 +0200 Subject: [FieldTrip] transformation matrix Message-ID: Dear Fieldtrip users, A quick simple question (maybe it's been answered somewhere already but really I cannot find it...) Functions like ft_read_mri and ft_volumerealign attach the field 'transform' (a 4 x 4 matrix) to the data structure ( http://www.fieldtriptoolbox.org/faq/how_to_coregister_an_anatomical_mri_with_the_gradiometer_or_electrode_positions ) My question is: what operations do each of the values in this transformation matrix correspond to? Thanks for your help! Maris -------------- next part -------------- An HTML attachment was scrubbed... URL: From jorn at artinis.com Tue Apr 26 09:26:25 2016 From: jorn at artinis.com (=?UTF-8?Q?J=C3=B6rn_M._Horschig?=) Date: Tue, 26 Apr 2016 09:26:25 +0200 Subject: [FieldTrip] transformation matrix In-Reply-To: References: Message-ID: <003301d19f8c$f1442d70$d3cc8850$@artinis.com> Hi Maris, The transformation matrix contains the rotation, scaling (so to say, the upper-left 3x3 matrix) and other components, e.g. a translational component (the 4th column). You can think of the fourth row as a sort of a mathematical trick to end up with a square matrix, making a lot of operations easier and computationally more efficient. This 4x4 transformation matrix is actually called a projection matrix (widely used in 3D programming), and there the 4th row actually plays a big role in perspective mapping (e.g. being able to make objects farther away seem smaller). This explanation should be roughly correct - I am not a mathematician though ;) Best regards, Jörn -- Jörn M. Horschig, PhD, Software Engineer Artinis Medical Systems | +31 481 350 980 From: fieldtrip-bounces at science.ru.nl [mailto:fieldtrip-bounces at science.ru.nl] On Behalf Of Maris Skujevskis Sent: Monday, April 25, 2016 23:52 To: fieldtrip at science.ru.nl Subject: [FieldTrip] transformation matrix Dear Fieldtrip users, A quick simple question (maybe it's been answered somewhere already but really I cannot find it...) Functions like ft_read_mri and ft_volumerealign attach the field 'transform' (a 4 x 4 matrix) to the data structure ( http://www.fieldtriptoolbox.org/faq/how_to_coregister_an_anatomical_mri_with_the_gradiometer_or_electrode_positions ) My question is: what operations do each of the values in this transformation matrix correspond to? Thanks for your help! Maris -------------- next part -------------- An HTML attachment was scrubbed... URL: From zsoltturi at gmail.com Tue Apr 26 14:14:34 2016 From: zsoltturi at gmail.com (Zsolt Turi) Date: Tue, 26 Apr 2016 14:14:34 +0200 Subject: [FieldTrip] cluster plot Message-ID: Dear Filedtrip users, I recently performed a non-parametric cluster-based permutation test on time-frequency data using a within-subjects design. I have two related questions/issues: 1) Size issues: For 11 participants the size of the file containing the time-frequency grand averages is 1.4 GB for each condition (I have two conditions), which is really hard to load in for the permutation test. Is this size reasonable? powspctrm: [4-D double] label: {64x1 cell} freq: [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20] time: [1x26 double] dimord: 'subj_chan_freq_time' cfg: [1x1 struct] 2) Cluster plot issue: Related to the first issue, after generating the plots for the stat, the computer stops responding and it is impossible to save the figure or even close it. cfg = []; cfg.alpha = 0.05; cfg.parameter = 'stat'; cfg.zlim = [-4 4]; cfg.layout = 'EEG1010.lay'; ft_clusterplot(cfg, stat); Have some of you encountered such kind of issues? I use 64 bit Win 7 OS, 8 GB RAM, Intel Core i5 CPU, 9.0.0.341360 (R2016a) Matlab and fieldtrip-20160424 versions. Thanks for your help in advance! Zsolt -------------- next part -------------- An HTML attachment was scrubbed... URL: From p.taesler at uke.de Tue Apr 26 14:45:03 2016 From: p.taesler at uke.de (Philipp Taesler) Date: Tue, 26 Apr 2016 14:45:03 +0200 Subject: [FieldTrip] cluster plot In-Reply-To: References: Message-ID: <571F62CF.6000201@uke.de> Hi Zsolt, I've had some similar problems with data from a very long analysis pipeline. It also failed to plot. A quick and dirty solution for me was to get rid of the "cfg" field in the struct, as it had somehow accumulated lots of data. newdata = rmfield(olddata, 'cfg'); Maybe this will help, otherwise I'm out of ideas for now :) Cheers, Phil Am 26.04.2016 um 14:14 schrieb Zsolt Turi: > Dear Filedtrip users, > > I recently performed a non-parametric cluster-based permutation test on > time-frequency data using a within-subjects design. I have two related > questions/issues: > > 1) Size issues: > > For 11 participants the size of the file containing the time-frequency > grand averages is 1.4 GB for each condition (I have two conditions), > which is really hard to load in for the permutation test. Is this size > reasonable? > > > powspctrm: [4-D double] > label: {64x1 cell} > freq: [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20] > time: [1x26 double] > dimord: 'subj_chan_freq_time' > cfg: [1x1 struct] > > > 2) Cluster plot issue: > > Related to the first issue, after generating the plots for the stat, the > computer stops responding and it is impossible to save the figure or > even close it. > > cfg = []; > cfg.alpha = 0.05; > cfg.parameter = 'stat'; > cfg.zlim = [-4 4]; > cfg.layout = 'EEG1010.lay'; > ft_clusterplot(cfg, stat); > > Have some of you encountered such kind of issues? > > > I use 64 bit Win 7 OS, 8 GB RAM, Intel Core i5 CPU, 9.0.0.341360 > (R2016a) Matlab and fieldtrip-20160424 versions. > > Thanks for your help in advance! > > Zsolt -- Philipp Taesler Department of Systems Neuroscience University Medical Center Hamburg-Eppendorf Martinistr. 52, W34, 20248 Hamburg, Germany Phone: +49-40-7410-59902 Fax: +49-40-7410-59955 Email: p.taesler at uke.de -- _____________________________________________________________________ Universitätsklinikum Hamburg-Eppendorf; Körperschaft des öffentlichen Rechts; Gerichtsstand: Hamburg | www.uke.de Vorstandsmitglieder: Prof. Dr. Burkhard Göke (Vorsitzender), Prof. Dr. Dr. Uwe Koch-Gromus, Joachim Prölß, Rainer Schoppik _____________________________________________________________________ SAVE PAPER - THINK BEFORE PRINTING From rb643 at medschl.cam.ac.uk Tue Apr 26 23:12:27 2016 From: rb643 at medschl.cam.ac.uk (Richard Bethlehem) Date: Tue, 26 Apr 2016 21:12:27 +0000 Subject: [FieldTrip] PostDoc/Bioinformatician post available at Cambridge Message-ID: <3188FAB8621D294696F13E80A7BBC97E01013D9C2D@me-mbx3.medschl.cam.ac.uk> Dear all, Our lab is current looking hire a bio-information to work and a large genetics data project and in a wonderful team! http://www.jobs.cam.ac.uk/job/10224/ It might be beyond the remit of the mailing list so please feel free toward to anyone you think might be interested! Cheers, Richard -------------- next part -------------- An HTML attachment was scrubbed... URL: From zsoltturi at gmail.com Wed Apr 27 09:46:34 2016 From: zsoltturi at gmail.com (Zsolt Turi) Date: Wed, 27 Apr 2016 09:46:34 +0200 Subject: [FieldTrip] cluster plot In-Reply-To: <571F62CF.6000201@uke.de> References: <571F62CF.6000201@uke.de> Message-ID: Dear Phil, thanks for the suggestion, I tried and it worked out! Cheers, Zsolt 2016-04-26 14:45 GMT+02:00 Philipp Taesler : > Hi Zsolt, > > I've had some similar problems with data from a very long analysis > pipeline. It also failed to plot. A quick and dirty solution for me was > to get rid of the "cfg" field in the struct, as it had somehow > accumulated lots of data. > > newdata = rmfield(olddata, 'cfg'); > > Maybe this will help, otherwise I'm out of ideas for now :) > > Cheers, > Phil > > > Am 26.04.2016 um 14:14 schrieb Zsolt Turi: > > Dear Filedtrip users, > > > > I recently performed a non-parametric cluster-based permutation test on > > time-frequency data using a within-subjects design. I have two related > > questions/issues: > > > > 1) Size issues: > > > > For 11 participants the size of the file containing the time-frequency > > grand averages is 1.4 GB for each condition (I have two conditions), > > which is really hard to load in for the permutation test. Is this size > > reasonable? > > > > > > powspctrm: [4-D double] > > label: {64x1 cell} > > freq: [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20] > > time: [1x26 double] > > dimord: 'subj_chan_freq_time' > > cfg: [1x1 struct] > > > > > > 2) Cluster plot issue: > > > > Related to the first issue, after generating the plots for the stat, the > > computer stops responding and it is impossible to save the figure or > > even close it. > > > > cfg = []; > > cfg.alpha = 0.05; > > cfg.parameter = 'stat'; > > cfg.zlim = [-4 4]; > > cfg.layout = 'EEG1010.lay'; > > ft_clusterplot(cfg, stat); > > > > Have some of you encountered such kind of issues? > > > > > > I use 64 bit Win 7 OS, 8 GB RAM, Intel Core i5 CPU, 9.0.0.341360 > > (R2016a) Matlab and fieldtrip-20160424 versions. > > > > Thanks for your help in advance! > > > > Zsolt > > > -- > Philipp Taesler > Department of Systems Neuroscience > University Medical Center Hamburg-Eppendorf > Martinistr. 52, W34, 20248 Hamburg, Germany > > Phone: +49-40-7410-59902 > Fax: +49-40-7410-59955 > Email: p.taesler at uke.de > -- > > _____________________________________________________________________ > > Universitätsklinikum Hamburg-Eppendorf; Körperschaft des öffentlichen > Rechts; Gerichtsstand: Hamburg | www.uke.de > Vorstandsmitglieder: Prof. Dr. Burkhard Göke (Vorsitzender), Prof. Dr. Dr. > Uwe Koch-Gromus, Joachim Prölß, Rainer Schoppik > _____________________________________________________________________ > > SAVE PAPER - THINK BEFORE PRINTING > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -- Post-doctoral Research Fellow Department of Clinical Neurophysiology Georg-August University, Göttingen Robert-Koch-Str. 40 37075 Goettingen -------------- next part -------------- An HTML attachment was scrubbed... URL: From ph442 at cam.ac.uk Wed Apr 27 12:49:18 2016 From: ph442 at cam.ac.uk (parham hashemzadeh) Date: Wed, 27 Apr 2016 11:49:18 +0100 Subject: [FieldTrip] MNE-sample data set on Fieldtrip. Message-ID: <96d4943980d708a2b7d8b6ffbc439792@cam.ac.uk> Dear All I was hoping to perform a complete source analysis using FieldTrip on the MNE-sample data set. The link to the MNE data set link is given below: http://martinos.org/mne/dev/manual/sample_dataset.html#babdhifj I am terribly confused on how to align the MRI coordinates to MEG. The MEG system is a neuromag306. The function hdr=ft_read_header(raw_data_set_filename) reads fiducial marks HPI. It is contained in hdr.orig.dig. Also shape = ft_read_headshape(raw_data_set_filename) gives a structure shape = pos: [143x3 double] fid: [1x1 struct] label: {143x1 cell} coordsys: 'neuromag' unit: 'cm' pnt: [143x3 double] where the shape.fid has the nasion, lpa and rpa. I have the following questions: 1. It appears to me that the MRI coordinate system is already spm. Axis X :Left to right. Axis Y: Posterior to Anterior. Axis Z: bottom to top. 2. How can I realign the MRI to MEG? a) Interactively: ft_volumerealign or b) Should I use the information in shape to have it done automatically? I think, it would be unwise to define my own lpa, rpa and nasion. 3. What is the relationship between HPI coil coordinates and the lpa, rpa and nasion coordinates? Are there scripts that relate the two. 4. Has anyone ever created a script to use Fieldtrip to analyze this specific data set? 5. The MEG sensors are in a different coordinate frame "1" as opposed to head coordinates (Electrodes). Do I have to make sure that these coordinates are transformed to head coordinates prior to ft_prepare_leadfield calculations? or is this done automatically by fieldtrip? I just have the feeling that it would be unwise to do this interactively because of the existence of the fiducial markers. Many thanks if you are able to help me. -- best regards Parham Hashemzadeh Research Associate Department of Applied Mathematics and Theoretical Physics University of Cambridge, UK. email: hashemzadeh at damtp.cam.ac.uk From gina.joue at univr.it Wed Apr 27 18:24:16 2016 From: gina.joue at univr.it (gj) Date: Wed, 27 Apr 2016 18:24:16 +0200 Subject: [FieldTrip] FW: From a .csv data file, to a recognized dataset by fieldtrip In-Reply-To: References: Message-ID: <5720E7B0.4060207@univr.it> Hi Mina, I'm definitely not a FieldTrip expert, but I recently did something similar with .dat files that was just tab-delimited EEG data in the format [nsamples x nchan]. I followed this page closely: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat Basically, I created the following FT data structure: data.label % [nchan x 1] cell array of string labels for channels data.fsample % sampling frequency in Hz % for each trial t: data.trial{t} = load('eeg.dat'); % load your EEG data file -- should be [nchan x nsamples] data.time{t} % [1 x nsamples] vector corresponding to the time axis for each trial in SECONDS at each sampling point! If you've set all of that, you should be able to doublecheck your data by plotting it, e.g. cfg = []; cfg.viewmode = 'vertical'; % 'butterfly" superimposes channels cfg.continuous = 'no'; ft_databrowser(cfg,data); To prepare your channel layouts in FT data format, it seems like you need the electrodes in the ff formats 1. in mm in MNI coordinates and FT 2-D data format (see also templates in your FT subfolder: template/electrode/). If you don't have this, you can prepare your channel layout by using ft_prepare_layout() (check out the comments in the code or 'help ft_prepare_layout'). Then check that you've set up your data structure correctly with ft_plot_lay(); 2. in phi/theta coordinates of FT_DATATYPE_SENS format (some templates in FT subfolder template/layout/). Check out "help FT_DATATYPE_SENS" Your fiducials should be at the beginning of the list of your channels. Hope that is somewhat useful. Good luck! g From runna90 at 126.com Thu Apr 28 03:15:05 2016 From: runna90 at 126.com (CRN) Date: Thu, 28 Apr 2016 09:15:05 +0800 Subject: [FieldTrip] filter in continuous data and then epoch Message-ID: Dear fieldtrippers, I am processing MEG data acquired by CTF275 and I want to do filters in continuous raw data and then epoch them according to triggers. But I got warnings which were displayed below the code. Here is my code: cfg = []; cfg.dataset = dataset.ds; cfg.continuous = 'yes'; cfg.channel = 'meg'; raw_data = ft_preprocessing(cfg); cfg = []; cfg.lpfilter = 'yes'; cfg.lpfreq = 30; cfg.hpfilter = 'yes'; cfg.hpfreq = 1; cfg.dftfilte = 'yes'; cfg.dftfreq = 50; conti_filt = ft_preprocessing(cfg,raw_data); cfg=[]; cfg.dataset = [subjectdata.subjectdir filesep subjectdata.datadir{f_n}]; cfg.trialdef.eventtype = 'frontpanel trigger'; cfg.trialdef.eventvalue = 3; cfg.trialdef.pre = 0.5; cfg.trialdef.post = 1.2; cfg.continuous = 'yes'; cfg.trialfun = 'ft_trialfun_crn'; % self defined trl function cfg.channel = 'MEG'; cfg.layout = 'MEG.lay'; cfg = ft_definetrial(cfg); data_filt = ft_preprocessing(cfg, conti_filt); Warning: The field cfg.trl is forbidden, it will be removed from your configuration The field cfg.dataset is forbidden, it will be removed from your configuration The field cfg.datafile is forbidden, it will be removed from your configuration The field cfg.headerfile is forbidden, it will be removed from your configuration I have stuck in this question a whole night, please help! Thank you very much! Best wishes, Runnan runna90 at 126.com Institute of Biophysics, Chinese Academy of Science, Beijing, China -------------- next part -------------- An HTML attachment was scrubbed... URL: From icelandhouse at gmail.com Thu Apr 28 21:06:35 2016 From: icelandhouse at gmail.com (Maris Skujevskis) Date: Thu, 28 Apr 2016 21:06:35 +0200 Subject: [FieldTrip] Electrode position effects on leadfield values Message-ID: Dear Fieldtrip users, It is common knowledge that due to noise/measurement error, it is hard, if not impossible to match Polhemus digitized electrode locations with the MR head shape precisely. Even after manual and iterative alignment some electrodes remain "hanging" in the air above the head surface, while some others get buried below the head surface. Here is an illustration of what I mean: https://goo.gl/aSm7YU I am wondering what effect this type of electrode misplacement has on the values in the leadfield matrix as calculated by ft_prepare_leadfield? How does fieldtrip deal with electrodes placed in such a way? It seems that there is some magic involved there, since in theory the lead field matrix values for the electrodes not touching the surface of the head should be zero (which is not the case in the lead field matrix produced by ft_prepare_leadfield). I am currently testing how moving a "floating" and a "buried" electrode to its nearest point on the scalp affects the leadfield matrix values. I do not have any definite answers yet, but I did want to check in with some more experienced users out there before spending too much time on this (and possibly reinventing the wheel, so to speak). Thanks! Maris -------------- next part -------------- An HTML attachment was scrubbed... URL: From A.Reid at psych.ru.nl Fri Apr 29 14:01:38 2016 From: A.Reid at psych.ru.nl (Reid, A.T. (Andrew)) Date: Fri, 29 Apr 2016 12:01:38 +0000 Subject: [FieldTrip] Unit error using ft_topoplotTFR.m Message-ID: <5AE33796-5433-4D90-AE5F-A3ABD85E0C00@donders.ru.nl> Hi all, I am trying to do a simple topo plot of some time-locked HCP data. Running ft_multiplotTFR on the TFR output structure works fine. When I run ft_topoplotTFR on the same structure, I get the following error: creating layout from data.grad undoing the invcomp balancing for the gradiometer definition Error using ft_scalingfactor (line 181) cannot convert T to unknown Error in ft_scalingfactor (line 94) factor = cellfun(@ft_scalingfactor, old(:), new(:)); Error in ft_apply_montage (line 309) scale = ft_scalingfactor(input.chanunit, montage.chanunitorg); Error in undobalancing (line 37) sens = ft_apply_montage(sens, sens.balance.(sens.balance.current), 'inverse', 'yes', 'keepunused', 'yes', 'warning', 'no'); Error in ft_prepare_layout>sens2lay (line 957) sens = undobalancing(sens); Error in ft_prepare_layout (line 430) layout = sens2lay(data.grad, cfg.rotate, cfg.projection, cfg.style, cfg.overlap); Error in ft_topoplotTFR (line 192) cfg.layout = ft_prepare_layout(cfg, varargin{:}); The data.grad.balance.invcomp.chanunitnew cell array appears to be the culprit, as it contains “unknown” while the main data.chanunit has unit “T”. Not sure how to proceed here.. Thanks! Andrew ____________________________________________________ Andrew Reid Postdoctoral Fellow Department of Cognitive Artificial Intelligence Donders Institute for Brain, Cognition and Behaviour Radboud University Nijmegen Web: http://andrew.modelgui.org/ Tel: +31 (0)24 36 55931 -------------- next part -------------- An HTML attachment was scrubbed... URL: From gina.joue at univr.it Fri Apr 29 17:49:05 2016 From: gina.joue at univr.it (gj) Date: Fri, 29 Apr 2016 17:49:05 +0200 Subject: [FieldTrip] Fwd: ft_sourcegrandaverage and ft_sourceplot usage In-Reply-To: <57238213.5090103@univr.it> References: <57238213.5090103@univr.it> Message-ID: <57238271.70009@univr.it> Hi, I had computed source reconstruction in the frequency domain of my EEG data -- followed by * ft_sourcedescriptives with cfg.projectmom="yes" * set the resulting source_proj.dim = grid.dim source_proj.pos = grid.pos * ft_sourceinterpolate onto an MNI template brain but for some conditions of some subjects, this resulting localizations were predominantly in the center of the head. So, I was thinking of calculating the grand average of the source (though is this kosher when I have obvious individual source modeling problems?): ----- cfg.parameter = 'avg.pow'; cfg.keepindividual = 'yes'; cfg.outputfile = 'srcGrandAvg'; srcGrandAvg = ft_sourcegrandaverage(cfg, source_interp{:}); % source_interp = output of ft_sourceinterpolate ----- I'm not sure if my approach is correct because this results in a HUGE (several hundred MBs) srcGrandAvg matrix per condition that takes forever to write to disk. Moreover I cannot seem to plot it with ft_sourceplot (doesn't plot the source averaging results): ----- cfg = []; cfg.funparameter = 'pow'; cfg.method='ortho'; srcGrandAvg.anatomy = mri.anatomy; % from load('standard_mri.mat'); figure ft_sourceplot(cfg,srcGrandAvg); ----- ft_sourceplot gives me the messages: ----- the input is source data with 7109137 brainordinates on a [181 217 181] grid scaling anatomy to [0 1] not plotting functional data not applying a mask on the functional data not using an atlas not using a region-of-interest ----- My output from ft_sourcegrandaverage looks like this: ----- srcGrandAvg = pow: [19x7109137 double] coordsys: 'spm' dim: [181 217 181] freq: 12 inside: [7109137x1 logical] pos: [7109137x3 double] unit: 'mm' cfg: [1x1 struct] anatomy: [1x1 struct] ----- Thanks in advance for any help or advice!!! Gina From tineke.snijders at donders.ru.nl Fri Apr 1 12:03:30 2016 From: tineke.snijders at donders.ru.nl (Snijders, T.M. (Tineke)) Date: Fri, 1 Apr 2016 10:03:30 +0000 Subject: [FieldTrip] Question about coherence statistics In-Reply-To: References: <2595287eebb0aeacfe5761a9de10de24@inserm.fr> <68a5ba763224075e6d9ec9aa7684221a@inserm.fr>, <815A9820E75FBC4F96B7CD3A8089D11C378AE3E0@exprd04.hosting.ru.nl>, Message-ID: <815A9820E75FBC4F96B7CD3A8089D11C378AE4DA@exprd04.hosting.ru.nl> Hi Laetitia, Indeed, as 'coh' doesn't have the trial information anymore after ft_connectivityanalysis, you can't use it as input for ft_freqstatistics if you only have one subject. Indeed, giving 'cohspctrm' as parameter with your freq data doesn't work as 'cohspctrm' is not in your freq data. The cfg.parameter specifies what data to use for the randomization, so that parameter should be in the data you give as input. You can use the freq data as input for freq_statistics, but then you have to change your cfg.statistic. This is the statistical function that is called after shuffling your trials - in your case after shuffling your trials the coherence has to be computed and the difference between conditions calculated. As far as I know, if you set your cfg.statistic to 'diff_itc', it will compute the difference in the inter-trial coherence between two conditions (looking at the phase consistency over trials). Best, Tineke ________________________________ From: laetitia.lalla at inserm.fr [laetitia.lalla at inserm.fr] Sent: Thursday, March 31, 2016 3:22 PM To: FieldTrip discussion list Cc: Snijders, T.M. (Tineke) Subject: Re: [FieldTrip] Question about coherence statistics Dear Tineke, thank you very much for your fast answer ! I'm not sure I understand what you mean though... Maybe i did not express myself correctly. I do have individual trial data : I have 26 observations for condition 1 and 26 observations for condition 2. They appear : - In my structure "data" (output of ft_preprocessing) : data.trial is a cell {1 x nbtrials} (in my case : {1, 26}) - in my structure "freq" (output of ft_freqanalysis) : freq.powspctrm is a matrix of dimension : nbtrials X nbchannel X nbfreq (in my case 26x2x25) But I don't have this information anymore in the structure "coh" (output of ft_connectivityanalysis) : coh.cospctrm is a matrix of dimension nbchannelcmb x nbfreq (in my case 1x25) since the coherence is calculated by averaging over trials... You may mean I should give the "freq" structures as inputs to the fonction ft_freqstatistics ? I just tried that : I created a structure data_all by concatenated data1.trial and data2.trial (and every other appropriate attribute). I took the Time Frequency Representation with ft_freqanalysis (with keeptrials='yes') to obtain a structure TFR_all (following this tutorial : http://www.fieldtriptoolbox.org/tutorial/natmeg/statistics This is actually how I did the statistics for the Power). But then, if I give this as an input to ft_freqstatistics, like this : cfg = []; cfg.statistic = 'diff'; cfg.parameter='cohspctrm'; cfg.design= [ones(1,nbtrial)) 2*ones(1, nbtrial))]; %same nb of trials for both condition cfg.method = 'montecarlo'; cfg.numrandomization = 1000; cfg.ivar = 1; cfg.alpha=0.05; cfg.tail=0; cfg.correcttail='alpha'; >> stat=ft_freqstatistics(cfg, FR_alltrials); I have the following error : Error using getdimord (line 15) field "cohspctrm" not present in data which makes a lot of sense, since I did not gave coherence as an input... I gave Frequency representations.. I was hoping that maybe the function would calculate the coherence itself for the statistics ? ^^ But it's clearly not the way to go. Could you be a bit more explicit about what you meant ? Thanks a lot. Best, Laetitia Lalla PhD student in Neurosciences INMED, Marseille, France On 31-03-2016 13:47, Snijders, T.M. (Tineke) wrote: Hi Laetitia, If you only have one subject you do need individual trial data, otherwise you can't do statistics like this. You need multiple observations (either subjects or trials). Best, Tineke ________________________________ From: fieldtrip-bounces at science.ru.nl [fieldtrip-bounces at science.ru.nl] on behalf of laetitia.lalla at inserm.fr [laetitia.lalla at inserm.fr] Sent: Thursday, March 31, 2016 1:11 PM To: fieldtrip at science.ru.nl Subject: [FieldTrip] Question about coherence statistics Dear FielTrip community, Sorry to bother you again... I have a question about the statistical testing to assess coherence differences and the related paper by E Maris, JM Schoffelen and P Fries (Journal of Neuroscience Methods, 2007) I believe I am exactly in the framework described in this paper, but I guess there is still some crucial information that I don't understand... This is my story : - It's a single-subject study - I want to compare two sets of trials observed in different conditions. - The 2 sets of trials are exactly the same size, so my coherence estimate won't be biased by the "unequal sample size problem". - I just want to compare for 1 channel pair, for 1 frequency bin [6Hz 10Hz], so I guess the Multiple Comparison problem won't affect my analysis too much (either in the spatial or the spectral dimension). Based on the paper, I could refer myself to the point "2.7.1. A non parametric satistical test for a single signal pair and a single frequency bin". - Since my interest is in the coherence difference for a single signal pair, I can choose [|C1(f)|-|C2(f)|] as a test statistic. - And I can perform the montecarlo simulation. My question is the following : How can I implement the nonparametric test of the coherence difference between my 2 conditions with the fieldtrip functions ? This is what I did : 1) Extract and preprocess the signal from my condition 1. 2) freq1= ft_freqanalysis(cfg, signal1) (with cfg.method='mtmfft', cfg.output='powandcsd') → 3) coh1= ft_connectivityanalysis(cfg, freq1) I did the same thing for the other condition → coh2. And then for the statistics : cfg = []; cfg.statistic = 'diff'; (% because the statistic test than I chose is the difference [|C1(f)|-|C2(f)|]) cfg.parameter='cohspctrm'; cfg.method = 'montecarlo'; cfg.numrandomization = 1000; cfg.ivar = 1; cfg.alpha=0.05; cfg.tail=0; cfg.correcttail='alpha'; stat=ft_freqstatistics(cfg, coh1, coh2); And it gives me the following error : Error using ft_checkconfig (line 153) The field cfg.design is required. Here, I really don't understand why I'm asked for the design matrix... When doing the statistics for the Power, I understood that the design matrix was telling which trial belonged to the condition 1 and which trial belonged to the condition 2. But here, it doesn't make any sense because my coherence was calculated by averaging on the trials... Does the design matrix mean something differently here ? Or maybe I forgot one parameter to put in the cfg ? Any help will be appreciated ! Thanks a lot for your time, Laetitia Lalla PhD student in Neurosciences INMED, Marseille, France _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From hibafouani123 at hotmail.com Fri Apr 1 12:15:53 2016 From: hibafouani123 at hotmail.com (hiba fouani) Date: Fri, 1 Apr 2016 10:15:53 +0000 Subject: [FieldTrip] Bidomain model instead of dipoles In-Reply-To: References: Message-ID: Dear fieldtripper, I want to study source localization for ecg but with bidomain model for sources not dipoles, is it possible with fieldtrip or openmeeg? and thank you for suggestion for any tool. Thank you Hiba > From: fieldtrip-request at science.ru.nl > Subject: fieldtrip Digest, Vol 65, Issue 1 > To: fieldtrip at science.ru.nl > Date: Fri, 1 Apr 2016 12:00:02 +0200 > > Send fieldtrip mailing list submissions to > fieldtrip at science.ru.nl > > To subscribe or unsubscribe via the World Wide Web, visit > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > or, via email, send a message with subject or body 'help' to > fieldtrip-request at science.ru.nl > > You can reach the person managing the list at > fieldtrip-owner at science.ru.nl > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of fieldtrip digest..." > > > Today's Topics: > > 1. Question about coherence statistics (laetitia.lalla at inserm.fr) > 2. Re: Question about coherence statistics (Snijders, T.M. (Tineke)) > 3. Re: Question about coherence statistics (laetitia.lalla at inserm.fr) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Thu, 31 Mar 2016 13:11:31 +0200 > From: laetitia.lalla at inserm.fr > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Question about coherence statistics > Message-ID: > Content-Type: text/plain; charset="utf-8" > > > > Dear FielTrip community, > > Sorry to bother you again... > > I have a question about the statistical testing to assess coherence > differences and the related paper by E Maris, JM Schoffelen and P Fries > (Journal of Neuroscience Methods, 2007) > > I believe I am exactly in the framework described in this paper, but I > guess there is still some crucial information that I don't understand... > > > This is my story : > > - It's a single-subject study > > - I want to compare two sets of trials observed in different conditions. > > > - The 2 sets of trials are exactly the same size, so my coherence > estimate won't be biased by the "unequal sample size problem". > > - I just want to compare for 1 channel pair, for 1 frequency bin [6Hz > 10Hz], so I guess the Multiple Comparison problem won't affect my > analysis too much (either in the spatial or the spectral dimension). > > Based on the paper, I could refer myself to the point "2.7.1. A non > parametric satistical test for a single signal pair and a single > frequency bin". > > - Since my interest is in the coherence difference for a single signal > pair, I can choose [|C1(f)|-|C2(f)|] as a test statistic. > > - And I can perform the montecarlo simulation. > > My question is the following : How can I implement the nonparametric > test of the coherence difference between my 2 conditions with the > fieldtrip functions ? > > This is what I did : > > 1) Extract and preprocess the signal from my condition 1. > > 2) freq1= ft_freqanalysis(cfg, signal1) (with cfg.method='mtmfft', > cfg.output='powandcsd') ? > > 3) coh1= ft_connectivityanalysis(cfg, freq1) > > I did the same thing for the other condition ? coh2. > > And then for the statistics : > > cfg = []; > > cfg.statistic = 'diff'; (% because the statistic test than I chose is > the difference [|C1(f)|-|C2(f)|]) > > cfg.parameter='cohspctrm'; > > cfg.method = 'montecarlo'; > > cfg.numrandomization = 1000; > > cfg.ivar = 1; > > cfg.alpha=0.05; > > cfg.tail=0; > > cfg.correcttail='alpha'; > > stat=ft_freqstatistics(cfg, coh1, coh2); > > And it gives me the following error : > > Error using ft_checkconfig (line 153) > > The field cfg.design is required. > > Here, I really don't understand why I'm asked for the design matrix... > When doing the statistics for the Power, I understood that the design > matrix was telling which trial belonged to the condition 1 and which > trial belonged to the condition 2. But here, it doesn't make any sense > because my coherence was calculated by averaging on the trials... > > Does the design matrix mean something differently here ? Or maybe I > forgot one parameter to put in the cfg ? > > Any help will be appreciated ! > > Thanks a lot for your time, > > Laetitia Lalla > > PhD student in Neurosciences > > INMED, Marseille, France > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > Message: 2 > Date: Thu, 31 Mar 2016 11:47:19 +0000 > From: "Snijders, T.M. (Tineke)" > To: FieldTrip discussion list > Subject: Re: [FieldTrip] Question about coherence statistics > Message-ID: > <815A9820E75FBC4F96B7CD3A8089D11C378AE3E0 at exprd04.hosting.ru.nl> > Content-Type: text/plain; charset="iso-2022-jp" > > Hi Laetitia, > > If you only have one subject you do need individual trial data, otherwise you can't do statistics like this. > You need multiple observations (either subjects or trials). > > Best, > Tineke > > ________________________________ > From: fieldtrip-bounces at science.ru.nl [fieldtrip-bounces at science.ru.nl] on behalf of laetitia.lalla at inserm.fr [laetitia.lalla at inserm.fr] > Sent: Thursday, March 31, 2016 1:11 PM > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Question about coherence statistics > > > Dear FielTrip community, > > Sorry to bother you again... > > I have a question about the statistical testing to assess coherence differences and the related paper by E Maris, JM Schoffelen and P Fries (Journal of Neuroscience Methods, 2007) > > I believe I am exactly in the framework described in this paper, but I guess there is still some crucial information that I don't understand... > > > > This is my story : > > - It's a single-subject study > > - I want to compare two sets of trials observed in different conditions. > > - The 2 sets of trials are exactly the same size, so my coherence estimate won't be biased by the ?unequal sample size problem?. > > - I just want to compare for 1 channel pair, for 1 frequency bin [6Hz 10Hz], so I guess the Multiple Comparison problem won't affect my analysis too much (either in the spatial or the spectral dimension). > > > > Based on the paper, I could refer myself to the point ?2.7.1. A non parametric satistical test for a single signal pair and a single frequency bin?. > > - Since my interest is in the coherence difference for a single signal pair, I can choose [|C1(f)|-|C2(f)|] as a test statistic. > > - And I can perform the montecarlo simulation. > > > > My question is the following : How can I implement the nonparametric test of the coherence difference between my 2 conditions with the fieldtrip functions ? > > > > This is what I did : > > 1) Extract and preprocess the signal from my condition 1. > > 2) freq1= ft_freqanalysis(cfg, signal1) (with cfg.method='mtmfft', cfg.output='powandcsd') ? > > 3) coh1= ft_connectivityanalysis(cfg, freq1) > > > > I did the same thing for the other condition ? coh2. > > > > And then for the statistics : > > cfg = []; > > cfg.statistic = 'diff'; (% because the statistic test than I chose is the difference [|C1(f)|-|C2(f)|]) > > cfg.parameter='cohspctrm'; > > cfg.method = 'montecarlo'; > > cfg.numrandomization = 1000; > > cfg.ivar = 1; > > cfg.alpha=0.05; > > cfg.tail=0; > > cfg.correcttail='alpha'; > > stat=ft_freqstatistics(cfg, coh1, coh2); > > > > And it gives me the following error : > > Error using ft_checkconfig (line 153) > > The field cfg.design is required. > > > > Here, I really don't understand why I'm asked for the design matrix... When doing the statistics for the Power, I understood that the design matrix was telling which trial belonged to the condition 1 and which trial belonged to the condition 2. But here, it doesn't make any sense because my coherence was calculated by averaging on the trials... > > Does the design matrix mean something differently here ? Or maybe I forgot one parameter to put in the cfg ? > > > > Any help will be appreciated ! > > > > Thanks a lot for your time, > > > > Laetitia Lalla > > PhD student in Neurosciences > > INMED, Marseille, France > > > > > > > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > Message: 3 > Date: Thu, 31 Mar 2016 15:22:31 +0200 > From: laetitia.lalla at inserm.fr > To: FieldTrip discussion list > Subject: Re: [FieldTrip] Question about coherence statistics > Message-ID: > Content-Type: text/plain; charset="utf-8" > > > > Dear Tineke, > > thank you very much for your fast answer ! I'm not sure I understand > what you mean though... Maybe i did not express myself correctly. I do > have individual trial data : I have 26 observations for condition 1 and > 26 observations for condition 2. > > They appear : > > - In my structure "data" (output of ft_preprocessing) : data.trial is a > cell {1 x nbtrials} (in my case : {1, 26}) > > - in my structure "freq" (output of ft_freqanalysis) : freq.powspctrm is > a matrix of dimension : nbtrials X nbchannel X nbfreq (in my case > 26x2x25) > > But I don't have this information anymore in the structure "coh" (output > of ft_connectivityanalysis) : coh.cospctrm is a matrix of dimension > nbchannelcmb x nbfreq (in my case 1x25) since the coherence is > calculated by averaging over trials... > > You may mean I should give the "freq" structures as inputs to the > fonction ft_freqstatistics ? > > I just tried that : I created a structure data_all by concatenated > data1.trial and data2.trial (and every other appropriate attribute). I > took the Time Frequency Representation with ft_freqanalysis (with > keeptrials='yes') to obtain a structure TFR_all (following this tutorial > : http://www.fieldtriptoolbox.org/tutorial/natmeg/statistics This is > actually how I did the statistics for the Power). > > But then, if I give this as an input to ft_freqstatistics, like this : > > cfg = []; > cfg.statistic = 'diff'; > cfg.parameter='cohspctrm'; > cfg.design= [ones(1,nbtrial)) 2*ones(1, nbtrial))]; %same nb of trials > for both condition > cfg.method = 'montecarlo'; > cfg.numrandomization = 1000; > cfg.ivar = 1; > cfg.alpha=0.05; > cfg.tail=0; > cfg.correcttail='alpha'; > >> stat=ft_freqstatistics(cfg, FR_alltrials); > > I have the following error : > > Error using getdimord (line 15) > field "cohspctrm" not present in data > > which makes a lot of sense, since I did not gave coherence as an > input... I gave Frequency representations.. I was hoping that maybe the > function would calculate the coherence itself for the statistics ? ^^ > But it's clearly not the way to go. > > Could you be a bit more explicit about what you meant ? > > Thanks a lot. > > Best, > > Laetitia Lalla > > PhD student in Neurosciences > > INMED, Marseille, France > > On 31-03-2016 13:47, Snijders, T.M. (Tineke) wrote: > > > Hi Laetitia, > > > > If you only have one subject you do need individual trial data, otherwise you can't do statistics like this. > > You need multiple observations (either subjects or trials). > > > > Best, > > Tineke > > > > ------------------------- > > > > FROM: fieldtrip-bounces at science.ru.nl [fieldtrip-bounces at science.ru.nl] on behalf of laetitia.lalla at inserm.fr [laetitia.lalla at inserm.fr] > > SENT: Thursday, March 31, 2016 1:11 PM > > TO: fieldtrip at science.ru.nl > > SUBJECT: [FieldTrip] Question about coherence statistics > > > > Dear FielTrip community, > > > > Sorry to bother you again... > > > > I have a question about the statistical testing to assess coherence differences and the related paper by E Maris, JM Schoffelen and P Fries (Journal of Neuroscience Methods, 2007) > > > > I believe I am exactly in the framework described in this paper, but I guess there is still some crucial information that I don't understand... > > > > This is my story : > > > > - It's a single-subject study > > > > - I want to compare two sets of trials observed in different conditions. > > > > - The 2 sets of trials are exactly the same size, so my coherence estimate won't be biased by the "unequal sample size problem". > > > > - I just want to compare for 1 channel pair, for 1 frequency bin [6Hz 10Hz], so I guess the Multiple Comparison problem won't affect my analysis too much (either in the spatial or the spectral dimension). > > > > Based on the paper, I could refer myself to the point "2.7.1. A non parametric satistical test for a single signal pair and a single frequency bin". > > > > - Since my interest is in the coherence difference for a single signal pair, I can choose [|C1(f)|-|C2(f)|] as a test statistic. > > > > - And I can perform the montecarlo simulation. > > > > My question is the following : How can I implement the nonparametric test of the coherence difference between my 2 conditions with the fieldtrip functions ? > > > > This is what I did : > > > > 1) Extract and preprocess the signal from my condition 1. > > > > 2) freq1= ft_freqanalysis(cfg, signal1) (with cfg.method='mtmfft', cfg.output='powandcsd') ? > > > > 3) coh1= ft_connectivityanalysis(cfg, freq1) > > > > I did the same thing for the other condition ? coh2. > > > > And then for the statistics : > > > > cfg = []; > > > > cfg.statistic = 'diff'; (% because the statistic test than I chose is the difference [|C1(f)|-|C2(f)|]) > > > > cfg.parameter='cohspctrm'; > > > > cfg.method = 'montecarlo'; > > > > cfg.numrandomization = 1000; > > > > cfg.ivar = 1; > > > > cfg.alpha=0.05; > > > > cfg.tail=0; > > > > cfg.correcttail='alpha'; > > > > stat=ft_freqstatistics(cfg, coh1, coh2); > > > > And it gives me the following error : > > > > Error using ft_checkconfig (line 153) > > > > The field cfg.design is required. > > > > Here, I really don't understand why I'm asked for the design matrix... When doing the statistics for the Power, I understood that the design matrix was telling which trial belonged to the condition 1 and which trial belonged to the condition 2. But here, it doesn't make any sense because my coherence was calculated by averaging on the trials... > > > > Does the design matrix mean something differently here ? Or maybe I forgot one parameter to put in the cfg ? > > > > Any help will be appreciated ! > > > > Thanks a lot for your time, > > > > Laetitia Lalla > > > > PhD student in Neurosciences > > > > INMED, Marseille, France > > > > _______________________________________________ > > fieldtrip mailing list > > fieldtrip at donders.ru.nl > > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > End of fieldtrip Digest, Vol 65, Issue 1 > **************************************** -------------- next part -------------- An HTML attachment was scrubbed... URL: From juangpc at gmail.com Fri Apr 1 22:38:54 2016 From: juangpc at gmail.com (Juan) Date: Fri, 1 Apr 2016 22:38:54 +0200 Subject: [FieldTrip] tutorial on preprocessing ERP activity in combined MEG/EEG data Message-ID: Hi, Following the tutorial on preprocessing combined MEG/EEG data, I've noticed that in order to reproduce ft_multiplotER figures (i.e. ) some changes must be made to the code. ​ I c ​ould do the changes these myself but ​as this implies quite a few within the tutorial, ​ I'm wondering if this is ok or not. For instance, cfg.xlim and cfg.ylim must be changed to cfg.vlim and cfg.hlim. Also ERF_diff = ft_math(cfg, ERF_oddball, ERF_standard); must be changed to ERF_diff = ft_math(cfg, ERF_standard, ERF_oddball); ​ Juan -------------- next part -------------- An HTML attachment was scrubbed... URL: From laetitia.lalla at inserm.fr Mon Apr 4 11:45:49 2016 From: laetitia.lalla at inserm.fr (laetitia.lalla at inserm.fr) Date: Mon, 04 Apr 2016 11:45:49 +0200 Subject: [FieldTrip] Question about coherence statistics In-Reply-To: <815A9820E75FBC4F96B7CD3A8089D11C378AE4DA@exprd04.hosting.ru.nl> References: <2595287eebb0aeacfe5761a9de10de24@inserm.fr> <68a5ba763224075e6d9ec9aa7684221a@inserm.fr>, <815A9820E75FBC4F96B7CD3A8089D11C378AE3E0@exprd04.hosting.ru.nl>, <815A9820E75FBC4F96B7CD3A8089D11C378AE4DA@exprd04.hosting.ru.nl> Message-ID: <17c319aeab6f35a621fb193e8b051792@inserm.fr> Hey Tineke, Thank you very much ! It's all clear now. I was stuck with the list of statistics described in the "help" of freqstatistics and I did not even though of browsing the ft_statfun_XXX functions. I'm gonna try this right away. Have a nice day, Laetitia Lalla PhD student in Neurosciences INMED, Marseille, France On 01-04-2016 12:03, Snijders, T.M. (Tineke) wrote: > Hi Laetitia, > > Indeed, as 'coh' doesn't have the trial information anymore after ft_connectivityanalysis, you can't use it as input for ft_freqstatistics if you only have one subject. > > Indeed, giving 'cohspctrm' as parameter with your freq data doesn't work as 'cohspctrm' is not in your freq data. The cfg.parameter specifies what data to use for the randomization, so that parameter should be in the data you give as input. > > You can use the freq data as input for freq_statistics, but then you have to change your cfg.statistic. This is the statistical function that is called after shuffling your trials - in your case after shuffling your trials the coherence has to be computed and the difference between conditions calculated. As far as I know, if you set your cfg.statistic to 'diff_itc', it will compute the difference in the inter-trial coherence between two conditions (looking at the phase consistency over trials). > > Best, > Tineke > > ------------------------- > > FROM: laetitia.lalla at inserm.fr [laetitia.lalla at inserm.fr] > SENT: Thursday, March 31, 2016 3:22 PM > TO: FieldTrip discussion list > CC: Snijders, T.M. (Tineke) > SUBJECT: Re: [FieldTrip] Question about coherence statistics > > Dear Tineke, > > thank you very much for your fast answer ! I'm not sure I understand what you mean though... Maybe i did not express myself correctly. I do have individual trial data : I have 26 observations for condition 1 and 26 observations for condition 2. > > They appear : > > - In my structure "data" (output of ft_preprocessing) : data.trial is a cell {1 x nbtrials} (in my case : {1, 26}) > > - in my structure "freq" (output of ft_freqanalysis) : freq.powspctrm is a matrix of dimension : nbtrials X nbchannel X nbfreq (in my case 26x2x25) > > But I don't have this information anymore in the structure "coh" (output of ft_connectivityanalysis) : coh.cospctrm is a matrix of dimension nbchannelcmb x nbfreq (in my case 1x25) since the coherence is calculated by averaging over trials... > > You may mean I should give the "freq" structures as inputs to the fonction ft_freqstatistics ? > > I just tried that : I created a structure data_all by concatenated data1.trial and data2.trial (and every other appropriate attribute). I took the Time Frequency Representation with ft_freqanalysis (with keeptrials='yes') to obtain a structure TFR_all (following this tutorial : http://www.fieldtriptoolbox.org/tutorial/natmeg/statistics This is actually how I did the statistics for the Power). > > But then, if I give this as an input to ft_freqstatistics, like this : > > cfg = []; > cfg.statistic = 'diff'; > cfg.parameter='cohspctrm'; > cfg.design= [ones(1,nbtrial)) 2*ones(1, nbtrial))]; %same nb of trials for both condition > cfg.method = 'montecarlo'; > cfg.numrandomization = 1000; > cfg.ivar = 1; > cfg.alpha=0.05; > cfg.tail=0; > cfg.correcttail='alpha'; >>> stat=ft_freqstatistics(cfg, FR_alltrials); > > I have the following error : > > Error using getdimord (line 15) > field "cohspctrm" not present in data > > which makes a lot of sense, since I did not gave coherence as an input... I gave Frequency representations.. I was hoping that maybe the function would calculate the coherence itself for the statistics ? ^^ But it's clearly not the way to go. > > Could you be a bit more explicit about what you meant ? > > Thanks a lot. > > Best, > > Laetitia Lalla > > PhD student in Neurosciences > > INMED, Marseille, France > > On 31-03-2016 13:47, Snijders, T.M. (Tineke) wrote: > >> Hi Laetitia, >> >> If you only have one subject you do need individual trial data, otherwise you can't do statistics like this. >> You need multiple observations (either subjects or trials). >> >> Best, >> Tineke >> >> ------------------------- >> >> FROM: fieldtrip-bounces at science.ru.nl [fieldtrip-bounces at science.ru.nl] on behalf of laetitia.lalla at inserm.fr [laetitia.lalla at inserm.fr] >> SENT: Thursday, March 31, 2016 1:11 PM >> TO: fieldtrip at science.ru.nl >> SUBJECT: [FieldTrip] Question about coherence statistics >> >> Dear FielTrip community, >> >> Sorry to bother you again... >> >> I have a question about the statistical testing to assess coherence differences and the related paper by E Maris, JM Schoffelen and P Fries (Journal of Neuroscience Methods, 2007) >> >> I believe I am exactly in the framework described in this paper, but I guess there is still some crucial information that I don't understand... >> >> This is my story : >> >> - It's a single-subject study >> >> - I want to compare two sets of trials observed in different conditions. >> >> - The 2 sets of trials are exactly the same size, so my coherence estimate won't be biased by the "unequal sample size problem". >> >> - I just want to compare for 1 channel pair, for 1 frequency bin [6Hz 10Hz], so I guess the Multiple Comparison problem won't affect my analysis too much (either in the spatial or the spectral dimension). >> >> Based on the paper, I could refer myself to the point "2.7.1. A non parametric satistical test for a single signal pair and a single frequency bin". >> >> - Since my interest is in the coherence difference for a single signal pair, I can choose [|C1(f)|-|C2(f)|] as a test statistic. >> >> - And I can perform the montecarlo simulation. >> >> My question is the following : How can I implement the nonparametric test of the coherence difference between my 2 conditions with the fieldtrip functions ? >> >> This is what I did : >> >> 1) Extract and preprocess the signal from my condition 1. >> >> 2) freq1= ft_freqanalysis(cfg, signal1) (with cfg.method='mtmfft', cfg.output='powandcsd') → >> >> 3) coh1= ft_connectivityanalysis(cfg, freq1) >> >> I did the same thing for the other condition → coh2. >> >> And then for the statistics : >> >> cfg = []; >> >> cfg.statistic = 'diff'; (% because the statistic test than I chose is the difference [|C1(f)|-|C2(f)|]) >> >> cfg.parameter='cohspctrm'; >> >> cfg.method = 'montecarlo'; >> >> cfg.numrandomization = 1000; >> >> cfg.ivar = 1; >> >> cfg.alpha=0.05; >> >> cfg.tail=0; >> >> cfg.correcttail='alpha'; >> >> stat=ft_freqstatistics(cfg, coh1, coh2); >> >> And it gives me the following error : >> >> Error using ft_checkconfig (line 153) >> >> The field cfg.design is required. >> >> Here, I really don't understand why I'm asked for the design matrix... When doing the statistics for the Power, I understood that the design matrix was telling which trial belonged to the condition 1 and which trial belonged to the condition 2. But here, it doesn't make any sense because my coherence was calculated by averaging on the trials... >> >> Does the design matrix mean something differently here ? Or maybe I forgot one parameter to put in the cfg ? >> >> Any help will be appreciated ! >> >> Thanks a lot for your time, >> >> Laetitia Lalla >> >> PhD student in Neurosciences >> >> INMED, Marseille, France >> >> _______________________________________________ >> 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 -------------- next part -------------- An HTML attachment was scrubbed... URL: From rmontefusco at med.uchile.cl Mon Apr 4 14:17:12 2016 From: rmontefusco at med.uchile.cl (Rodrigo Montefusco) Date: Mon, 4 Apr 2016 09:17:12 -0300 Subject: [FieldTrip] Question about coherence statistics In-Reply-To: <17c319aeab6f35a621fb193e8b051792@inserm.fr> References: <2595287eebb0aeacfe5761a9de10de24@inserm.fr> <68a5ba763224075e6d9ec9aa7684221a@inserm.fr> <815A9820E75FBC4F96B7CD3A8089D11C378AE3E0@exprd04.hosting.ru.nl> <815A9820E75FBC4F96B7CD3A8089D11C378AE4DA@exprd04.hosting.ru.nl> <17c319aeab6f35a621fb193e8b051792@inserm.fr> Message-ID: Hi Laetitia, What you may try is to perform a "manual" permutation of your conditions before calculation of the coherence, and subtract the values of both randomized conditions... do that many....many many many times (1000 or above depending on your alpha...but as you have not many trials, do the math on how many you will need)...and you will end up with a distribution of difference coherence values. Then,based on your hypothesis, you can set a percentile threshold. Then subtract your original coherence values and check if they are under or over the threshold. If somebody find this is not correct, please let me know with an explanation! :) Best regards. YOGUI ps: best mail list ever! On Mon, Apr 4, 2016 at 6:45 AM, wrote: > Hey Tineke, > > Thank you very much ! It's all clear now. I was stuck with the list of > statistics described in the "help" of freqstatistics and I did not even > though of browsing the ft_statfun_XXX functions. I'm gonna try this right > away. > > Have a nice day, > > > > Laetitia Lalla > > PhD student in Neurosciences > > INMED, Marseille, France > > > > On 01-04-2016 12:03, Snijders, T.M. (Tineke) wrote: > > Hi Laetitia, > > Indeed, as 'coh' doesn't have the trial information anymore after > ft_connectivityanalysis, you can't use it as input for ft_freqstatistics if > you only have one subject. > > Indeed, giving 'cohspctrm' as parameter with your freq data doesn't work > as 'cohspctrm' is not in your freq data. The cfg.parameter specifies what > data to use for the randomization, so that parameter should be in the data > you give as input. > > You can use the freq data as input for freq_statistics, but then you have > to change your cfg.statistic. This is the statistical function that is > called after shuffling your trials - in your case after shuffling your > trials the coherence has to be computed and the difference between > conditions calculated. As far as I know, if you set your cfg.statistic to > 'diff_itc', it will compute the difference in the inter-trial coherence > between two conditions (looking at the phase consistency over trials). > > Best, > Tineke > > ------------------------------ > *From:* laetitia.lalla at inserm.fr [laetitia.lalla at inserm.fr] > *Sent:* Thursday, March 31, 2016 3:22 PM > *To:* FieldTrip discussion list > *Cc:* Snijders, T.M. (Tineke) > *Subject:* Re: [FieldTrip] Question about coherence statistics > > > Dear Tineke, > > thank you very much for your fast answer ! I'm not sure I understand what > you mean though... Maybe i did not express myself correctly. I do have > individual trial data : I have 26 observations for condition 1 and 26 > observations for condition 2. > > They appear : > > - In my structure "data" (output of ft_preprocessing) : data.trial is a > cell {1 x nbtrials} (in my case : {1, 26}) > > - in my structure "freq" (output of ft_freqanalysis) : freq.powspctrm is a > matrix of dimension : nbtrials X nbchannel X nbfreq (in my case 26x2x25) > > But I don't have this information anymore in the structure "coh" (output > of ft_connectivityanalysis) : coh.cospctrm is a matrix of dimension > nbchannelcmb x nbfreq (in my case 1x25) since the coherence is calculated > by averaging over trials... > > > > You may mean I should give the "freq" structures as inputs to the fonction > ft_freqstatistics ? > > I just tried that : I created a structure data_all by concatenated > data1.trial and data2.trial (and every other appropriate attribute). I took > the Time Frequency Representation with ft_freqanalysis (with > keeptrials='yes') to obtain a structure TFR_all (following this tutorial : > http://www.fieldtriptoolbox.org/tutorial/natmeg/statistics This is > actually how I did the statistics for the Power). > > But then, if I give this as an input to ft_freqstatistics, like this : > > cfg = []; > cfg.statistic = 'diff'; > cfg.parameter='cohspctrm'; > cfg.design= [ones(1,nbtrial)) 2*ones(1, nbtrial))]; %same nb of trials for > both condition > cfg.method = 'montecarlo'; > cfg.numrandomization = 1000; > cfg.ivar = 1; > cfg.alpha=0.05; > cfg.tail=0; > cfg.correcttail='alpha'; > >> stat=ft_freqstatistics(cfg, FR_alltrials); > > I have the following error : > > Error using getdimord (line 15) > field "cohspctrm" not present in data > > which makes a lot of sense, since I did not gave coherence as an input... > I gave Frequency representations.. I was hoping that maybe the function > would calculate the coherence itself for the statistics ? ^^ But it's > clearly not the way to go. > > > > Could you be a bit more explicit about what you meant ? > > > > Thanks a lot. > > Best, > > Laetitia Lalla > > PhD student in Neurosciences > > INMED, Marseille, France > > > > > > On 31-03-2016 13:47, Snijders, T.M. (Tineke) wrote: > > Hi Laetitia, > > If you only have one subject you do need individual trial data, otherwise > you can't do statistics like this. > You need multiple observations (either subjects or trials). > > Best, > Tineke > > ------------------------------ > *From:* fieldtrip-bounces at science.ru.nl [fieldtrip-bounces at science.ru.nl] > on behalf of laetitia.lalla at inserm.fr [laetitia.lalla at inserm.fr] > *Sent:* Thursday, March 31, 2016 1:11 PM > *To:* fieldtrip at science.ru.nl > *Subject:* [FieldTrip] Question about coherence statistics > > > Dear FielTrip community, > > Sorry to bother you again... > > I have a question about the statistical testing to assess coherence > differences and the related paper by E Maris, JM Schoffelen and P Fries > (Journal of Neuroscience Methods, 2007) > > I believe I am exactly in the framework described in this paper, but I > guess there is still some crucial information that I don't understand... > > > > This is my story : > > - It's a single-subject study > > - I want to compare two sets of trials observed in different conditions. > > - The 2 sets of trials are exactly the same size, so my coherence estimate > won't be biased by the "unequal sample size problem". > > - I just want to compare for 1 channel pair, for 1 frequency bin [6Hz > 10Hz], so I guess the Multiple Comparison problem won't affect my analysis > too much (either in the spatial or the spectral dimension). > > > > Based on the paper, I could refer myself to the point "2.7.1. A non > parametric satistical test for a single signal pair and a single frequency > bin". > > - Since my interest is in the coherence difference for a single signal > pair, I can choose [|C1(f)|-|C2(f)|] as a test statistic. > > - And I can perform the montecarlo simulation. > > > > My question is the following : How can I implement the nonparametric test > of the coherence difference between my 2 conditions with the fieldtrip > functions ? > > > > This is what I did : > > 1) Extract and preprocess the signal from my condition 1. > > 2) freq1= ft_freqanalysis(cfg, signal1) (with cfg.method='mtmfft', > cfg.output='powandcsd') → > > 3) coh1= ft_connectivityanalysis(cfg, freq1) > > > > I did the same thing for the other condition → coh2. > > > > And then for the statistics : > > cfg = []; > > cfg.statistic = 'diff'; (% because the statistic test than I chose is the > difference [|C1(f)|-|C2(f)|]) > > cfg.parameter='cohspctrm'; > > cfg.method = 'montecarlo'; > > cfg.numrandomization = 1000; > > cfg.ivar = 1; > > cfg.alpha=0.05; > > cfg.tail=0; > > cfg.correcttail='alpha'; > > stat=ft_freqstatistics(cfg, coh1, coh2); > > > > And it gives me the following error : > > Error using ft_checkconfig (line 153) > > The field cfg.design is required. > > > > Here, I really don't understand why I'm asked for the design matrix... > When doing the statistics for the Power, I understood that the design > matrix was telling which trial belonged to the condition 1 and which trial > belonged to the condition 2. But here, it doesn't make any sense because my > coherence was calculated by averaging on the trials... > > Does the design matrix mean something differently here ? Or maybe I forgot > one parameter to put in the cfg ? > > > > Any help will be appreciated ! > > > > Thanks a lot for your time, > > > > Laetitia Lalla > > PhD student in Neurosciences > > INMED, Marseille, France > > > > > > > > > _______________________________________________ > 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 > > > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From wanyu at gazzaleylab.ucsf.edu Mon Apr 4 20:15:12 2016 From: wanyu at gazzaleylab.ucsf.edu (WanYu Hsu) Date: Mon, 4 Apr 2016 11:15:12 -0700 Subject: [FieldTrip] questions about power spectrum analysis and bootstrp Message-ID: Hi community, I am recently running EEG power spectrum analysis. For some reason, I wanted to run the analysis with bootstrapped trials. Is there anyway to apply bootstrap with ft_freqanalysis? I tried adding bootstrap option in ft_sourceanalysis to ft_freqanalysis, but it doesn't work. cfg = []; cfg.foi = 2:30; cfg.method = 'mtmconvol'; cfg.taper = 'hanning'; cfg.keeptrials = 'no'; cfg.t_ftimwin = 3.2 ./ cfg.foi; cfg.toi = -0.5:0.01:0.6; cfg.output = 'powandcsd'; cfg.bootstrap = 'yes'; cfg.numbootstrap = 25; % cfg.trials = 'all'; freq2{s} = ft_freqanalysis(cfg, data_concat_TFR(s)); Any help would be appreciated. Best, WanYu Hsu -------------- next part -------------- An HTML attachment was scrubbed... URL: From gina.joue at univr.it Tue Apr 5 10:51:53 2016 From: gina.joue at univr.it (gj) Date: Tue, 5 Apr 2016 10:51:53 +0200 Subject: [FieldTrip] Error with interpn when calling, ft_sourceinterpolate In-Reply-To: References: Message-ID: <57037CA9.1030602@univr.it> Hi, I just noticed that I had messed up the message threading (no easy way to keep threading as I only receive a daily digest), and I wanted to leave feedback for future reference that the problem was indeed, as you pointed out Jan-Mathijs, because of the incompatible resolution of the template grid I was using -- once I loaded one with a different resolution (standard_sourcemodel3d10mm.mat instead of standard_sourcemodel3d5mm.mat in my case), I didn't get the error anymore. Thanks a lot, Jan-Mathijs!!! g > Message: 4 > Date: Tue, 29 Mar 2016 07:50:05 +0000 > From: "Schoffelen, J.M. (Jan Mathijs)" > To: FieldTrip discussion list > Subject: Re: [FieldTrip] fieldtrip Digest, Vol 64, Issue 32 > Message-ID: > Content-Type: text/plain; charset="utf-8" > > Hi Gina, > > That?s what I was afraid of. By replacing the .pos and .dim you made the data structure inconsistent. The number of source positions should be kept constant, i.e. you need to use a ?template grid? that is defined at the same approximate spatial resolution as your individual grids. The reason for this is that the numeric data (e.g. in source.avg.pow) should have the same number of elements as the size(source.pos,1). > > Best, > Jan-Mathijs > > ------------------------------ > > Message: 3 > Date: Tue, 29 Mar 2016 09:16:29 +0200 > From: gj > To: fieldtrip at science.ru.nl > Subject: Re: [FieldTrip] fieldtrip Digest, Vol 64, Issue 32 > Message-ID: <56FA2BCD.7010201 at univr.it> > Content-Type: text/plain; charset=windows-1252; format=flowed > > Hi Jan-Mathijs, > > Before replacing them with the values from the template grid, > source_proj.dim is 1-row matrix = [15,18,13] > and > source_proj.pos a 3510x3 matrix of doubles > > > After, it's > source_proj.dim is a 1-row matrix = [32,39,34] > and > source_proj.pos is a 42432x3 matrix of doubles > > Thanks! > Gina From maity_winky at yahoo.es Tue Apr 5 14:13:43 2016 From: maity_winky at yahoo.es (=?UTF-8?Q?Mait=C3=A9_Crespo_Garc=C3=ADa?=) Date: Tue, 5 Apr 2016 12:13:43 +0000 (UTC) Subject: [FieldTrip] questions about power spectrum analysis and bootstrp In-Reply-To: References: Message-ID: <25792913.5051433.1459858423045.JavaMail.yahoo@mail.yahoo.com> Dear WanYu Hsu, For frequency analysis, it seems to be implemented differently. You can first compute power and csd values with ft_freqanalysis and then access the bootstrap option with ft_freqstatistics calling the Montecarlo method. Would that way work for you? Best,Maite El Lunes 4 de abril de 2016 20:36, WanYu Hsu escribió: Hi community, I am recently running EEG power spectrum analysis. For some reason, I wanted to run the analysis with bootstrapped trials. Is there anyway to apply bootstrap with ft_freqanalysis? I tried adding bootstrap option in ft_sourceanalysis to ft_freqanalysis, but it doesn't work. cfg = []; cfg.foi         = 2:30; cfg.method = 'mtmconvol'; cfg.taper     = 'hanning'; cfg.keeptrials = 'no'; cfg.t_ftimwin  = 3.2 ./ cfg.foi; cfg.toi            = -0.5:0.01:0.6; cfg.output      = 'powandcsd'; cfg.bootstrap = 'yes'; cfg.numbootstrap  =  25; % cfg.trials = 'all'; freq2{s} = ft_freqanalysis(cfg, data_concat_TFR(s)); Any help would be appreciated. Best, WanYu Hsu _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From r.thomas at nin.knaw.nl Wed Apr 6 15:10:10 2016 From: r.thomas at nin.knaw.nl (Rajat Thomas) Date: Wed, 6 Apr 2016 13:10:10 +0000 Subject: [FieldTrip] FEM using Simbio Message-ID: <1459948210999.59028@nin.knaw.nl> Dear all, Has anyone used the FEM approach to Headmodels using Simbio recently? If so, I get this error: "Elements have wrong orientation or are degenerated" Any ideas? cfg = []; cfg.method ='simbio'; cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows mesh.tissyelabel vol = ft_prepare_headmodel(cfg, mesh); And; ? disp(mesh) hex: [545883x8 double] pnt: [569722x3 double] labels: [545883x1 double] tissue: [545883x1 double] tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} unit: 'mm' cfg: [1x1 struct] Any help would be highly appreciated. Rajat Rajat Mani Thomas Social Brain Lab Netherlands Institute for Neuroscience Amsterdam -------------- next part -------------- An HTML attachment was scrubbed... URL: From carsten.wolters at uni-muenster.de Wed Apr 6 16:03:09 2016 From: carsten.wolters at uni-muenster.de (Carsten Wolters) Date: Wed, 6 Apr 2016 16:03:09 +0200 Subject: [FieldTrip] FEM using Simbio In-Reply-To: <1459948210999.59028@nin.knaw.nl> References: <1459948210999.59028@nin.knaw.nl> Message-ID: <5705171D.3050306@uni-muenster.de> Dear Rajat, the element-node cards of SimBio-NeuroFEM need to follow certain orientations (see www.simbio.de). If you do not want to struggle with meshing/ordering, use the SimBio-VGRID mesher http://vgrid.simbio.de/ that follows the required ordering of nodes. You might use this mesher to produce 1mm geometry-adapted FEM meshes that show good overall performance, see http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf and http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf (latter was just accepted by NeuroImage). Best regards Carsten Am 06.04.2016 um 15:10 schrieb Rajat Thomas: > > Dear all, > > > Has anyone used the FEM approach to Headmodels using Simbio recently? > > > If so, I get this error: > > "Elements have wrong orientation or are degenerated" > > Any ideas? > > cfg = []; > > cfg.method ='simbio'; > > cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows > mesh.tissyelabel > > vol = ft_prepare_headmodel(cfg, mesh); > > > And; > > ​ > > disp(mesh) > hex: [545883x8 double] > pnt: [569722x3 double] > labels: [545883x1 double] > tissue: [545883x1 double] > tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} > unit: 'mm' > cfg: [1x1 struct] > > > Any help would be highly appreciated. > > Rajat > > > > > > > Rajat Mani Thomas > Social Brain Lab > Netherlands Institute for Neuroscience > Amsterdam > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: carsten_wolters.vcf Type: text/x-vcard Size: 402 bytes Desc: not available URL: From s.homolle at donders.ru.nl Wed Apr 6 17:13:42 2016 From: s.homolle at donders.ru.nl (Simon Homolle) Date: Wed, 6 Apr 2016 17:13:42 +0200 Subject: [FieldTrip] FEM using Simbio In-Reply-To: <1459948210999.59028@nin.knaw.nl> References: <1459948210999.59028@nin.knaw.nl> Message-ID: <41AC91C9-638C-4B4E-B19F-933D96A76249@donders.ru.nl> Dear Rajat, could you please describe how you generated your mesh? Bests, Simon Homölle PhD Candidate Donders Institute for Brain, Cognition and Behaviour Centre for Cognitive Neuroimaging Radboud University Nijmegen Phone: +31-(0)24-36-65059 > On 06 Apr 2016, at 15:10, Rajat Thomas wrote: > > Dear all, > > Has anyone used the FEM approach to Headmodels using Simbio recently? > > If so, I get this error: > "Elements have wrong orientation or are degenerated" > > Any ideas? > > cfg = []; > cfg.method ='simbio'; > cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows mesh.tissyelabel > vol = ft_prepare_headmodel(cfg, mesh); > > And; > ​ > disp(mesh) > hex: [545883x8 double] > pnt: [569722x3 double] > labels: [545883x1 double] > tissue: [545883x1 double] > tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} > unit: 'mm' > cfg: [1x1 struct] > > Any help would be highly appreciated. > > Rajat > > > > > > > Rajat Mani Thomas > Social Brain Lab > Netherlands Institute for Neuroscience > Amsterdam > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From gina.joue at univr.it Wed Apr 6 17:42:47 2016 From: gina.joue at univr.it (gj) Date: Wed, 6 Apr 2016 17:42:47 +0200 Subject: [FieldTrip] ft_source2sparse usage for EEG data Message-ID: <57052E77.5070709@univr.it> Hi FieldTrip community, Sorry for the onslaught of newbie questions. I would like to run a whole-brain network analysis on source level on a 2-sec continuous recording of EEG data. Following the tutorials (for MEG), I first run ft_source2sparse to reduce the matrix to only voxels inside the skull: >> source_sparse = ft_source2sparse(source_proj); total number of dipoles : 6804 number of dipoles inside brain: 3294 number of dipoles outside brain: 3510 When I then try to run the connectivity analysis (ft_connectivityanalysis), regardless of which connectivity method, I get the error: ---- error --- Requested 92232x92232 (126.8GB) array exceeds maximum array size preference. Creation of arrays greater than this limit may take a long time and cause MATLAB to become unresponsive. See array size limit or preference panel for more information. Error in univariate2bivariate (line 314) data.crsspctrm = (transpose(mom)*conj(mom))./nrpt; Error in ft_connectivityanalysis (line 434) [data, powindx, hasrpt] = univariate2bivariate(data, 'mom', 'crsspctrm', dtype, 'cmb', cfg.refindx, 'keeprpt', 0); ----end error--- I guess it is related to how I might have created the sourcemodel (ft_freqanalysis run with method='mtmfft', output='fourier', keeptrials='yes')? I am using FieldTrip ver.20160309. Thank you very much in advance for any help! Gina From pmetzak at gmail.com Thu Apr 7 01:47:49 2016 From: pmetzak at gmail.com (Paul Metzak) Date: Wed, 6 Apr 2016 16:47:49 -0700 Subject: [FieldTrip] TFR plotting following ft_freqbaseline Message-ID: Hello Fieldtrippers, I have a quick question about the output from my ft_freqanalysis. I ran ft_freqbaseline but when I plot the TFR using TFRmultiplot, I still have activity in the baseline period. I have included the cfg for the ft_freqanalysis call as well as the cfg for the ft_freqbaseline call and a .png from one of the sensors with this message. I took a look at the TFR plots for the pre- and post- ft_freqbaseline call and they look different so it is doing it's job but I am just wondering if activity in the baseline period represents a problem with the way I have analyzed my data thus far, or whether it is a normal result in fairly rapid MEG designs. Thanks for any information you can offer! Paul %%% ft_freqanalysis cfg %%%% tstep: 0.0500 twindow: 0.5000 fLow: 2 fHigh: 160 fstep: 2 method: 'mtmconvol' taper: 'hanning' rmvbl: 'yes' bltype: 'absolute' baseline: [-0.5000 0] trlbegin: -1 trlend: 2 conditions: [1 2 3] output: 'powandcsd' runname: 'run1' foi: [1x80 double] t_ftimwin: [80x1 double] toi: [1x51 double] %%% ft_freqbaseline cfg %%%% baseline: [-0.5000 0] baselinetype: 'absolute' -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: baseline_corr_prob.png Type: image/png Size: 10004 bytes Desc: not available URL: From carsten.wolters at uni-muenster.de Thu Apr 7 09:22:10 2016 From: carsten.wolters at uni-muenster.de (Carsten Wolters) Date: Thu, 7 Apr 2016 09:22:10 +0200 Subject: [FieldTrip] FEM using Simbio In-Reply-To: <5705171D.3050306@uni-muenster.de> References: <1459948210999.59028@nin.knaw.nl> <5705171D.3050306@uni-muenster.de> Message-ID: <57060AA2.8040804@uni-muenster.de> Dear Rajat, if you want to use another meshing tool than VGRID, the element-node-ordering of SimBio-NeuroFEM can be downloaded here: http://www.sci.utah.edu/~wolters/SimBio/SimBioNeuroFEMElementNodeOrdering0001.pdf For regular cubic elements and geometry-adapted cubic elements, please see the ordering of x23. I hope this will finally fully answer your question. Best regards Carsten Am 06.04.2016 um 16:03 schrieb Carsten Wolters: > Dear Rajat, > > the element-node cards of SimBio-NeuroFEM need to follow certain > orientations (see www.simbio.de). > > If you do not want to struggle with meshing/ordering, use the > SimBio-VGRID mesher > http://vgrid.simbio.de/ > that follows the required ordering of nodes. You might use this mesher > to produce 1mm geometry-adapted FEM meshes > that show good overall performance, see > http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf > and > http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf > (latter was just accepted by NeuroImage). > > Best regards > Carsten > > Am 06.04.2016 um 15:10 schrieb Rajat Thomas: >> >> Dear all, >> >> >> Has anyone used the FEM approach to Headmodels using Simbio recently? >> >> >> If so, I get this error: >> >> "Elements have wrong orientation or are degenerated" >> >> Any ideas? >> >> cfg = []; >> >> cfg.method ='simbio'; >> >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows >> mesh.tissyelabel >> >> vol = ft_prepare_headmodel(cfg, mesh); >> >> >> And; >> >> ​ >> >> disp(mesh) >> hex: [545883x8 double] >> pnt: [569722x3 double] >> labels: [545883x1 double] >> tissue: [545883x1 double] >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >> unit: 'mm' >> cfg: [1x1 struct] >> >> >> Any help would be highly appreciated. >> >> Rajat >> >> >> >> >> >> >> Rajat Mani Thomas >> Social Brain Lab >> Netherlands Institute for Neuroscience >> Amsterdam >> >> >> _______________________________________________ >> 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 -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: carsten_wolters.vcf Type: text/x-vcard Size: 402 bytes Desc: not available URL: From j.herring at donders.ru.nl Thu Apr 7 10:35:41 2016 From: j.herring at donders.ru.nl (Herring, J.D. (Jim)) Date: Thu, 7 Apr 2016 08:35:41 +0000 Subject: [FieldTrip] TFR plotting following ft_freqbaseline In-Reply-To: References: Message-ID: <3D00B7615FB58D46A0B49B9AD67A33EB3D98D61D@exprd01.hosting.ru.nl> Dear Paul, You can check whether the baseline correction worked by seeing whether the mean in the baseline per frequency is zero. If your frequency data is contained in the structure ‘freq’ you could do something like the following: baseline = [-.5 0]; channel_idx = find(strcmp(freq.label,’MLO11’)); time_idx = find(freq.time>=baseline(1)&freq.time<=baseline(2)); mean_baseline = nanmean(freq.powspctrm(channel_idx,:,time_idx),3); ‘mean_baseline’ should be roughly around zero for all frequencies. I suspect that the positive activity at/slightly before zero cancels the negative activity around -500 to -400. Here it is important to realize that whenever you are calculating a time-frequency analysis you are moving a sliding time-window over your data. The value at time-point zero therefore represent the power at that particular frequency from minus to plus half of the chosen window length. Given that your time-window is 500ms, the data at time-point zero therefore reflects the power from [-250 – 250ms]. It is therefore very likely that it contains stimulus-related activity. If you want to be sure that your baseline data does not represent any stimulus-related activity you should choose a baseline period earlier than, or at -250 ms (ie. Half your sliding time window size). Best, Jim From: fieldtrip-bounces at science.ru.nl [mailto:fieldtrip-bounces at science.ru.nl] On Behalf Of Paul Metzak Sent: Thursday, April 07, 2016 1:48 AM To: fieldtrip at science.ru.nl Subject: [FieldTrip] TFR plotting following ft_freqbaseline Hello Fieldtrippers, I have a quick question about the output from my ft_freqanalysis. I ran ft_freqbaseline but when I plot the TFR using TFRmultiplot, I still have activity in the baseline period. I have included the cfg for the ft_freqanalysis call as well as the cfg for the ft_freqbaseline call and a .png from one of the sensors with this message. I took a look at the TFR plots for the pre- and post- ft_freqbaseline call and they look different so it is doing it's job but I am just wondering if activity in the baseline period represents a problem with the way I have analyzed my data thus far, or whether it is a normal result in fairly rapid MEG designs. Thanks for any information you can offer! Paul %%% ft_freqanalysis cfg %%%% tstep: 0.0500 twindow: 0.5000 fLow: 2 fHigh: 160 fstep: 2 method: 'mtmconvol' taper: 'hanning' rmvbl: 'yes' bltype: 'absolute' baseline: [-0.5000 0] trlbegin: -1 trlend: 2 conditions: [1 2 3] output: 'powandcsd' runname: 'run1' foi: [1x80 double] t_ftimwin: [80x1 double] toi: [1x51 double] %%% ft_freqbaseline cfg %%%% baseline: [-0.5000 0] baselinetype: 'absolute' -------------- next part -------------- An HTML attachment was scrubbed... URL: From j.vorwerk at uni-muenster.de Thu Apr 7 14:25:42 2016 From: j.vorwerk at uni-muenster.de (Johannes Vorwerk) Date: Thu, 7 Apr 2016 14:25:42 +0200 Subject: [FieldTrip] FEM using Simbio In-Reply-To: <5705171D.3050306@uni-muenster.de> References: <1459948210999.59028@nin.knaw.nl> <5705171D.3050306@uni-muenster.de> Message-ID: <435735E3-7D87-4DD6-A2C1-E2BBFBBF4B44@googlemail.com> Hi, this question was already answered in this thread http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html If ft_volumereslice is not applied before the mesh generation, the afterwards applied transformation might flip the directions of the mesh, leading to the described error. Best, Johannes > Am 06.04.2016 um 16:03 schrieb Carsten Wolters : > > Dear Rajat, > > the element-node cards of SimBio-NeuroFEM need to follow certain orientations (see www.simbio.de ). > > If you do not want to struggle with meshing/ordering, use the SimBio-VGRID mesher > http://vgrid.simbio.de/ > that follows the required ordering of nodes. You might use this mesher to produce 1mm geometry-adapted FEM meshes > that show good overall performance, see > http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf > and > http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf > (latter was just accepted by NeuroImage). > > Best regards > Carsten > > Am 06.04.2016 um 15:10 schrieb Rajat Thomas: >> Dear all, >> >> Has anyone used the FEM approach to Headmodels using Simbio recently? >> >> If so, I get this error: >> "Elements have wrong orientation or are degenerated" >> >> Any ideas? >> >> cfg = []; >> cfg.method ='simbio'; >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows mesh.tissyelabel >> vol = ft_prepare_headmodel(cfg, mesh); >> >> And; >> ​ >> disp(mesh) >> hex: [545883x8 double] >> pnt: [569722x3 double] >> labels: [545883x1 double] >> tissue: [545883x1 double] >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >> unit: 'mm' >> cfg: [1x1 struct] >> >> Any help would be highly appreciated. >> >> Rajat >> >> >> >> >> >> >> Rajat Mani Thomas >> Social Brain Lab >> Netherlands Institute for Neuroscience >> Amsterdam >> >> >> _______________________________________________ >> 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 -------------- next part -------------- An HTML attachment was scrubbed... URL: From michelic72 at gmail.com Thu Apr 7 17:36:37 2016 From: michelic72 at gmail.com (Cristiano Micheli) Date: Thu, 7 Apr 2016 17:36:37 +0200 Subject: [FieldTrip] FEM using Simbio In-Reply-To: <1459948210999.59028@nin.knaw.nl> References: <1459948210999.59028@nin.knaw.nl> Message-ID: Hi Rajat My guess is that the orientations of your hexahedrons are not correct. According to a low-level file's internal rules, elements' orientations have to abide strict rules (not sure what exactly the contraints are in this case though...). I had same problems when for example the triangular boundaries used to define the 3d hexahedral mesh were not topologically correct, to start with. Admittedly this approach requires a lot of technical expertise. Can I ask you what do you need a FEM model for? Regards Cris Micheli On Wed, Apr 6, 2016 at 3:10 PM, Rajat Thomas wrote: > Dear all, > > > Has anyone used the FEM approach to Headmodels using Simbio recently? > > > If so, I get this error: > "Elements have wrong orientation or are degenerated" > > Any ideas? > > cfg = []; > > cfg.method ='simbio'; > > cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows > mesh.tissyelabel > > vol = ft_prepare_headmodel(cfg, mesh); > > > And; > > ​ > disp(mesh) > hex: [545883x8 double] > pnt: [569722x3 double] > labels: [545883x1 double] > tissue: [545883x1 double] > tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} > unit: 'mm' > cfg: [1x1 struct] > > > Any help would be highly appreciated. > > Rajat > > > > > > > Rajat Mani Thomas > Social Brain Lab > Netherlands Institute for Neuroscience > Amsterdam > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From giovannipellegrino at gmail.com Thu Apr 7 21:02:05 2016 From: giovannipellegrino at gmail.com (Giovanni Pellegrino) Date: Thu, 7 Apr 2016 15:02:05 -0400 Subject: [FieldTrip] Dipole fitting Message-ID: Dear Fieldtrippers, Do you know if the FieldTrip Dipole Fitting has been compared to the CTF, Elekta, BESA or Curry? Are you aware of any study on this topic? Thanks in advance for your help Giovanni -- Giovanni Pellegrino, MD Multimodal Functional Imaging Laboratory Montreal Neurological Institute, McGill University Address: 332 Duff Medical Building, 3775 rue University, Montreal, QC, H3A 2B4, Canada Phone: (514) 398–1678 Fax: (514) 398–7461 Email: giovannipellegrino at gmail.com, giovanni.pellegrino2 at mcgill.ca Homepage: http://www.bic.mni.mcgill.ca/ResearchLabsMFIL/PeopleGiovanni -------------- next part -------------- An HTML attachment was scrubbed... URL: From ole.jensen at donders.ru.nl Fri Apr 8 09:23:46 2016 From: ole.jensen at donders.ru.nl (Ole Jensen) Date: Fri, 8 Apr 2016 09:23:46 +0200 Subject: [FieldTrip] Birmingham-Illinois BRIDGE Fellowships Message-ID: <57075C82.8030309@donders.ru.nl> Dear all, I would like to point you to a set of Birmingham-Illinois BRIDGE Fellowships providing some exciting research and career prospects: http://www.birminghamillinoisbridge.org/index.php/fellows/ In particular the areas 'Cognition and Ageing' and 'Brain Trauma' could be relevant for candidates with EEG/MEG expertise. All the best, Ole -- Prof. dr. Ole Jensen http://www.neuosc.com From laetitia.lalla at inserm.fr Fri Apr 8 10:27:58 2016 From: laetitia.lalla at inserm.fr (laetitia.lalla at inserm.fr) Date: Fri, 08 Apr 2016 10:27:58 +0200 Subject: [FieldTrip] Using FieldTrip to analyse LFP recordings in rat In-Reply-To: References: <2595287eebb0aeacfe5761a9de10de24@inserm.fr> <68a5ba763224075e6d9ec9aa7684221a@inserm.fr> <815A9820E75FBC4F96B7CD3A8089D11C378AE3E0@exprd04.hosting.ru.nl> <815A9820E75FBC4F96B7CD3A8089D11C378AE4DA@exprd04.hosting.ru.nl> <17c319aeab6f35a621fb193e8b051792@inserm.fr> Message-ID: <628babdc107aebd4cc7588ea87ce5ea6@inserm.fr> Hello everyone, my name is Laetitia and I'm a Phd student in Marseille (France). I'm doing in-vivo recording in freely-moving rats : I implant them with 2 electrodes deep into 2 different regions of the brain. I'm studying the Local Field Potentials and I want to use FieldTrip to analyse the data. To simplify : - I have 2 rats. - Each rat did 20 sessions of the task (on 20 different days). - Each session consists of 20 trials of condition 1 and 20 trials of condition 2. I have 2 questions. 1) I have the feeling it would be meaningless to do "source reconstruction" because my electrodes are already deep inside my "source" and the LFP I am recording is very local. (My electrodes have 32 channels separated by 20-200 µm. The LFP is very very similar across all the channels, so I averaged over the 32 channels to have one signal for each region.) However, I see that 2 different functions exist for the statistics : FT_FREQSTATISTICS AND FT_SOURCESTATISTICS. So far, I've been using ft_freqstatistics but I encounter some issues (for exemple, doing monte-carlo permutation test to assess the imaginary coherence). I thought of computing it manually, but I'm thinking that maybe more stuff are implemented in ft_sourcestatisctics ? → Are these 2 functions fundamentally different or do they call the same sub-fonctions (and my problem has actually nothing to do with that) ? 2) I'm a bit confused with the vocabulary from EEG and MEG studies (I'm not used to it yet...). From what I understood, in human studies, you can do comparison for a single subject (across trials) or across subjects. But I have 3 levels of comparisons in my design : - WITHIN A SESSION, I WANT TO COMPARE ACROSS TRIALS (the 20 trials of condition 1 VS the 20 trials of condition 2). - WITHIN A RAT, I WANT TO COMPARE ACROSS SESSIONS (between the 2 conditions) - then - in the very end - ACROSS RATS. But I have only 2 rats so far, so I will deal with this later. I'm a bit confused when reading the tutorials and the mailing list, especially when it comes to the statistics... For example : this is from an email from 2013 by Eric Maris about "Nonparametric statistical testing of phase coherence" (http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006401.html) "To compare coherence between conditions across subjects (instead of trials), you need a different statfun: depsamplesT (for a within-subjects design; subjects have participated in all conditions) or indepsamplesT (for a between-subjects design; subjects have participated in only one condition)." → If I want to compare across sessions (for a same rat), can I actually consider that my different sessions are "subjects"? And then compare coherence "across subjects" would be doing it "across sessions" ? And I would be in a "within-subject design" since my sessions involve the 2 conditions every time ? I realise that it may be very confusing... I hope you will understand my problem ! And if anyone already applied fieldtrip functions to do statistics on a different framework that the usual EEG/MEG, please let me know ! Thanks a lot, Laetitia Lalla PhD Student in Neuroscience INMED, Marseille, France -------------- next part -------------- An HTML attachment was scrubbed... URL: From anne.urai at gmail.com Fri Apr 8 21:40:12 2016 From: anne.urai at gmail.com (Anne Urai) Date: Fri, 8 Apr 2016 21:40:12 +0200 Subject: [FieldTrip] ft_channelrepair with channel absent from data In-Reply-To: <6B298E85-A270-4D51-9219-F74A1C4B4AEE@donders.ru.nl> References: <50B23369.5020105@fcdonders.ru.nl> <50B33A53.2000701@donders.ru.nl> <6B298E85-A270-4D51-9219-F74A1C4B4AEE@donders.ru.nl> Message-ID: Dear FieldTrippers, I head a similar problem with interpolating missing channels from a CTF275 system. Since I couldn't find a final answer on the mailing list, I thought I'd share my solution. Specifically, giving both a cfg.layout and a cfg.neighbours input into ft_channelrepair avoids ft_fetch_sens getting the grad structure from the data (from which the channels that were not recorded are missing). With this setting, the sensors that are needed are defined based on the layout from the fieldtrip/templates directory, which is complete. Happy interpolating!  cfg = [];  cfg.layout = 'CTF275';  cfg.method = 'template';  neighbours = ft_prepare_neighbours(cfg);    cfg = [];  cfg.neighbours = neighbours;  cfg.method = 'spline'; % spline can handle missing grad struct  cfg.layout = 'CTF275'; % use this rather than grad structure to find sens info    % find missing channels in this dataset  cfg.missingchannel = {neighbours((~ismember({neighbours(:).label}, data.label))).label};  data = ft_channelrepair(cfg,data);  assert(length(data.label) == 275, 'CTF275 not completely interpolated!'); —  Anne E. Urai, MSc PhD student | Institut für Neurophysiologie und Pathophysiologie  Universitätsklinikum Hamburg-Eppendorf | Martinistrasse 52, 20246 | Hamburg, Germany  www.anneurai.net / @AnneEUrai From: Linsey Roijendijk Reply: FieldTrip discussion list Date: 20 December 2012 at 18:44:31 To: FieldTrip discussion list Subject:  Re: [FieldTrip] ft_channelrepair with channel absent from data Correction: I made a mistake in my e-mail, I meant the spherical spline interpolation method, because that's the one Jorn said should work. On Dec 20, 2012, at 6:31 PM, Linsey Roijendijk wrote: Hi all, I have also been trying to reinterpolate MEG channels that were never recorded with the nearest neighbour interpolation method, however when calling the method (in the same way Tom also used it) the function seems to do something, however it did not interpolate the missing sensors.  There were still 273 sensors instead of 275.  Do I need to give along a special cfg.grad or do something else? Thanks in advance, Linsey On Nov 26, 2012, at 10:45 AM, Jörn M. Horschig wrote:q Hey Tom, I guess I have several questions all at once: 1) Is it actually possible to reinterpolate MEG channels that were never recorded - eg because the channels were deactivated when the acquisition took place? Should work, but only with the SSI (=spherical spline interpolation) method. For the nearest neighbour interpolation, the function constructs a list of neuighbouring and constructs a weighted average. The function, however, wants to weigh each sensor according to its distance from the sensor to be reconstructed. That information can only be found in the grad structure, but in the grad structure there are only sensors which were recorded, thus the distance from a missing sensor cannot be measured because its position is missing in the grad structure. SSI should work though, cause it relies on a different rationale. 2) What might be causing the error I'm seeing? Since you have 301 channels rather than 275, my suspicion is that you include reference gradiometers. This should not fail in principle, though... maybe I can drop by your office to check it out? Got some time right now? 3) Where is ft_fetch_sens? It's a private function, can be found in FieldTrip/private. You have to cd to that directory in order for Matlab to find it (the idea behind private function is that there are only visible for higher-level function and 'hidden' for all other functions). Best, Jörn Thanks for help with any of the above! Best, Tom -- Tom Marshall, MSc. Neuronal Oscillations Group, Donders Centre for Cognitive Neuroimaging tel: +31(0)243668487 email: t.marshall at fcdonders.ru.nl postal: PO Box 9101, 6500HB, Nijmegen, The Netherlands visiting: Kapittelweg 29, 6525EN, Nijmegen, The Netherlands _______________________________________________ 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 -- Linsey Roijendijk MSc. Donders Institute for Brain, Cognition and Behaviour Centre for Neuroscience dept. of Biophysics Radboud University Nijmegen Montessorilaan 3, Room B.02.34 P.O.Box 9104 6500 HE Nijmegen The Netherlands Tel: +31(0)24 3612616 L.Roijendijk at donders.ru.nl _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -- Linsey Roijendijk MSc. Donders Institute for Brain, Cognition and Behaviour Centre for Neuroscience dept. of Biophysics Radboud University Nijmegen Montessorilaan 3, Room B.02.34 P.O.Box 9104 6500 HE Nijmegen The Netherlands Tel: +31(0)24 3612616 L.Roijendijk at donders.ru.nl _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From Max.Cantor at Colorado.EDU Fri Apr 8 23:02:17 2016 From: Max.Cantor at Colorado.EDU (Max Cantor) Date: Fri, 8 Apr 2016 15:02:17 -0600 Subject: [FieldTrip] TFR mask stats question; Baselined vs unbaselined statistics question Message-ID: Hi fieldtrippers, I have two unrelated stats questions, but I figured I'd post them together: 1. I've run within subjects permutation statistics testing the difference between an anomaly and control condition for three different language conditions; preposition, morphosyntax, and semantics. The code is nearly identical for both my ERPs and TFRs, except that when I plot my ERPs with cfg.maskparameter = 'mask', cfg.parameter = 'stat', and cfg.maskalpha = 0.025, it seems to multiplot just fine, whereas when I try to do the same for the TFRs, my multiplotted plots are blank, but when I comment out the mask, the stat plots are fine. I'll attach the code, but is there something I'm doing obviously wrong? Also, am I correct that my maskalpha should correspond to my alpha, and not my cluster alpha? This is the TFR code, but the ERP code is the exact same except for with timelocked data as the input and ft_timelockstatistics as the function. cfg = []; cfg.method = 'montecarlo'; cfg.statistic = 'depsamplesT'; cfg.correctm = 'cluster'; cfg.clusteralpha = 0.05; cfg.clusterstatistic = 'maxsum'; cfg.minnbchan = 2; cfg.neighbours = neighbours; cfg.tail = 0; cfg.clustertail = 0; cfg.alpha = 0.025; cfg.numrandomization = 1000; nsubj = length(tot_tfr2_bl{1}); design = zeros(2,2*nsubj); for i = 1:nsubj design(1,i) = i; end for i = 1:nsubj design(1,nsubj+i) = i; end design(2,1:nsubj) = 1; design(2,nsubj+1:2*nsubj) = 2; cfg.design = design; cfg.uvar = 1; cfg.ivar = 2; % Anomaly vs Control stat_tfr{1} = ft_freqstatistics(cfg, tot_tfr2_bl{1}{:}, tot_tfr2_bl{2}{:}); % Preposition stat_tfr{2} = ft_freqstatistics(cfg, tot_tfr2_bl{3}{:}, tot_tfr2_bl{4}{:}); % Semantics stat_tfr{3} = ft_freqstatistics(cfg, tot_tfr2_bl{5}{:}, tot_tfr2_bl{6}{:}); % Morphosyntax This is the plotting code. Again, it is virtually the same for the ERPs except the non-stats configurations would be what makes sense for ERPs. % Anomaly vs Control TFR stats multiplot cfg = []; cfg.xlim = [-0.2 1]; cfg.zlim = [-3 3]; % proportion from baseline cfg.layout = [max_dir '/quickcap64.mat']; cfg.maskparameter = 'mask'; cfg.parameter = 'stat'; cfg.maskalpha = 0.025; ft_multiplotTFR(cfg, stat_tfr{1}); title('Preposition'); ft_multiplotTFR(cfg, stat_tfr{3}); title('Semantic'); ft_multiplotTFR(cfg, stat_tfr{5}); title('Morphosyntactic'); 2. The second question is about analyzing baselined vs unbaselined data. I've seen in the tutorials that there is a somewhat different method for analyzing trial vs baseline period. However, what I've done instead (for both ERP and TFR), is use the same within-subjects statistics as with anomaly vs control, except with the inputs being baselined vs unbaselined ERPs or TFRs, e.g. Baselined Preposition Anomaly vs Unbaselined Preposition Anomaly, etc. I understand that the proposed method and my method are not testing the same thing exactly, but is this a reasonable way of testing the effect of the baselining anyway? Thanks, Max -- Max Cantor Graduate Student Cognitive Neuroscience of Language Lab University of Colorado Boulder -------------- next part -------------- An HTML attachment was scrubbed... URL: From laetitia.lalla at inserm.fr Sun Apr 10 18:36:56 2016 From: laetitia.lalla at inserm.fr (laetitia.lalla at inserm.fr) Date: Sun, 10 Apr 2016 18:36:56 +0200 Subject: [FieldTrip] Implementation of statistical testing for imaginary coherence differences in FieldTrip In-Reply-To: <815A9820E75FBC4F96B7CD3A8089D11C378AE4DA@exprd04.hosting.ru.nl> References: <2595287eebb0aeacfe5761a9de10de24@inserm.fr> <68a5ba763224075e6d9ec9aa7684221a@inserm.fr>, <815A9820E75FBC4F96B7CD3A8089D11C378AE3E0@exprd04.hosting.ru.nl>, <815A9820E75FBC4F96B7CD3A8089D11C378AE4DA@exprd04.hosting.ru.nl> Message-ID: Dear FieldTrip community, I'm a PhD student in Marseille studying LFPs of freely-moving rats from 2 different regions of the brain. Right now, I'm looking at the imaginary part of the coherency, and I'm interested in the difference in iCoh between 2 conditions (trial and baseline). I searched the old FieldTrip emails and I found this conversation about the imaginary part of the coherency and its statistical testing : http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006402.html If I understood correctly, and based on what Jörn M. Horschig and Eric Maris wrote in April 2013, there was no straightforward implementation of the statistical testing of the differences in the imaginary coherence (between 2 conditions) in FieldTrip at that time. (Jörn wrote "You could have a look at Guido Nolte's paper on imaginary coherence and look it up in the methods section how he is computing it" and Eric wrote : "For a single-subject study, you would have to write your own statfun"). Is this still the case ? Or maybe this is more straightforward now (maybe with new Fieldtrip functions) ? if not, has anyone already tried some similar testing with Fieldtrip or just with Matlab ? Thank you very much for all the help you're providing! Best, Laetitia -------------- next part -------------- An HTML attachment was scrubbed... URL: From gina.joue at univr.it Mon Apr 11 14:37:54 2016 From: gina.joue at univr.it (gj) Date: Mon, 11 Apr 2016 14:37:54 +0200 Subject: [FieldTrip] ft_source2sparse usage for EEG data In-Reply-To: References: Message-ID: <570B9AA2.9050000@univr.it> Hi, Sorry for bumping this message about exceeding the max array size when trying to do a whole brain network analysis with ft_connectivityanalysis, but I am at a loss....Any help (even generally related to FieldTrip connectivity analysis tutorials/scripts specifically for EEG data) very much appreciated! Thanks! Gina From jan.schoffelen at donders.ru.nl Mon Apr 11 15:15:16 2016 From: jan.schoffelen at donders.ru.nl (Schoffelen, J.M. (Jan Mathijs)) Date: Mon, 11 Apr 2016 13:15:16 +0000 Subject: [FieldTrip] ft_source2sparse usage for EEG data References: Message-ID: <096A2A53-E33F-491C-B90F-FBF48172F10B@donders.ru.nl> Hi Gina, A dimensionality of 92232 ( ^ 2) suggests that you have 28 times the number of inside dipoles. I suspect a interaction between FieldTrip’s (perhaps occassionally sloppy) internal data bookkeeping and your specification of the input data/cfg. Where does this factor of 28 come from? Best, Jan-Mathijs > On 11 Apr 2016, at 14:37, gj wrote: > > Hi, > > Sorry for bumping this message about exceeding the max array size when trying to do a whole brain network analysis with ft_connectivityanalysis, but I am at a loss....Any help (even generally related to FieldTrip connectivity analysis tutorials/scripts specifically for EEG data) very much appreciated! > > Thanks! > Gina > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip From assaf.harel at wright.edu Mon Apr 11 15:31:32 2016 From: assaf.harel at wright.edu (Harel, Assaf) Date: Mon, 11 Apr 2016 13:31:32 +0000 Subject: [FieldTrip] Postdoc Position in Human Neuroscience and Visual Cognition Lab Wright State University Message-ID: Human Neuroscience and Visual Cognition Lab Department of Psychology Wright State University A post-doc position is now available at the Human Neuroscience and Visual Cognition Lab at the Department of Psychology, Wright State University. The lab is headed by Dr. Assaf Harel and investigates high-level vision and its neural substrates. We are particularly interested in how visual recognition occurs in real-world settings and adopt a neuroergonomic approach to study the applied aspects of high-level vision. For this purpose, we employ a diversity of cognitive neuroscience methods, including EEG, fMRI, psychophysics, and eye tracking. Research topics include, but are not limited to the following areas: visual expertise, object and scene recognition, categorization and perceptual learning. The position is fully funded for two years. The successful candidate will hold a PhD in Cognitive Neuroscience, Cognitive Psychology, Neurobiology, Computer Science, or any other related discipline by the start date of the position. Strong background and familiarity with fMRI or EEG research is required. Experience in computer programming, especially with Matlab is highly encouraged and will be considered a strong advantage. For more information on this position contact Dr. Assaf Harel: assaf.harel at wright.edu. Applicants should visit the following link to upload CV, statement of research, and three letters of reference: https://jobs.wright.edu/postings/8517 The Department of Psychology is housed in the College of Science and Mathematics, offers a Ph.D. in Human Factors and Industrial/ Organizational Psychology, and has 3 undergraduate concentration areas: (1) Cognition and Perception, (2) Industrial/ Organizational, and (3) Behavioral Neuroscience. Wright State University was recently ranked among the "Best in the Midwest" universities by The Princeton Review, listed among 260 Best National Universities in the annual "America's Best Colleges" rankings by U.S. News and World Report, and ranked fourth nationally among universities with limited numbers of doctoral programs in the Faculty Scholarly Productivity Index. Wright State University is an Equal Opportunity/Affirmative Action Employer. -------------- next part -------------- An HTML attachment was scrubbed... URL: From elinicolaisen at gmail.com Mon Apr 11 16:21:52 2016 From: elinicolaisen at gmail.com (Eliana Nicolaisen) Date: Mon, 11 Apr 2016 11:21:52 -0300 Subject: [FieldTrip] Grand average with deleted channels Message-ID: Dear all, I'm trying to make an ERP grand average using version 20150301. In some subjects I deleted bad channels. Those channels were replaced for NaNs. When I make the grand average using ft_timelockaverage, the grand average is composed only for the common channels across subjects. In other words, in channels deleated at least in one subject the grand average is NaN. This is because ft_timelockanalysis in this version calculates the average making a sum and dividng into degrees of freedom: *grandavg.avg = reshape(sum(avgmat, 1), datsiz)./ResultDOF; * (in line 187 of revision '$Id: ft_timelockgrandaverage.m 10194 2015-02-11 09:08:16Z roboos $') However, I tried version 20121014 that my colleague uses. In this version ft_timelockedanalysis makes a mean: *ResultGrandavg = mean(avgmat, 1);* (in line 183 of revision '$Id: ft_timelockgrandaverage.m 6750 2012-10-13 15:07:32Z roboos $') In the version 20121014 is easy to make a correction that calculates a grand average taking into account NaNs (just changing mean for nanmean). However, in version 20150301 making a similar correction seems more complicated. Question 1: Why version 20150301 calculates average using sum and division instead of using nanmean? Question 2: Do someone have a suggestion about how to change version 20150301? Any comment would be greatly appreciated. Kind regards, Eliana Nicolaisen -------------- next part -------------- An HTML attachment was scrubbed... URL: From gina.joue at univr.it Tue Apr 12 10:41:19 2016 From: gina.joue at univr.it (gj) Date: Tue, 12 Apr 2016 10:41:19 +0200 Subject: [FieldTrip] ft_source2sparse usage for EEG data In-Reply-To: <570B9AA2.9050000@univr.it> References: <570B9AA2.9050000@univr.it> Message-ID: <570CB4AF.6030401@univr.it> Thank you for your help, Jan Mathijs! These are all the related steps I did leading up to the ft_source2sparse call, in case. My input EEG data to FieldTrip are 2 seconds of passive visual stimulation, preprocessed and averaged across all trials per condition per subject in another software. Thank you! g ------------- begin snippet -------------- cfg = []; cfg.method = 'mtmfft'; cfg.output = 'fourier'; cfg.keeptrials = 'yes'; cfg.tapsmofrq = 2; cfg.foi = 12; fft = ft_freqanalysis(cfg, data); cfg = []; cfg.output = {'brain','skull','scalp'}; mri_seg = ft_volumesegment(cfg, mri); % mri from standard_mri.mat (mm) cfg=[]; cfg.tissue={'brain','skull','scalp'}; cfg.numvertices = [3000 1600 800]; mesh_hd=ft_prepare_mesh(cfg,mri_seg); cfg = []; cfg.method = 'bemcp'; headmodel = ft_prepare_headmodel(cfg, mesh_hd); cfg = []; cfg.grid.warpmni = 'yes'; cfg.grid.template = template_grid; % standard_sourcemodel3d10mm.mat cfg.grid.nonlinear = 'yes'; cfg.mri = mri; sourcemodel = ft_prepare_sourcemodel(cfg); cfg = []; cfg.elec = elecR; % elec realigned to standard_bem.mat cfg.headmodel = headmodel; % output from ft_prepare_headmodel cfg.grid = sourcemodel; % output from ft_prepare_sourcemodel lf = ft_prepare_leadfield(cfg); cfg = []; cfg.frequency = fft.freq; cfg.elec = elecR; cfg.method = 'eloreta'; cfg.grid = lf; cfg.vol = vol; % from standard_bem.mat cfg.keeptrials = 'yes'; %cfg.rawtrial = 'yes'; source = ft_sourceanalysis(cfg, fft); cfg = []; cfg.projectmom = 'yes'; source_proj = ft_sourcedescriptives(cfg,source); ------------- end snippet -------------- From ronny.ibrahim at mq.edu.au Tue Apr 12 11:44:44 2016 From: ronny.ibrahim at mq.edu.au (Ronny Ibrahim) Date: Tue, 12 Apr 2016 09:44:44 +0000 Subject: [FieldTrip] Averaging 4D spatio-temporospectral data (trials x channels x frequencies x time) Message-ID: Dear Fellow fieldtrip users, I was wondering whether there is any function which let's me to average my 4D (trials x channels x frequencies x time) time-frequency structure along the trials dimension. I have tried to look into ft_freqgrandaverage function but it won't let me do it. I had set the keeptrials configuration to 'yes' with the aim of representing my data in the relative percentage change format by using the ft_freqbaseline to represent my data in the 'relchange' (percent change format) in which I would like to average. Many thank's in advance for your kind help. Kind Regards, Ronny -------------- next part -------------- An HTML attachment was scrubbed... URL: From maity_winky at yahoo.es Tue Apr 12 13:43:45 2016 From: maity_winky at yahoo.es (=?UTF-8?Q?Mait=C3=A9_Crespo_Garc=C3=ADa?=) Date: Tue, 12 Apr 2016 11:43:45 +0000 (UTC) Subject: [FieldTrip] Averaging 4D spatio-temporospectral data (trials x channels x frequencies x time) In-Reply-To: References: Message-ID: <24058211.2420001.1460461425906.JavaMail.yahoo@mail.yahoo.com> Hi Ronny, try the ft_freqdescriptives. In this tutorial  (http://www.fieldtriptoolbox.org/tutorial/cluster_permutation_freq) it says you can do it. Best,Maite cfg = []; freqFIC_planar_cmb = ft_freqdescriptives(cfg, freqFIC_planar_cmb); El Martes 12 de abril de 2016 12:12, Ronny Ibrahim escribió: Dear Fellow fieldtrip users,I was wondering whether there is any function which let's me to average my  4D (trials x channels x frequencies x time) time-frequency structure along the trials dimension. I have tried to look into ft_freqgrandaverage function but it won't let me do it. I had set the keeptrials configuration to 'yes' with the aim of representing my data in the relative percentage change format by using the ft_freqbaseline to represent my data in the 'relchange' (percent change format) in which I would like to average. Many thank's in advance for your kind help. Kind Regards, Ronny   _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From zsuzsanna.nemecz at gmail.com Wed Apr 13 14:02:08 2016 From: zsuzsanna.nemecz at gmail.com (Zsuzsanna Nemecz) Date: Wed, 13 Apr 2016 14:02:08 +0200 Subject: [FieldTrip] FEM: Missing SIMBIO toolbox Message-ID: Hi, I think the Simbio toolbox is missing in fieldtrip-20160407 and -20160412. I tried generating a FEM volume conduction model and got the following error message in Matlab: Error using ft_hastoolbox (line 485) the SIMBIO toolbox is not installed, see https://www.mrt.uni-jena.de/simbio/index.php/Main_Page I checked in the filedtrip/external directory and the Simbio folder was indeed missing. I solved the problem by downloading an older version ( 2016 March 19th), but I thought it's worth posting anyway for your information. Best Zsuzsanna -------------- next part -------------- An HTML attachment was scrubbed... URL: From r.thomas at nin.knaw.nl Wed Apr 13 16:25:51 2016 From: r.thomas at nin.knaw.nl (Rajat Thomas) Date: Wed, 13 Apr 2016 14:25:51 +0000 Subject: [FieldTrip] Simbio works with ft_volumereslice but leadfield In-Reply-To: References: Message-ID: <1460557552027.85876@nin.knaw.nl> Dear all, Last week I asked for help with Simbio and after following the suggestion of volume reslicing magically the simbio based headmodel was created. But my leadfield calculations are taking way too long. It is a 128^3 grid and am running it on my desktop. (2.4 GHz, plenty of memory 32GB) Could anyone give me a rough ball park on how long it should take to create a leadfield? Thank you. Rajat Rajat Mani Thomas Social Brain Lab Netherlands Institute for Neuroscience Amsterdam ________________________________________ From: fieldtrip-bounces at science.ru.nl on behalf of fieldtrip-request at science.ru.nl Sent: 08 April 2016 12:00 To: fieldtrip at science.ru.nl Subject: fieldtrip Digest, Vol 65, Issue 7 Send fieldtrip mailing list submissions to fieldtrip at science.ru.nl To subscribe or unsubscribe via the World Wide Web, visit http://mailman.science.ru.nl/mailman/listinfo/fieldtrip or, via email, send a message with subject or body 'help' to fieldtrip-request at science.ru.nl You can reach the person managing the list at fieldtrip-owner at science.ru.nl When replying, please edit your Subject line so it is more specific than "Re: Contents of fieldtrip digest..." Today's Topics: 1. Re: FEM using Simbio (Johannes Vorwerk) 2. Re: FEM using Simbio (Cristiano Micheli) 3. Dipole fitting (Giovanni Pellegrino) 4. Birmingham-Illinois BRIDGE Fellowships (Ole Jensen) 5. Using FieldTrip to analyse LFP recordings in rat (laetitia.lalla at inserm.fr) ---------------------------------------------------------------------- Message: 1 Date: Thu, 7 Apr 2016 14:25:42 +0200 From: Johannes Vorwerk To: FieldTrip discussion list Subject: Re: [FieldTrip] FEM using Simbio Message-ID: <435735E3-7D87-4DD6-A2C1-E2BBFBBF4B44 at googlemail.com> Content-Type: text/plain; charset="utf-8" Hi, this question was already answered in this thread http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html If ft_volumereslice is not applied before the mesh generation, the afterwards applied transformation might flip the directions of the mesh, leading to the described error. Best, Johannes > Am 06.04.2016 um 16:03 schrieb Carsten Wolters : > > Dear Rajat, > > the element-node cards of SimBio-NeuroFEM need to follow certain orientations (see www.simbio.de ). > > If you do not want to struggle with meshing/ordering, use the SimBio-VGRID mesher > http://vgrid.simbio.de/ > that follows the required ordering of nodes. You might use this mesher to produce 1mm geometry-adapted FEM meshes > that show good overall performance, see > http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf > and > http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf > (latter was just accepted by NeuroImage). > > Best regards > Carsten > > Am 06.04.2016 um 15:10 schrieb Rajat Thomas: >> Dear all, >> >> Has anyone used the FEM approach to Headmodels using Simbio recently? >> >> If so, I get this error: >> "Elements have wrong orientation or are degenerated" >> >> Any ideas? >> >> cfg = []; >> cfg.method ='simbio'; >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows mesh.tissyelabel >> vol = ft_prepare_headmodel(cfg, mesh); >> >> And; >> ? >> disp(mesh) >> hex: [545883x8 double] >> pnt: [569722x3 double] >> labels: [545883x1 double] >> tissue: [545883x1 double] >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >> unit: 'mm' >> cfg: [1x1 struct] >> >> Any help would be highly appreciated. >> >> Rajat >> >> >> >> >> >> >> Rajat Mani Thomas >> Social Brain Lab >> Netherlands Institute for Neuroscience >> Amsterdam >> >> >> _______________________________________________ >> 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 -------------- next part -------------- An HTML attachment was scrubbed... URL: ------------------------------ Message: 2 Date: Thu, 7 Apr 2016 17:36:37 +0200 From: Cristiano Micheli To: FieldTrip discussion list Subject: Re: [FieldTrip] FEM using Simbio Message-ID: Content-Type: text/plain; charset="utf-8" Hi Rajat My guess is that the orientations of your hexahedrons are not correct. According to a low-level file's internal rules, elements' orientations have to abide strict rules (not sure what exactly the contraints are in this case though...). I had same problems when for example the triangular boundaries used to define the 3d hexahedral mesh were not topologically correct, to start with. Admittedly this approach requires a lot of technical expertise. Can I ask you what do you need a FEM model for? Regards Cris Micheli On Wed, Apr 6, 2016 at 3:10 PM, Rajat Thomas wrote: > Dear all, > > > Has anyone used the FEM approach to Headmodels using Simbio recently? > > > If so, I get this error: > "Elements have wrong orientation or are degenerated" > > Any ideas? > > cfg = []; > > cfg.method ='simbio'; > > cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows > mesh.tissyelabel > > vol = ft_prepare_headmodel(cfg, mesh); > > > And; > > ? > disp(mesh) > hex: [545883x8 double] > pnt: [569722x3 double] > labels: [545883x1 double] > tissue: [545883x1 double] > tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} > unit: 'mm' > cfg: [1x1 struct] > > > Any help would be highly appreciated. > > Rajat > > > > > > > Rajat Mani Thomas > Social Brain Lab > Netherlands Institute for Neuroscience > Amsterdam > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: ------------------------------ Message: 3 Date: Thu, 7 Apr 2016 15:02:05 -0400 From: Giovanni Pellegrino To: fieldtrip at science.ru.nl Subject: [FieldTrip] Dipole fitting Message-ID: Content-Type: text/plain; charset="utf-8" Dear Fieldtrippers, Do you know if the FieldTrip Dipole Fitting has been compared to the CTF, Elekta, BESA or Curry? Are you aware of any study on this topic? Thanks in advance for your help Giovanni -- Giovanni Pellegrino, MD Multimodal Functional Imaging Laboratory Montreal Neurological Institute, McGill University Address: 332 Duff Medical Building, 3775 rue University, Montreal, QC, H3A 2B4, Canada Phone: (514) 398?1678 Fax: (514) 398?7461 Email: giovannipellegrino at gmail.com, giovanni.pellegrino2 at mcgill.ca Homepage: http://www.bic.mni.mcgill.ca/ResearchLabsMFIL/PeopleGiovanni -------------- next part -------------- An HTML attachment was scrubbed... URL: ------------------------------ Message: 4 Date: Fri, 8 Apr 2016 09:23:46 +0200 From: Ole Jensen To: fieldtrip at science.ru.nl Subject: [FieldTrip] Birmingham-Illinois BRIDGE Fellowships Message-ID: <57075C82.8030309 at donders.ru.nl> Content-Type: text/plain; charset=utf-8; format=flowed Dear all, I would like to point you to a set of Birmingham-Illinois BRIDGE Fellowships providing some exciting research and career prospects: http://www.birminghamillinoisbridge.org/index.php/fellows/ In particular the areas 'Cognition and Ageing' and 'Brain Trauma' could be relevant for candidates with EEG/MEG expertise. All the best, Ole -- Prof. dr. Ole Jensen http://www.neuosc.com ------------------------------ Message: 5 Date: Fri, 08 Apr 2016 10:27:58 +0200 From: laetitia.lalla at inserm.fr To: fieldtrip at science.ru.nl Subject: [FieldTrip] Using FieldTrip to analyse LFP recordings in rat Message-ID: <628babdc107aebd4cc7588ea87ce5ea6 at inserm.fr> Content-Type: text/plain; charset="utf-8" Hello everyone, my name is Laetitia and I'm a Phd student in Marseille (France). I'm doing in-vivo recording in freely-moving rats : I implant them with 2 electrodes deep into 2 different regions of the brain. I'm studying the Local Field Potentials and I want to use FieldTrip to analyse the data. To simplify : - I have 2 rats. - Each rat did 20 sessions of the task (on 20 different days). - Each session consists of 20 trials of condition 1 and 20 trials of condition 2. I have 2 questions. 1) I have the feeling it would be meaningless to do "source reconstruction" because my electrodes are already deep inside my "source" and the LFP I am recording is very local. (My electrodes have 32 channels separated by 20-200 ?m. The LFP is very very similar across all the channels, so I averaged over the 32 channels to have one signal for each region.) However, I see that 2 different functions exist for the statistics : FT_FREQSTATISTICS AND FT_SOURCESTATISTICS. So far, I've been using ft_freqstatistics but I encounter some issues (for exemple, doing monte-carlo permutation test to assess the imaginary coherence). I thought of computing it manually, but I'm thinking that maybe more stuff are implemented in ft_sourcestatisctics ? ? Are these 2 functions fundamentally different or do they call the same sub-fonctions (and my problem has actually nothing to do with that) ? 2) I'm a bit confused with the vocabulary from EEG and MEG studies (I'm not used to it yet...). From what I understood, in human studies, you can do comparison for a single subject (across trials) or across subjects. But I have 3 levels of comparisons in my design : - WITHIN A SESSION, I WANT TO COMPARE ACROSS TRIALS (the 20 trials of condition 1 VS the 20 trials of condition 2). - WITHIN A RAT, I WANT TO COMPARE ACROSS SESSIONS (between the 2 conditions) - then - in the very end - ACROSS RATS. But I have only 2 rats so far, so I will deal with this later. I'm a bit confused when reading the tutorials and the mailing list, especially when it comes to the statistics... For example : this is from an email from 2013 by Eric Maris about "Nonparametric statistical testing of phase coherence" (http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006401.html) "To compare coherence between conditions across subjects (instead of trials), you need a different statfun: depsamplesT (for a within-subjects design; subjects have participated in all conditions) or indepsamplesT (for a between-subjects design; subjects have participated in only one condition)." ? If I want to compare across sessions (for a same rat), can I actually consider that my different sessions are "subjects"? And then compare coherence "across subjects" would be doing it "across sessions" ? And I would be in a "within-subject design" since my sessions involve the 2 conditions every time ? I realise that it may be very confusing... I hope you will understand my problem ! And if anyone already applied fieldtrip functions to do statistics on a different framework that the usual EEG/MEG, please let me know ! Thanks a lot, Laetitia Lalla PhD Student in Neuroscience INMED, Marseille, France -------------- next part -------------- An HTML attachment was scrubbed... URL: ------------------------------ _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl http://mailman.science.ru.nl/mailman/listinfo/fieldtrip End of fieldtrip Digest, Vol 65, Issue 7 **************************************** From icelandhouse at gmail.com Wed Apr 13 19:35:17 2016 From: icelandhouse at gmail.com (Maris Skujevskis) Date: Wed, 13 Apr 2016 19:35:17 +0200 Subject: [FieldTrip] Correlated sources: LCMV, MNE, dipole fitting Message-ID: Dear Fieldtrip community, I am trying to localize neural sources of the primary somatosensory response using the LCMV beamformer on an ERP dataset. In my experiment the subjects are stimulated bilaterally - both the left and the right index finger simultaneously receive an identical tactile half a second stimulus. The LCMV beamformer fails to detect two distinct early cortical sources (left and right S1), instead I get a single rather central source (along the lines of Van Veen et al., 1997, Fig.2(f) ). My question is: -is it expected that MNE fares better than LCMV when two sources are correlated? (i.e. would MNE be more likely to detect both right and left S1)? -or would dipole fitting be the preferred method for obtaining an accurate estimate of left/right S1 location? Any suggestions will be appreciated! Thanks! Maris On Wed, Apr 13, 2016 at 12:00 PM, wrote: > Send fieldtrip mailing list submissions to > fieldtrip at science.ru.nl > > To subscribe or unsubscribe via the World Wide Web, visit > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > or, via email, send a message with subject or body 'help' to > fieldtrip-request at science.ru.nl > > You can reach the person managing the list at > fieldtrip-owner at science.ru.nl > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of fieldtrip digest..." > > > Today's Topics: > > 1. Re: Averaging 4D spatio-temporospectral data (trials x > channels x frequencies x time) (Mait? Crespo Garc?a) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Tue, 12 Apr 2016 11:43:45 +0000 (UTC) > From: Mait? Crespo Garc?a > To: FieldTrip discussion list > Subject: Re: [FieldTrip] Averaging 4D spatio-temporospectral data > (trials x channels x frequencies x time) > Message-ID: > <24058211.2420001.1460461425906.JavaMail.yahoo at mail.yahoo.com> > Content-Type: text/plain; charset="utf-8" > > Hi Ronny, > try the ft_freqdescriptives. In this tutorial? ( > http://www.fieldtriptoolbox.org/tutorial/cluster_permutation_freq) it > says you can do it. > Best,Maite > > cfg = []; > freqFIC_planar_cmb = ft_freqdescriptives(cfg, freqFIC_planar_cmb); > > > > El Martes 12 de abril de 2016 12:12, Ronny Ibrahim < > ronny.ibrahim at mq.edu.au> escribi?: > > > Dear Fellow > fieldtrip users,I was wondering whether there is any function which let's > me to?average my ?4D (trials?x channels x frequencies x time) > time-frequency?structure along the trials dimension. I have tried to look > into ft_freqgrandaverage function but it won't let me do it. I had set?the > keeptrials configuration to 'yes' with the aim of representing my data in > the relative percentage change format by using the?ft_freqbaseline to > represent my data in the 'relchange' (percent change format) in?which I > would like to average. > Many thank's in advance for your kind help. > Kind Regards, > Ronny?? > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: < > http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160412/8f7f5099/attachment-0001.html > > > > ------------------------------ > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > End of fieldtrip Digest, Vol 65, Issue 11 > ***************************************** > -------------- next part -------------- An HTML attachment was scrubbed... URL: From gina.joue at univr.it Wed Apr 13 20:13:44 2016 From: gina.joue at univr.it (gj) Date: Wed, 13 Apr 2016 20:13:44 +0200 Subject: [FieldTrip] source reconstruction + noise bias in center of head Message-ID: <570E8C58.6080709@univr.it> Hi FieldTrip community, I tried doing source analysis of EEG data using method "eloreta." For some participants, the sources found were where we expected, but for some participants, the strongest power is in the center of the brain (and some on the skull...). What can I do in this case/what should I doublecheck? We don't have structural MRIs for each participant but coregistered the electrodes to a template brain. I actually tried using DICS to do the source analysis in order to estimate the noise, but 1. there is high power in almost the entire brain 2. the noise estimated is all 0's or NAs. Thanks in advance for any help! Gina From julian.keil at gmail.com Thu Apr 14 09:48:05 2016 From: julian.keil at gmail.com (Julian Keil) Date: Thu, 14 Apr 2016 09:48:05 +0200 Subject: [FieldTrip] Simbio works with ft_volumereslice but leadfield In-Reply-To: <1460557552027.85876@nin.knaw.nl> References: <1460557552027.85876@nin.knaw.nl> Message-ID: Hi Rajat, what do you mean by "way too long"? Have you tried setting the resolution of the mesh in the call to ft_prepare_mesh prior to ft_prepare_headmodel? Setting it to cfg.resolution = 5 (which changes the mesh resolution from the default 1mm to 5mm) greatly sped up the mesh preparation and leadfield computation in my case. Please beware however that I use a rather old FT-Version as I don't have a current Matlab Version, so the functionality might have changed. Good Luck, Julian ******************** Dr. Julian Keil AG Multisensorische Integration Psychiatrische Universitätsklinik der Charité im St. Hedwig-Krankenhaus Große Hamburger Straße 5-11, Haus 2 10115 Berlin Telefon: +49-30-2311-1879 Fax: +49-30-2311-2209 http://psy-ccm.charite.de/forschung/bildgebung/ag_multisensorische_integration Am 13.04.2016 um 16:25 schrieb Rajat Thomas: > Dear all, > > Last week I asked for help with Simbio and after following the suggestion of volume reslicing magically the > simbio based headmodel was created. > > But my leadfield calculations are taking way too long. > It is a 128^3 grid and am running it on my desktop. (2.4 GHz, plenty of memory 32GB) > > Could anyone give me a rough ball park on how long it should take to create a leadfield? > > Thank you. > Rajat > > > > Rajat Mani Thomas > Social Brain Lab > Netherlands Institute for Neuroscience > Amsterdam > > ________________________________________ > From: fieldtrip-bounces at science.ru.nl on behalf of fieldtrip-request at science.ru.nl > Sent: 08 April 2016 12:00 > To: fieldtrip at science.ru.nl > Subject: fieldtrip Digest, Vol 65, Issue 7 > > Send fieldtrip mailing list submissions to > fieldtrip at science.ru.nl > > To subscribe or unsubscribe via the World Wide Web, visit > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > or, via email, send a message with subject or body 'help' to > fieldtrip-request at science.ru.nl > > You can reach the person managing the list at > fieldtrip-owner at science.ru.nl > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of fieldtrip digest..." > > > Today's Topics: > > 1. Re: FEM using Simbio (Johannes Vorwerk) > 2. Re: FEM using Simbio (Cristiano Micheli) > 3. Dipole fitting (Giovanni Pellegrino) > 4. Birmingham-Illinois BRIDGE Fellowships (Ole Jensen) > 5. Using FieldTrip to analyse LFP recordings in rat > (laetitia.lalla at inserm.fr) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Thu, 7 Apr 2016 14:25:42 +0200 > From: Johannes Vorwerk > To: FieldTrip discussion list > Subject: Re: [FieldTrip] FEM using Simbio > Message-ID: <435735E3-7D87-4DD6-A2C1-E2BBFBBF4B44 at googlemail.com> > Content-Type: text/plain; charset="utf-8" > > Hi, > > this question was already answered in this thread > > http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html > > If ft_volumereslice is not applied before the mesh generation, the afterwards applied transformation might flip the directions of the mesh, leading to the described error. > > Best, > Johannes > >> Am 06.04.2016 um 16:03 schrieb Carsten Wolters : >> >> Dear Rajat, >> >> the element-node cards of SimBio-NeuroFEM need to follow certain orientations (see www.simbio.de ). >> >> If you do not want to struggle with meshing/ordering, use the SimBio-VGRID mesher >> http://vgrid.simbio.de/ >> that follows the required ordering of nodes. You might use this mesher to produce 1mm geometry-adapted FEM meshes >> that show good overall performance, see >> http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf >> and >> http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf >> (latter was just accepted by NeuroImage). >> >> Best regards >> Carsten >> >> Am 06.04.2016 um 15:10 schrieb Rajat Thomas: >>> Dear all, >>> >>> Has anyone used the FEM approach to Headmodels using Simbio recently? >>> >>> If so, I get this error: >>> "Elements have wrong orientation or are degenerated" >>> >>> Any ideas? >>> >>> cfg = []; >>> cfg.method ='simbio'; >>> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows mesh.tissyelabel >>> vol = ft_prepare_headmodel(cfg, mesh); >>> >>> And; >>> ? >>> disp(mesh) >>> hex: [545883x8 double] >>> pnt: [569722x3 double] >>> labels: [545883x1 double] >>> tissue: [545883x1 double] >>> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >>> unit: 'mm' >>> cfg: [1x1 struct] >>> >>> Any help would be highly appreciated. >>> >>> Rajat >>> >>> >>> >>> >>> >>> >>> Rajat Mani Thomas >>> Social Brain Lab >>> Netherlands Institute for Neuroscience >>> Amsterdam >>> >>> >>> _______________________________________________ >>> 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 > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > Message: 2 > Date: Thu, 7 Apr 2016 17:36:37 +0200 > From: Cristiano Micheli > To: FieldTrip discussion list > Subject: Re: [FieldTrip] FEM using Simbio > Message-ID: > > Content-Type: text/plain; charset="utf-8" > > Hi Rajat > > My guess is that the orientations of your hexahedrons are not correct. > According to a low-level file's internal rules, elements' orientations have > to abide strict rules (not sure what exactly the contraints are in this > case though...). > I had same problems when for example the triangular boundaries used to > define the 3d hexahedral mesh were not topologically correct, to start with. > Admittedly this approach requires a lot of technical expertise. > Can I ask you what do you need a FEM model for? > > Regards > Cris Micheli > > > > > On Wed, Apr 6, 2016 at 3:10 PM, Rajat Thomas wrote: > >> Dear all, >> >> >> Has anyone used the FEM approach to Headmodels using Simbio recently? >> >> >> If so, I get this error: >> "Elements have wrong orientation or are degenerated" >> >> Any ideas? >> >> cfg = []; >> >> cfg.method ='simbio'; >> >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows >> mesh.tissyelabel >> >> vol = ft_prepare_headmodel(cfg, mesh); >> >> >> And; >> >> ? >> disp(mesh) >> hex: [545883x8 double] >> pnt: [569722x3 double] >> labels: [545883x1 double] >> tissue: [545883x1 double] >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >> unit: 'mm' >> cfg: [1x1 struct] >> >> >> Any help would be highly appreciated. >> >> Rajat >> >> >> >> >> >> >> Rajat Mani Thomas >> Social Brain Lab >> Netherlands Institute for Neuroscience >> Amsterdam >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > Message: 3 > Date: Thu, 7 Apr 2016 15:02:05 -0400 > From: Giovanni Pellegrino > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Dipole fitting > Message-ID: > > Content-Type: text/plain; charset="utf-8" > > Dear Fieldtrippers, > > Do you know if the FieldTrip Dipole Fitting has been compared to the CTF, > Elekta, BESA or Curry? Are you aware of any study on this topic? > > Thanks in advance for your help > > Giovanni > > -- > Giovanni Pellegrino, MD > Multimodal Functional Imaging Laboratory > Montreal Neurological Institute, McGill University > Address: 332 Duff Medical Building, 3775 rue University, Montreal, QC, H3A > 2B4, Canada > Phone: (514) 398?1678 > Fax: (514) 398?7461 > Email: giovannipellegrino at gmail.com, giovanni.pellegrino2 at mcgill.ca > Homepage: http://www.bic.mni.mcgill.ca/ResearchLabsMFIL/PeopleGiovanni > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > Message: 4 > Date: Fri, 8 Apr 2016 09:23:46 +0200 > From: Ole Jensen > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Birmingham-Illinois BRIDGE Fellowships > Message-ID: <57075C82.8030309 at donders.ru.nl> > Content-Type: text/plain; charset=utf-8; format=flowed > > Dear all, > > I would like to point you to a set of Birmingham-Illinois BRIDGE > Fellowships providing some exciting research and career prospects: > http://www.birminghamillinoisbridge.org/index.php/fellows/ > > In particular the areas 'Cognition and Ageing' and 'Brain Trauma' could > be relevant for candidates with EEG/MEG expertise. > > All the best, > > Ole > > -- > Prof. dr. Ole Jensen > http://www.neuosc.com > > > > ------------------------------ > > Message: 5 > Date: Fri, 08 Apr 2016 10:27:58 +0200 > From: laetitia.lalla at inserm.fr > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Using FieldTrip to analyse LFP recordings in rat > Message-ID: <628babdc107aebd4cc7588ea87ce5ea6 at inserm.fr> > Content-Type: text/plain; charset="utf-8" > > > > Hello everyone, > > my name is Laetitia and I'm a Phd student in Marseille (France). I'm > doing in-vivo recording in freely-moving rats : I implant them with 2 > electrodes deep into 2 different regions of the brain. I'm studying the > Local Field Potentials and I want to use FieldTrip to analyse the data. > > To simplify : > > - I have 2 rats. > > - Each rat did 20 sessions of the task (on 20 different days). > > - Each session consists of 20 trials of condition 1 and 20 trials of > condition 2. > > I have 2 questions. > > 1) I have the feeling it would be meaningless to do "source > reconstruction" because my electrodes are already deep inside my > "source" and the LFP I am recording is very local. (My electrodes have > 32 channels separated by 20-200 ?m. The LFP is very very similar across > all the channels, so I averaged over the 32 channels to have one signal > for each region.) > > However, I see that 2 different functions exist for the statistics : > FT_FREQSTATISTICS AND FT_SOURCESTATISTICS. So far, I've been using > ft_freqstatistics but I encounter some issues (for exemple, doing > monte-carlo permutation test to assess the imaginary coherence). I > thought of computing it manually, but I'm thinking that maybe more stuff > are implemented in ft_sourcestatisctics ? > > ? Are these 2 functions fundamentally different or do they call the same > sub-fonctions (and my problem has actually nothing to do with that) ? > > 2) I'm a bit confused with the vocabulary from EEG and MEG studies (I'm > not used to it yet...). From what I understood, in human studies, you > can do comparison for a single subject (across trials) or across > subjects. But I have 3 levels of comparisons in my design : > > - WITHIN A SESSION, I WANT TO COMPARE ACROSS TRIALS (the 20 trials of > condition 1 VS the 20 trials of condition 2). > > - WITHIN A RAT, I WANT TO COMPARE ACROSS SESSIONS (between the 2 > conditions) > > - then - in the very end - ACROSS RATS. But I have only 2 rats so far, > so I will deal with this later. > > I'm a bit confused when reading the tutorials and the mailing list, > especially when it comes to the statistics... For example : this is from > an email from 2013 by Eric Maris about "Nonparametric statistical > testing of phase coherence" > (http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006401.html) > "To compare coherence between conditions across subjects (instead of > trials), you need a different statfun: depsamplesT (for a > within-subjects design; subjects have participated in all conditions) or > indepsamplesT (for a between-subjects design; subjects have participated > in only one condition)." > > ? If I want to compare across sessions (for a same rat), can I actually > consider that my different sessions are "subjects"? And then compare > coherence "across subjects" would be doing it "across sessions" ? And I > would be in a "within-subject design" since my sessions involve the 2 > conditions every time ? > > I realise that it may be very confusing... I hope you will understand my > problem ! > > And if anyone already applied fieldtrip functions to do statistics on a > different framework that the usual EEG/MEG, please let me know ! > > Thanks a lot, > > Laetitia Lalla > > PhD Student in Neuroscience > > INMED, Marseille, France > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > End of fieldtrip Digest, Vol 65, Issue 7 > **************************************** > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 495 bytes Desc: Message signed with OpenPGP using GPGMail URL: From deb.desideri at gmail.com Thu Apr 14 10:21:08 2016 From: deb.desideri at gmail.com (Debora Desideri) Date: Thu, 14 Apr 2016 10:21:08 +0200 Subject: [FieldTrip] Simbio works with ft_volumereslice but leadfield In-Reply-To: <1460557552027.85876@nin.knaw.nl> References: <1460557552027.85876@nin.knaw.nl> Message-ID: Dear Rajat, I am also using Simbio and I usually run the leadfield calculation overnight since it takes approximatelly 12-15 hours for 64 EEG channels with a grid of 6 mm resolution ( 2.60 GHz, 32 GB RAM). I don't know whether there is a way to speed the process up. Maybe we just need to be patient, or work on a very powerful machine. Best, Debora On Wed, Apr 13, 2016 at 4:25 PM, Rajat Thomas wrote: > Dear all, > > Last week I asked for help with Simbio and after following the suggestion > of volume reslicing magically the > simbio based headmodel was created. > > But my leadfield calculations are taking way too long. > It is a 128^3 grid and am running it on my desktop. (2.4 GHz, plenty of > memory 32GB) > > Could anyone give me a rough ball park on how long it should take to > create a leadfield? > > Thank you. > Rajat > > > > Rajat Mani Thomas > Social Brain Lab > Netherlands Institute for Neuroscience > Amsterdam > > ________________________________________ > From: fieldtrip-bounces at science.ru.nl > on behalf of fieldtrip-request at science.ru.nl < > fieldtrip-request at science.ru.nl> > Sent: 08 April 2016 12:00 > To: fieldtrip at science.ru.nl > Subject: fieldtrip Digest, Vol 65, Issue 7 > > Send fieldtrip mailing list submissions to > fieldtrip at science.ru.nl > > To subscribe or unsubscribe via the World Wide Web, visit > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > or, via email, send a message with subject or body 'help' to > fieldtrip-request at science.ru.nl > > You can reach the person managing the list at > fieldtrip-owner at science.ru.nl > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of fieldtrip digest..." > > > Today's Topics: > > 1. Re: FEM using Simbio (Johannes Vorwerk) > 2. Re: FEM using Simbio (Cristiano Micheli) > 3. Dipole fitting (Giovanni Pellegrino) > 4. Birmingham-Illinois BRIDGE Fellowships (Ole Jensen) > 5. Using FieldTrip to analyse LFP recordings in rat > (laetitia.lalla at inserm.fr) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Thu, 7 Apr 2016 14:25:42 +0200 > From: Johannes Vorwerk > To: FieldTrip discussion list > Subject: Re: [FieldTrip] FEM using Simbio > Message-ID: <435735E3-7D87-4DD6-A2C1-E2BBFBBF4B44 at googlemail.com> > Content-Type: text/plain; charset="utf-8" > > Hi, > > this question was already answered in this thread > > http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html < > http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html> > > If ft_volumereslice is not applied before the mesh generation, the > afterwards applied transformation might flip the directions of the mesh, > leading to the described error. > > Best, > Johannes > > > Am 06.04.2016 um 16:03 schrieb Carsten Wolters < > carsten.wolters at uni-muenster.de>: > > > > Dear Rajat, > > > > the element-node cards of SimBio-NeuroFEM need to follow certain > orientations (see www.simbio.de ). > > > > If you do not want to struggle with meshing/ordering, use the > SimBio-VGRID mesher > > http://vgrid.simbio.de/ > > that follows the required ordering of nodes. You might use this mesher > to produce 1mm geometry-adapted FEM meshes > > that show good overall performance, see > > > http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf > < > http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf > > > > and > > > http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf > < > http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf > > > > (latter was just accepted by NeuroImage). > > > > Best regards > > Carsten > > > > Am 06.04.2016 um 15:10 schrieb Rajat Thomas: > >> Dear all, > >> > >> Has anyone used the FEM approach to Headmodels using Simbio recently? > >> > >> If so, I get this error: > >> "Elements have wrong orientation or are degenerated" > >> > >> Any ideas? > >> > >> cfg = []; > >> cfg.method ='simbio'; > >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows > mesh.tissyelabel > >> vol = ft_prepare_headmodel(cfg, mesh); > >> > >> And; > >> ? > >> disp(mesh) > >> hex: [545883x8 double] > >> pnt: [569722x3 double] > >> labels: [545883x1 double] > >> tissue: [545883x1 double] > >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} > >> unit: 'mm' > >> cfg: [1x1 struct] > >> > >> Any help would be highly appreciated. > >> > >> Rajat > >> > >> > >> > >> > >> > >> > >> Rajat Mani Thomas > >> Social Brain Lab > >> Netherlands Institute for Neuroscience > >> Amsterdam > >> > >> > >> _______________________________________________ > >> fieldtrip mailing list > >> fieldtrip at donders.ru.nl > >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip < > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip> > > _______________________________________________ > > fieldtrip mailing list > > fieldtrip at donders.ru.nl > > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip < > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip> > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: < > http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160407/2ea995ee/attachment-0001.html > > > > ------------------------------ > > Message: 2 > Date: Thu, 7 Apr 2016 17:36:37 +0200 > From: Cristiano Micheli > To: FieldTrip discussion list > Subject: Re: [FieldTrip] FEM using Simbio > Message-ID: > < > CADW7XCAQONsZ_ujPhkffskZ+j-mnHnAzunS68CdKU6MLSosUPA at mail.gmail.com> > Content-Type: text/plain; charset="utf-8" > > Hi Rajat > > My guess is that the orientations of your hexahedrons are not correct. > According to a low-level file's internal rules, elements' orientations have > to abide strict rules (not sure what exactly the contraints are in this > case though...). > I had same problems when for example the triangular boundaries used to > define the 3d hexahedral mesh were not topologically correct, to start > with. > Admittedly this approach requires a lot of technical expertise. > Can I ask you what do you need a FEM model for? > > Regards > Cris Micheli > > > > > On Wed, Apr 6, 2016 at 3:10 PM, Rajat Thomas wrote: > > > Dear all, > > > > > > Has anyone used the FEM approach to Headmodels using Simbio recently? > > > > > > If so, I get this error: > > "Elements have wrong orientation or are degenerated" > > > > Any ideas? > > > > cfg = []; > > > > cfg.method ='simbio'; > > > > cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows > > mesh.tissyelabel > > > > vol = ft_prepare_headmodel(cfg, mesh); > > > > > > And; > > > > ? > > disp(mesh) > > hex: [545883x8 double] > > pnt: [569722x3 double] > > labels: [545883x1 double] > > tissue: [545883x1 double] > > tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} > > unit: 'mm' > > cfg: [1x1 struct] > > > > > > Any help would be highly appreciated. > > > > Rajat > > > > > > > > > > > > > > Rajat Mani Thomas > > Social Brain Lab > > Netherlands Institute for Neuroscience > > Amsterdam > > > > _______________________________________________ > > fieldtrip mailing list > > fieldtrip at donders.ru.nl > > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: < > http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160407/4adfe55a/attachment-0001.html > > > > ------------------------------ > > Message: 3 > Date: Thu, 7 Apr 2016 15:02:05 -0400 > From: Giovanni Pellegrino > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Dipole fitting > Message-ID: > u8GDw at mail.gmail.com> > Content-Type: text/plain; charset="utf-8" > > Dear Fieldtrippers, > > Do you know if the FieldTrip Dipole Fitting has been compared to the CTF, > Elekta, BESA or Curry? Are you aware of any study on this topic? > > Thanks in advance for your help > > Giovanni > > -- > Giovanni Pellegrino, MD > Multimodal Functional Imaging Laboratory > Montreal Neurological Institute, McGill University > Address: 332 Duff Medical Building, 3775 rue University, Montreal, QC, H3A > 2B4, Canada > Phone: (514) 398?1678 > Fax: (514) 398?7461 > Email: giovannipellegrino at gmail.com, giovanni.pellegrino2 at mcgill.ca > Homepage: http://www.bic.mni.mcgill.ca/ResearchLabsMFIL/PeopleGiovanni > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: < > http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160407/d01144bd/attachment-0001.html > > > > ------------------------------ > > Message: 4 > Date: Fri, 8 Apr 2016 09:23:46 +0200 > From: Ole Jensen > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Birmingham-Illinois BRIDGE Fellowships > Message-ID: <57075C82.8030309 at donders.ru.nl> > Content-Type: text/plain; charset=utf-8; format=flowed > > Dear all, > > I would like to point you to a set of Birmingham-Illinois BRIDGE > Fellowships providing some exciting research and career prospects: > http://www.birminghamillinoisbridge.org/index.php/fellows/ > > In particular the areas 'Cognition and Ageing' and 'Brain Trauma' could > be relevant for candidates with EEG/MEG expertise. > > All the best, > > Ole > > -- > Prof. dr. Ole Jensen > http://www.neuosc.com > > > > ------------------------------ > > Message: 5 > Date: Fri, 08 Apr 2016 10:27:58 +0200 > From: laetitia.lalla at inserm.fr > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Using FieldTrip to analyse LFP recordings in rat > Message-ID: <628babdc107aebd4cc7588ea87ce5ea6 at inserm.fr> > Content-Type: text/plain; charset="utf-8" > > > > Hello everyone, > > my name is Laetitia and I'm a Phd student in Marseille (France). I'm > doing in-vivo recording in freely-moving rats : I implant them with 2 > electrodes deep into 2 different regions of the brain. I'm studying the > Local Field Potentials and I want to use FieldTrip to analyse the data. > > To simplify : > > - I have 2 rats. > > - Each rat did 20 sessions of the task (on 20 different days). > > - Each session consists of 20 trials of condition 1 and 20 trials of > condition 2. > > I have 2 questions. > > 1) I have the feeling it would be meaningless to do "source > reconstruction" because my electrodes are already deep inside my > "source" and the LFP I am recording is very local. (My electrodes have > 32 channels separated by 20-200 ?m. The LFP is very very similar across > all the channels, so I averaged over the 32 channels to have one signal > for each region.) > > However, I see that 2 different functions exist for the statistics : > FT_FREQSTATISTICS AND FT_SOURCESTATISTICS. So far, I've been using > ft_freqstatistics but I encounter some issues (for exemple, doing > monte-carlo permutation test to assess the imaginary coherence). I > thought of computing it manually, but I'm thinking that maybe more stuff > are implemented in ft_sourcestatisctics ? > > ? Are these 2 functions fundamentally different or do they call the same > sub-fonctions (and my problem has actually nothing to do with that) ? > > 2) I'm a bit confused with the vocabulary from EEG and MEG studies (I'm > not used to it yet...). From what I understood, in human studies, you > can do comparison for a single subject (across trials) or across > subjects. But I have 3 levels of comparisons in my design : > > - WITHIN A SESSION, I WANT TO COMPARE ACROSS TRIALS (the 20 trials of > condition 1 VS the 20 trials of condition 2). > > - WITHIN A RAT, I WANT TO COMPARE ACROSS SESSIONS (between the 2 > conditions) > > - then - in the very end - ACROSS RATS. But I have only 2 rats so far, > so I will deal with this later. > > I'm a bit confused when reading the tutorials and the mailing list, > especially when it comes to the statistics... For example : this is from > an email from 2013 by Eric Maris about "Nonparametric statistical > testing of phase coherence" > (http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006401.html) > "To compare coherence between conditions across subjects (instead of > trials), you need a different statfun: depsamplesT (for a > within-subjects design; subjects have participated in all conditions) or > indepsamplesT (for a between-subjects design; subjects have participated > in only one condition)." > > ? If I want to compare across sessions (for a same rat), can I actually > consider that my different sessions are "subjects"? And then compare > coherence "across subjects" would be doing it "across sessions" ? And I > would be in a "within-subject design" since my sessions involve the 2 > conditions every time ? > > I realise that it may be very confusing... I hope you will understand my > problem ! > > And if anyone already applied fieldtrip functions to do statistics on a > different framework that the usual EEG/MEG, please let me know ! > > Thanks a lot, > > Laetitia Lalla > > PhD Student in Neuroscience > > INMED, Marseille, France > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: < > http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160408/2aed96c1/attachment-0001.html > > > > ------------------------------ > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > End of fieldtrip Digest, Vol 65, Issue 7 > **************************************** > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -- Debora Desideri, PhD Student BNP Lab - Neurology Department University Hospital Tübingen Eberhard Karls University Tübingen Hoppe-Seyler Str. 3 D-72076 Tübingen Tel: +49 7071/29 80478 -------------- next part -------------- An HTML attachment was scrubbed... URL: From carsten.wolters at uni-muenster.de Thu Apr 14 11:26:48 2016 From: carsten.wolters at uni-muenster.de (Carsten Wolters) Date: Thu, 14 Apr 2016 11:26:48 +0200 Subject: [FieldTrip] Simbio works with ft_volumereslice but leadfield In-Reply-To: <1460557552027.85876@nin.knaw.nl> References: <1460557552027.85876@nin.knaw.nl> Message-ID: <570F6258.50305@uni-muenster.de> Dear Rajat, we will need a little bit more informations where you are stuck or where the calculations are way too long? In ft_prepare_headmodel the FEM stiffness matrix is computed, which should not take much time. In ft_prepare_sourcemodel, a so-called FE transfer matrix is computed. To do so, for each electrode (but reference) a FEM linear equation system needs to be solved. The time for it thus scales with your number of electrodes. A fully-populated matrix will be resulting that has "number of electrodes -1" many rows and "number of FE nodes" many columns. For a reasonable number of electrodes and with your big memory (32 GB), this should not cause any trouble, but ft_prepare_sourcemodel might be the computationally most expensive step (but has to be done only once for a given FE model and electrode setup, so just start it in the evening). Once the transfer matrix is computed, each FEM forward computation is extremenly fast and therefore also the setup of the leadfield matrix with ft_prepare_leadfield. This should be the case, because for each source, only a right-hand-side in the size "number of FE nodes", but with only about 30 nonzeros, has to be computed and multiplied with the transfer matrix, which takes all together only milliseconds. So a 128^3 grid should not cause any trouble, as long as the transfer matrix fits in the memory (which should also be the case with 32GB), so that the computer doesn't need to swap. Best regards Carsten Am 13.04.2016 um 16:25 schrieb Rajat Thomas: > Dear all, > > Last week I asked for help with Simbio and after following the suggestion of volume reslicing magically the > simbio based headmodel was created. > > But my leadfield calculations are taking way too long. > It is a 128^3 grid and am running it on my desktop. (2.4 GHz, plenty of memory 32GB) > > Could anyone give me a rough ball park on how long it should take to create a leadfield? > > Thank you. > Rajat > > > > Rajat Mani Thomas > Social Brain Lab > Netherlands Institute for Neuroscience > Amsterdam > > ________________________________________ > From: fieldtrip-bounces at science.ru.nl on behalf of fieldtrip-request at science.ru.nl > Sent: 08 April 2016 12:00 > To: fieldtrip at science.ru.nl > Subject: fieldtrip Digest, Vol 65, Issue 7 > > Send fieldtrip mailing list submissions to > fieldtrip at science.ru.nl > > To subscribe or unsubscribe via the World Wide Web, visit > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > or, via email, send a message with subject or body 'help' to > fieldtrip-request at science.ru.nl > > You can reach the person managing the list at > fieldtrip-owner at science.ru.nl > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of fieldtrip digest..." > > > Today's Topics: > > 1. Re: FEM using Simbio (Johannes Vorwerk) > 2. Re: FEM using Simbio (Cristiano Micheli) > 3. Dipole fitting (Giovanni Pellegrino) > 4. Birmingham-Illinois BRIDGE Fellowships (Ole Jensen) > 5. Using FieldTrip to analyse LFP recordings in rat > (laetitia.lalla at inserm.fr) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Thu, 7 Apr 2016 14:25:42 +0200 > From: Johannes Vorwerk > To: FieldTrip discussion list > Subject: Re: [FieldTrip] FEM using Simbio > Message-ID: <435735E3-7D87-4DD6-A2C1-E2BBFBBF4B44 at googlemail.com> > Content-Type: text/plain; charset="utf-8" > > Hi, > > this question was already answered in this thread > > http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html > > If ft_volumereslice is not applied before the mesh generation, the afterwards applied transformation might flip the directions of the mesh, leading to the described error. > > Best, > Johannes > >> Am 06.04.2016 um 16:03 schrieb Carsten Wolters : >> >> Dear Rajat, >> >> the element-node cards of SimBio-NeuroFEM need to follow certain orientations (see www.simbio.de ). >> >> If you do not want to struggle with meshing/ordering, use the SimBio-VGRID mesher >> http://vgrid.simbio.de/ >> that follows the required ordering of nodes. You might use this mesher to produce 1mm geometry-adapted FEM meshes >> that show good overall performance, see >> http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf >> and >> http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf >> (latter was just accepted by NeuroImage). >> >> Best regards >> Carsten >> >> Am 06.04.2016 um 15:10 schrieb Rajat Thomas: >>> Dear all, >>> >>> Has anyone used the FEM approach to Headmodels using Simbio recently? >>> >>> If so, I get this error: >>> "Elements have wrong orientation or are degenerated" >>> >>> Any ideas? >>> >>> cfg = []; >>> cfg.method ='simbio'; >>> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows mesh.tissyelabel >>> vol = ft_prepare_headmodel(cfg, mesh); >>> >>> And; >>> ? >>> disp(mesh) >>> hex: [545883x8 double] >>> pnt: [569722x3 double] >>> labels: [545883x1 double] >>> tissue: [545883x1 double] >>> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >>> unit: 'mm' >>> cfg: [1x1 struct] >>> >>> Any help would be highly appreciated. >>> >>> Rajat >>> >>> >>> >>> >>> >>> >>> Rajat Mani Thomas >>> Social Brain Lab >>> Netherlands Institute for Neuroscience >>> Amsterdam >>> >>> >>> _______________________________________________ >>> 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 > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > Message: 2 > Date: Thu, 7 Apr 2016 17:36:37 +0200 > From: Cristiano Micheli > To: FieldTrip discussion list > Subject: Re: [FieldTrip] FEM using Simbio > Message-ID: > > Content-Type: text/plain; charset="utf-8" > > Hi Rajat > > My guess is that the orientations of your hexahedrons are not correct. > According to a low-level file's internal rules, elements' orientations have > to abide strict rules (not sure what exactly the contraints are in this > case though...). > I had same problems when for example the triangular boundaries used to > define the 3d hexahedral mesh were not topologically correct, to start with. > Admittedly this approach requires a lot of technical expertise. > Can I ask you what do you need a FEM model for? > > Regards > Cris Micheli > > > > > On Wed, Apr 6, 2016 at 3:10 PM, Rajat Thomas wrote: > >> Dear all, >> >> >> Has anyone used the FEM approach to Headmodels using Simbio recently? >> >> >> If so, I get this error: >> "Elements have wrong orientation or are degenerated" >> >> Any ideas? >> >> cfg = []; >> >> cfg.method ='simbio'; >> >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows >> mesh.tissyelabel >> >> vol = ft_prepare_headmodel(cfg, mesh); >> >> >> And; >> >> ? >> disp(mesh) >> hex: [545883x8 double] >> pnt: [569722x3 double] >> labels: [545883x1 double] >> tissue: [545883x1 double] >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >> unit: 'mm' >> cfg: [1x1 struct] >> >> >> Any help would be highly appreciated. >> >> Rajat >> >> >> >> >> >> >> Rajat Mani Thomas >> Social Brain Lab >> Netherlands Institute for Neuroscience >> Amsterdam >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > Message: 3 > Date: Thu, 7 Apr 2016 15:02:05 -0400 > From: Giovanni Pellegrino > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Dipole fitting > Message-ID: > > Content-Type: text/plain; charset="utf-8" > > Dear Fieldtrippers, > > Do you know if the FieldTrip Dipole Fitting has been compared to the CTF, > Elekta, BESA or Curry? Are you aware of any study on this topic? > > Thanks in advance for your help > > Giovanni > > -- > Giovanni Pellegrino, MD > Multimodal Functional Imaging Laboratory > Montreal Neurological Institute, McGill University > Address: 332 Duff Medical Building, 3775 rue University, Montreal, QC, H3A > 2B4, Canada > Phone: (514) 398?1678 > Fax: (514) 398?7461 > Email: giovannipellegrino at gmail.com, giovanni.pellegrino2 at mcgill.ca > Homepage: http://www.bic.mni.mcgill.ca/ResearchLabsMFIL/PeopleGiovanni > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > Message: 4 > Date: Fri, 8 Apr 2016 09:23:46 +0200 > From: Ole Jensen > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Birmingham-Illinois BRIDGE Fellowships > Message-ID: <57075C82.8030309 at donders.ru.nl> > Content-Type: text/plain; charset=utf-8; format=flowed > > Dear all, > > I would like to point you to a set of Birmingham-Illinois BRIDGE > Fellowships providing some exciting research and career prospects: > http://www.birminghamillinoisbridge.org/index.php/fellows/ > > In particular the areas 'Cognition and Ageing' and 'Brain Trauma' could > be relevant for candidates with EEG/MEG expertise. > > All the best, > > Ole > > -- > Prof. dr. Ole Jensen > http://www.neuosc.com > > > > ------------------------------ > > Message: 5 > Date: Fri, 08 Apr 2016 10:27:58 +0200 > From: laetitia.lalla at inserm.fr > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Using FieldTrip to analyse LFP recordings in rat > Message-ID: <628babdc107aebd4cc7588ea87ce5ea6 at inserm.fr> > Content-Type: text/plain; charset="utf-8" > > > > Hello everyone, > > my name is Laetitia and I'm a Phd student in Marseille (France). I'm > doing in-vivo recording in freely-moving rats : I implant them with 2 > electrodes deep into 2 different regions of the brain. I'm studying the > Local Field Potentials and I want to use FieldTrip to analyse the data. > > To simplify : > > - I have 2 rats. > > - Each rat did 20 sessions of the task (on 20 different days). > > - Each session consists of 20 trials of condition 1 and 20 trials of > condition 2. > > I have 2 questions. > > 1) I have the feeling it would be meaningless to do "source > reconstruction" because my electrodes are already deep inside my > "source" and the LFP I am recording is very local. (My electrodes have > 32 channels separated by 20-200 ?m. The LFP is very very similar across > all the channels, so I averaged over the 32 channels to have one signal > for each region.) > > However, I see that 2 different functions exist for the statistics : > FT_FREQSTATISTICS AND FT_SOURCESTATISTICS. So far, I've been using > ft_freqstatistics but I encounter some issues (for exemple, doingIch werde nachfragen. Es wird doch immer in ft_prepare_sourcemodel > die Transfermatrix gerechnet, sodass > > in ft_prepare_leadfield nur noch Multiplikationen dieser > Transfermatrix mit den vielen rechten Seiten > > gerechnet wird, was ja schnell gehen sollte. Ich frage, wo es > hakt. > > > monte-carlo permutation test to assess the imaginary coherence). I > thought of computing it manually, but I'm thinking that maybe more stuff > are implemented in ft_sourcestatisctics ? > > ? Are these 2 functions fundamentally different or do they call the same > sub-fonctions (and my problem has actually nothing to do with that) ? > > 2) I'm a bit confused with the vocabulary from EEG and MEG studies (I'm > not used to it yet...). From what I understood, in human studies, you > can do comparison for a single subject (across trials) or across > subjects. But I have 3 levels of comparisons in my design : > > - WITHIN A SESSION, I WANT TO COMPARE ACROSS TRIALS (the 20 trials of > condition 1 VS the 20 trials of condition 2). > > - WITHIN A RAT, I WANT TO COMPARE ACROSS SESSIONS (between the 2 > conditions) > > - then - in the very end - ACROSS RATS. But I have only 2 rats so far, > so I will deal with this later. > > I'm a bit confused when reading the tutorials and the mailing list, > especially when it comes to the statistics... For example : this is from > an email from 2013 by Eric Maris about "Nonparametric statistical > testing of phase coherence" > (http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006401.html) > "To compare coherence between conditions across subjects (instead of > trials), you need a different statfun: depsamplesT (for a > within-subjects design; subjects have participated in all conditions) or > indepsamplesT (for a between-subjects design; subjects have participated > in only one condition)." > > ? If I want to compare across sessions (for a same rat), can I actually > consider that my different sessions are "subjects"? And then compare > coherence "across subjects" would be doing it "across sessions" ? And I > would be in a "within-subject design" since my sessions involve the 2 > conditions every time ? > > I realise that it may be very confusing... I hope you will understand my > problem ! > > And if anyone already applied fieldtrip functions to do statistics on a > different framework that the usual EEG/MEG, please let me know ! > > Thanks a lot, > > Laetitia Lalla > > PhD Student in Neuroscience > > INMED, Marseille, France > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > ------------------------------ > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > End of fieldtrip Digest, Vol 65, Issue 7 > **************************************** > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- A non-text attachment was scrubbed... Name: carsten_wolters.vcf Type: text/x-vcard Size: 402 bytes Desc: not available URL: From erin.white at sickkids.ca Thu Apr 14 20:26:37 2016 From: erin.white at sickkids.ca (Erin White) Date: Thu, 14 Apr 2016 18:26:37 +0000 Subject: [FieldTrip] Grand average with deleted channels In-Reply-To: References: Message-ID: <0D4EE8880DEE3047BEC905C0EC463F8C3E52629B@SKMBXX03.sickkids.ca> Dear Eliana, One option for you would be, rather than deleting the bad channels, to interpolate what their activity would be from the average of surrounding channels. You can do this with FT_CHANNELREPAIR and it's pretty straightforward http://www.fieldtriptoolbox.org/reference/channelrepair Good luck with it! Erin ---------------------------------------------------- Erin White, PhD Post-Doctoral Research Fellow Neurosciences and Mental Health The Hospital for Sick Children 555 University Avenue Toronto, Ontario Canada Telephone: (647)834-7813 ________________________________ From: fieldtrip-bounces at science.ru.nl [fieldtrip-bounces at science.ru.nl] on behalf of Eliana Nicolaisen [elinicolaisen at gmail.com] Sent: April 11, 2016 10:21 AM To: fieldtrip at science.ru.nl Subject: [FieldTrip] Grand average with deleted channels Dear all, I'm trying to make an ERP grand average using version 20150301. In some subjects I deleted bad channels. Those channels were replaced for NaNs. When I make the grand average using ft_timelockaverage, the grand average is composed only for the common channels across subjects. In other words, in channels deleated at least in one subject the grand average is NaN. This is because ft_timelockanalysis in this version calculates the average making a sum and dividng into degrees of freedom: grandavg.avg = reshape(sum(avgmat, 1), datsiz)./ResultDOF; (in line 187 of revision '$Id: ft_timelockgrandaverage.m 10194 2015-02-11 09:08:16Z roboos $') However, I tried version 20121014 that my colleague uses. In this version ft_timelockedanalysis makes a mean: ResultGrandavg = mean(avgmat, 1); (in line 183 of revision '$Id: ft_timelockgrandaverage.m 6750 2012-10-13 15:07:32Z roboos $') In the version 20121014 is easy to make a correction that calculates a grand average taking into account NaNs (just changing mean for nanmean). However, in version 20150301 making a similar correction seems more complicated. Question 1: Why version 20150301 calculates average using sum and division instead of using nanmean? Question 2: Do someone have a suggestion about how to change version 20150301? Any comment would be greatly appreciated. Kind regards, Eliana Nicolaisen ________________________________ This e-mail may contain confidential, personal and/or health information(information which may be subject to legal restrictions on use, retention and/or disclosure) for the sole use of the intended recipient. Any review or distribution by anyone other than the person for whom it was originally intended is strictly prohibited. If you have received this e-mail in error, please contact the sender and delete all copies. -------------- next part -------------- An HTML attachment was scrubbed... URL: From j.vorwerk at uni-muenster.de Thu Apr 14 23:28:46 2016 From: j.vorwerk at uni-muenster.de (Johannes Vorwerk) Date: Thu, 14 Apr 2016 15:28:46 -0600 Subject: [FieldTrip] Simbio works with ft_volumereslice but leadfield In-Reply-To: References: <1460557552027.85876@nin.knaw.nl> Message-ID: <82D66CB4-DE42-409C-B350-E5DA0984A07E@googlemail.com> Hi Debora, could you indicate which part of the computation is the most time consuming, i.e., calculation of the transfer matrix or the subsequent computation of the dipole solutions? Principally, it should be possible to parallelize many of these steps, however, this wasn’t added to the checked-in code yet for reasons of stability/compatibility. Best, Johannes > Am 14.04.2016 um 02:21 schrieb Debora Desideri : > > Dear Rajat, > I am also using Simbio and I usually run the leadfield calculation overnight since it takes approximatelly 12-15 hours for 64 EEG channels with a grid of 6 mm resolution ( 2.60 GHz, 32 GB RAM). > I don't know whether there is a way to speed the process up. Maybe we just need to be patient, or work on a very powerful machine. > > Best, > Debora > > > On Wed, Apr 13, 2016 at 4:25 PM, Rajat Thomas > wrote: > Dear all, > > Last week I asked for help with Simbio and after following the suggestion of volume reslicing magically the > simbio based headmodel was created. > > But my leadfield calculations are taking way too long. > It is a 128^3 grid and am running it on my desktop. (2.4 GHz, plenty of memory 32GB) > > Could anyone give me a rough ball park on how long it should take to create a leadfield? > > Thank you. > Rajat > > > > Rajat Mani Thomas > Social Brain Lab > Netherlands Institute for Neuroscience > Amsterdam > > ________________________________________ > From: fieldtrip-bounces at science.ru.nl > on behalf of fieldtrip-request at science.ru.nl > > Sent: 08 April 2016 12:00 > To: fieldtrip at science.ru.nl > Subject: fieldtrip Digest, Vol 65, Issue 7 > > Send fieldtrip mailing list submissions to > fieldtrip at science.ru.nl > > To subscribe or unsubscribe via the World Wide Web, visit > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > or, via email, send a message with subject or body 'help' to > fieldtrip-request at science.ru.nl > > You can reach the person managing the list at > fieldtrip-owner at science.ru.nl > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of fieldtrip digest..." > > > Today's Topics: > > 1. Re: FEM using Simbio (Johannes Vorwerk) > 2. Re: FEM using Simbio (Cristiano Micheli) > 3. Dipole fitting (Giovanni Pellegrino) > 4. Birmingham-Illinois BRIDGE Fellowships (Ole Jensen) > 5. Using FieldTrip to analyse LFP recordings in rat > (laetitia.lalla at inserm.fr ) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Thu, 7 Apr 2016 14:25:42 +0200 > From: Johannes Vorwerk > > To: FieldTrip discussion list > > Subject: Re: [FieldTrip] FEM using Simbio > Message-ID: <435735E3-7D87-4DD6-A2C1-E2BBFBBF4B44 at googlemail.com > > Content-Type: text/plain; charset="utf-8" > > Hi, > > this question was already answered in this thread > > http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html > > > If ft_volumereslice is not applied before the mesh generation, the afterwards applied transformation might flip the directions of the mesh, leading to the described error. > > Best, > Johannes > > > Am 06.04.2016 um 16:03 schrieb Carsten Wolters >: > > > > Dear Rajat, > > > > the element-node cards of SimBio-NeuroFEM need to follow certain orientations (see www.simbio.de >). > > > > If you do not want to struggle with meshing/ordering, use the SimBio-VGRID mesher > > http://vgrid.simbio.de/ > > > that follows the required ordering of nodes. You might use this mesher to produce 1mm geometry-adapted FEM meshes > > that show good overall performance, see > > http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf > > > and > > http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf > > > (latter was just accepted by NeuroImage). > > > > Best regards > > Carsten > > > > Am 06.04.2016 um 15:10 schrieb Rajat Thomas: > >> Dear all, > >> > >> Has anyone used the FEM approach to Headmodels using Simbio recently? > >> > >> If so, I get this error: > >> "Elements have wrong orientation or are degenerated" > >> > >> Any ideas? > >> > >> cfg = []; > >> cfg.method ='simbio'; > >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows mesh.tissyelabel > >> vol = ft_prepare_headmodel(cfg, mesh); > >> > >> And; > >> ? > >> disp(mesh) > >> hex: [545883x8 double] > >> pnt: [569722x3 double] > >> labels: [545883x1 double] > >> tissue: [545883x1 double] > >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} > >> unit: 'mm' > >> cfg: [1x1 struct] > >> > >> Any help would be highly appreciated. > >> > >> Rajat > >> > >> > >> > >> > >> > >> > >> Rajat Mani Thomas > >> Social Brain Lab > >> Netherlands Institute for Neuroscience > >> Amsterdam > >> > >> > >> _______________________________________________ > >> 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 > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > > ------------------------------ > > Message: 2 > Date: Thu, 7 Apr 2016 17:36:37 +0200 > From: Cristiano Micheli > > To: FieldTrip discussion list > > Subject: Re: [FieldTrip] FEM using Simbio > Message-ID: > > > Content-Type: text/plain; charset="utf-8" > > Hi Rajat > > My guess is that the orientations of your hexahedrons are not correct. > According to a low-level file's internal rules, elements' orientations have > to abide strict rules (not sure what exactly the contraints are in this > case though...). > I had same problems when for example the triangular boundaries used to > define the 3d hexahedral mesh were not topologically correct, to start with. > Admittedly this approach requires a lot of technical expertise. > Can I ask you what do you need a FEM model for? > > Regards > Cris Micheli > > > > > On Wed, Apr 6, 2016 at 3:10 PM, Rajat Thomas > wrote: > > > Dear all, > > > > > > Has anyone used the FEM approach to Headmodels using Simbio recently? > > > > > > If so, I get this error: > > "Elements have wrong orientation or are degenerated" > > > > Any ideas? > > > > cfg = []; > > > > cfg.method ='simbio'; > > > > cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows > > mesh.tissyelabel > > > > vol = ft_prepare_headmodel(cfg, mesh); > > > > > > And; > > > > ? > > disp(mesh) > > hex: [545883x8 double] > > pnt: [569722x3 double] > > labels: [545883x1 double] > > tissue: [545883x1 double] > > tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} > > unit: 'mm' > > cfg: [1x1 struct] > > > > > > Any help would be highly appreciated. > > > > Rajat > > > > > > > > > > > > > > Rajat Mani Thomas > > Social Brain Lab > > Netherlands Institute for Neuroscience > > Amsterdam > > > > _______________________________________________ > > fieldtrip mailing list > > fieldtrip at donders.ru.nl > > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > > ------------------------------ > > Message: 3 > Date: Thu, 7 Apr 2016 15:02:05 -0400 > From: Giovanni Pellegrino > > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Dipole fitting > Message-ID: > > > Content-Type: text/plain; charset="utf-8" > > Dear Fieldtrippers, > > Do you know if the FieldTrip Dipole Fitting has been compared to the CTF, > Elekta, BESA or Curry? Are you aware of any study on this topic? > > Thanks in advance for your help > > Giovanni > > -- > Giovanni Pellegrino, MD > Multimodal Functional Imaging Laboratory > Montreal Neurological Institute, McGill University > Address: 332 Duff Medical Building, 3775 rue University, Montreal, QC, H3A > 2B4, Canada > Phone: (514) 398?1678 > Fax: (514) 398?7461 > Email: giovannipellegrino at gmail.com , giovanni.pellegrino2 at mcgill.ca > Homepage: http://www.bic.mni.mcgill.ca/ResearchLabsMFIL/PeopleGiovanni > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > > ------------------------------ > > Message: 4 > Date: Fri, 8 Apr 2016 09:23:46 +0200 > From: Ole Jensen > > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Birmingham-Illinois BRIDGE Fellowships > Message-ID: <57075C82.8030309 at donders.ru.nl > > Content-Type: text/plain; charset=utf-8; format=flowed > > Dear all, > > I would like to point you to a set of Birmingham-Illinois BRIDGE > Fellowships providing some exciting research and career prospects: > http://www.birminghamillinoisbridge.org/index.php/fellows/ > > In particular the areas 'Cognition and Ageing' and 'Brain Trauma' could > be relevant for candidates with EEG/MEG expertise. > > All the best, > > Ole > > -- > Prof. dr. Ole Jensen > http://www.neuosc.com > > > > ------------------------------ > > Message: 5 > Date: Fri, 08 Apr 2016 10:27:58 +0200 > From: laetitia.lalla at inserm.fr > To: fieldtrip at science.ru.nl > Subject: [FieldTrip] Using FieldTrip to analyse LFP recordings in rat > Message-ID: <628babdc107aebd4cc7588ea87ce5ea6 at inserm.fr > > Content-Type: text/plain; charset="utf-8" > > > > Hello everyone, > > my name is Laetitia and I'm a Phd student in Marseille (France). I'm > doing in-vivo recording in freely-moving rats : I implant them with 2 > electrodes deep into 2 different regions of the brain. I'm studying the > Local Field Potentials and I want to use FieldTrip to analyse the data. > > To simplify : > > - I have 2 rats. > > - Each rat did 20 sessions of the task (on 20 different days). > > - Each session consists of 20 trials of condition 1 and 20 trials of > condition 2. > > I have 2 questions. > > 1) I have the feeling it would be meaningless to do "source > reconstruction" because my electrodes are already deep inside my > "source" and the LFP I am recording is very local. (My electrodes have > 32 channels separated by 20-200 ?m. The LFP is very very similar across > all the channels, so I averaged over the 32 channels to have one signal > for each region.) > > However, I see that 2 different functions exist for the statistics : > FT_FREQSTATISTICS AND FT_SOURCESTATISTICS. So far, I've been using > ft_freqstatistics but I encounter some issues (for exemple, doing > monte-carlo permutation test to assess the imaginary coherence). I > thought of computing it manually, but I'm thinking that maybe more stuff > are implemented in ft_sourcestatisctics ? > > ? Are these 2 functions fundamentally different or do they call the same > sub-fonctions (and my problem has actually nothing to do with that) ? > > 2) I'm a bit confused with the vocabulary from EEG and MEG studies (I'm > not used to it yet...). From what I understood, in human studies, you > can do comparison for a single subject (across trials) or across > subjects. But I have 3 levels of comparisons in my design : > > - WITHIN A SESSION, I WANT TO COMPARE ACROSS TRIALS (the 20 trials of > condition 1 VS the 20 trials of condition 2). > > - WITHIN A RAT, I WANT TO COMPARE ACROSS SESSIONS (between the 2 > conditions) > > - then - in the very end - ACROSS RATS. But I have only 2 rats so far, > so I will deal with this later. > > I'm a bit confused when reading the tutorials and the mailing list, > especially when it comes to the statistics... For example : this is from > an email from 2013 by Eric Maris about "Nonparametric statistical > testing of phase coherence" > (http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006401.html ) > "To compare coherence between conditions across subjects (instead of > trials), you need a different statfun: depsamplesT (for a > within-subjects design; subjects have participated in all conditions) or > indepsamplesT (for a between-subjects design; subjects have participated > in only one condition)." > > ? If I want to compare across sessions (for a same rat), can I actually > consider that my different sessions are "subjects"? And then compare > coherence "across subjects" would be doing it "across sessions" ? And I > would be in a "within-subject design" since my sessions involve the 2 > conditions every time ? > > I realise that it may be very confusing... I hope you will understand my > problem ! > > And if anyone already applied fieldtrip functions to do statistics on a > different framework that the usual EEG/MEG, please let me know ! > > Thanks a lot, > > Laetitia Lalla > > PhD Student in Neuroscience > > INMED, Marseille, France > > > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: > > > ------------------------------ > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > End of fieldtrip Digest, Vol 65, Issue 7 > **************************************** > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > > > -- > > Debora Desideri, PhD Student > BNP Lab - Neurology Department > University Hospital Tübingen > Eberhard Karls University Tübingen > Hoppe-Seyler Str. 3 > D-72076 Tübingen > Tel: +49 7071/29 80478 > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From deb.desideri at gmail.com Fri Apr 15 09:55:43 2016 From: deb.desideri at gmail.com (Debora Desideri) Date: Fri, 15 Apr 2016 09:55:43 +0200 Subject: [FieldTrip] Simbio works with ft_volumereslice but leadfield In-Reply-To: <82D66CB4-DE42-409C-B350-E5DA0984A07E@googlemail.com> References: <1460557552027.85876@nin.knaw.nl> <82D66CB4-DE42-409C-B350-E5DA0984A07E@googlemail.com> Message-ID: Dear Johannes, the time consuming part is when I call ft_prepare_leadfield. The I used this precomputed leadfields for the computation of the dipole solution and this is actually quite fast. I started to use the FEM model only recently and I thought the long lasting calculation was normal. Is there a way to have a faster compuatation of leadfields? Best, Debora On Thu, Apr 14, 2016 at 11:28 PM, Johannes Vorwerk < j.vorwerk at uni-muenster.de> wrote: > Hi Debora, > > could you indicate which part of the computation is the most time > consuming, i.e., calculation of the transfer matrix or the subsequent > computation of the dipole solutions? Principally, it should be possible to > parallelize many of these steps, however, this wasn’t added to the > checked-in code yet for reasons of stability/compatibility. > > Best, > Johannes > > Am 14.04.2016 um 02:21 schrieb Debora Desideri : > > Dear Rajat, > I am also using Simbio and I usually run the leadfield calculation > overnight since it takes approximatelly 12-15 hours for 64 EEG channels > with a grid of 6 mm resolution ( 2.60 GHz, 32 GB RAM). > I don't know whether there is a way to speed the process up. Maybe we just > need to be patient, or work on a very powerful machine. > > Best, > Debora > > > On Wed, Apr 13, 2016 at 4:25 PM, Rajat Thomas > wrote: > >> Dear all, >> >> Last week I asked for help with Simbio and after following the suggestion >> of volume reslicing magically the >> simbio based headmodel was created. >> >> But my leadfield calculations are taking way too long. >> It is a 128^3 grid and am running it on my desktop. (2.4 GHz, plenty of >> memory 32GB) >> >> Could anyone give me a rough ball park on how long it should take to >> create a leadfield? >> >> Thank you. >> Rajat >> >> >> >> Rajat Mani Thomas >> Social Brain Lab >> Netherlands Institute for Neuroscience >> Amsterdam >> >> ________________________________________ >> From: fieldtrip-bounces at science.ru.nl >> on behalf of fieldtrip-request at science.ru.nl < >> fieldtrip-request at science.ru.nl> >> Sent: 08 April 2016 12:00 >> To: fieldtrip at science.ru.nl >> Subject: fieldtrip Digest, Vol 65, Issue 7 >> >> Send fieldtrip mailing list submissions to >> fieldtrip at science.ru.nl >> >> To subscribe or unsubscribe via the World Wide Web, visit >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> or, via email, send a message with subject or body 'help' to >> fieldtrip-request at science.ru.nl >> >> You can reach the person managing the list at >> fieldtrip-owner at science.ru.nl >> >> When replying, please edit your Subject line so it is more specific >> than "Re: Contents of fieldtrip digest..." >> >> >> Today's Topics: >> >> 1. Re: FEM using Simbio (Johannes Vorwerk) >> 2. Re: FEM using Simbio (Cristiano Micheli) >> 3. Dipole fitting (Giovanni Pellegrino) >> 4. Birmingham-Illinois BRIDGE Fellowships (Ole Jensen) >> 5. Using FieldTrip to analyse LFP recordings in rat >> (laetitia.lalla at inserm.fr) >> >> >> ---------------------------------------------------------------------- >> >> Message: 1 >> Date: Thu, 7 Apr 2016 14:25:42 +0200 >> From: Johannes Vorwerk >> To: FieldTrip discussion list >> Subject: Re: [FieldTrip] FEM using Simbio >> Message-ID: <435735E3-7D87-4DD6-A2C1-E2BBFBBF4B44 at googlemail.com> >> Content-Type: text/plain; charset="utf-8" >> >> Hi, >> >> this question was already answered in this thread >> >> http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html < >> http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html> >> >> If ft_volumereslice is not applied before the mesh generation, the >> afterwards applied transformation might flip the directions of the mesh, >> leading to the described error. >> >> Best, >> Johannes >> >> > Am 06.04.2016 um 16:03 schrieb Carsten Wolters < >> carsten.wolters at uni-muenster.de>: >> > >> > Dear Rajat, >> > >> > the element-node cards of SimBio-NeuroFEM need to follow certain >> orientations (see www.simbio.de ). >> > >> > If you do not want to struggle with meshing/ordering, use the >> SimBio-VGRID mesher >> > http://vgrid.simbio.de/ >> > that follows the required ordering of nodes. You might use this mesher >> to produce 1mm geometry-adapted FEM meshes >> > that show good overall performance, see >> > >> http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf >> < >> http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf >> > >> > and >> > >> http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf >> < >> http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf >> > >> > (latter was just accepted by NeuroImage). >> > >> > Best regards >> > Carsten >> > >> > Am 06.04.2016 um 15:10 schrieb Rajat Thomas: >> >> Dear all, >> >> >> >> Has anyone used the FEM approach to Headmodels using Simbio recently? >> >> >> >> If so, I get this error: >> >> "Elements have wrong orientation or are degenerated" >> >> >> >> Any ideas? >> >> >> >> cfg = []; >> >> cfg.method ='simbio'; >> >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows >> mesh.tissyelabel >> >> vol = ft_prepare_headmodel(cfg, mesh); >> >> >> >> And; >> >> ? >> >> disp(mesh) >> >> hex: [545883x8 double] >> >> pnt: [569722x3 double] >> >> labels: [545883x1 double] >> >> tissue: [545883x1 double] >> >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >> >> unit: 'mm' >> >> cfg: [1x1 struct] >> >> >> >> Any help would be highly appreciated. >> >> >> >> Rajat >> >> >> >> >> >> >> >> >> >> >> >> >> >> Rajat Mani Thomas >> >> Social Brain Lab >> >> Netherlands Institute for Neuroscience >> >> Amsterdam >> >> >> >> >> >> _______________________________________________ >> >> fieldtrip mailing list >> >> fieldtrip at donders.ru.nl >> >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip < >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip> >> > _______________________________________________ >> > fieldtrip mailing list >> > fieldtrip at donders.ru.nl >> > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip < >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip> >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> URL: < >> http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160407/2ea995ee/attachment-0001.html >> > >> >> ------------------------------ >> >> Message: 2 >> Date: Thu, 7 Apr 2016 17:36:37 +0200 >> From: Cristiano Micheli >> To: FieldTrip discussion list >> Subject: Re: [FieldTrip] FEM using Simbio >> Message-ID: >> < >> CADW7XCAQONsZ_ujPhkffskZ+j-mnHnAzunS68CdKU6MLSosUPA at mail.gmail.com> >> Content-Type: text/plain; charset="utf-8" >> >> Hi Rajat >> >> My guess is that the orientations of your hexahedrons are not correct. >> According to a low-level file's internal rules, elements' orientations >> have >> to abide strict rules (not sure what exactly the contraints are in this >> case though...). >> I had same problems when for example the triangular boundaries used to >> define the 3d hexahedral mesh were not topologically correct, to start >> with. >> Admittedly this approach requires a lot of technical expertise. >> Can I ask you what do you need a FEM model for? >> >> Regards >> Cris Micheli >> >> >> >> >> On Wed, Apr 6, 2016 at 3:10 PM, Rajat Thomas >> wrote: >> >> > Dear all, >> > >> > >> > Has anyone used the FEM approach to Headmodels using Simbio recently? >> > >> > >> > If so, I get this error: >> > "Elements have wrong orientation or are degenerated" >> > >> > Any ideas? >> > >> > cfg = []; >> > >> > cfg.method ='simbio'; >> > >> > cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows >> > mesh.tissyelabel >> > >> > vol = ft_prepare_headmodel(cfg, mesh); >> > >> > >> > And; >> > >> > ? >> > disp(mesh) >> > hex: [545883x8 double] >> > pnt: [569722x3 double] >> > labels: [545883x1 double] >> > tissue: [545883x1 double] >> > tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >> > unit: 'mm' >> > cfg: [1x1 struct] >> > >> > >> > Any help would be highly appreciated. >> > >> > Rajat >> > >> > >> > >> > >> > >> > >> > Rajat Mani Thomas >> > Social Brain Lab >> > Netherlands Institute for Neuroscience >> > Amsterdam >> > >> > _______________________________________________ >> > fieldtrip mailing list >> > fieldtrip at donders.ru.nl >> > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> > >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> URL: < >> http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160407/4adfe55a/attachment-0001.html >> > >> >> ------------------------------ >> >> Message: 3 >> Date: Thu, 7 Apr 2016 15:02:05 -0400 >> From: Giovanni Pellegrino >> To: fieldtrip at science.ru.nl >> Subject: [FieldTrip] Dipole fitting >> Message-ID: >> > u8GDw at mail.gmail.com> >> Content-Type: text/plain; charset="utf-8" >> >> Dear Fieldtrippers, >> >> Do you know if the FieldTrip Dipole Fitting has been compared to the CTF, >> Elekta, BESA or Curry? Are you aware of any study on this topic? >> >> Thanks in advance for your help >> >> Giovanni >> >> -- >> Giovanni Pellegrino, MD >> Multimodal Functional Imaging Laboratory >> Montreal Neurological Institute, McGill University >> Address: 332 Duff Medical Building, 3775 rue University, Montreal, QC, H3A >> 2B4, Canada >> Phone: (514) 398?1678 >> Fax: (514) 398?7461 >> Email: giovannipellegrino at gmail.com, giovanni.pellegrino2 at mcgill.ca >> Homepage: http://www.bic.mni.mcgill.ca/ResearchLabsMFIL/PeopleGiovanni >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> URL: < >> http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160407/d01144bd/attachment-0001.html >> > >> >> ------------------------------ >> >> Message: 4 >> Date: Fri, 8 Apr 2016 09:23:46 +0200 >> From: Ole Jensen >> To: fieldtrip at science.ru.nl >> Subject: [FieldTrip] Birmingham-Illinois BRIDGE Fellowships >> Message-ID: <57075C82.8030309 at donders.ru.nl> >> Content-Type: text/plain; charset=utf-8; format=flowed >> >> Dear all, >> >> I would like to point you to a set of Birmingham-Illinois BRIDGE >> Fellowships providing some exciting research and career prospects: >> http://www.birminghamillinoisbridge.org/index.php/fellows/ >> >> In particular the areas 'Cognition and Ageing' and 'Brain Trauma' could >> be relevant for candidates with EEG/MEG expertise. >> >> All the best, >> >> Ole >> >> -- >> Prof. dr. Ole Jensen >> http://www.neuosc.com >> >> >> >> ------------------------------ >> >> Message: 5 >> Date: Fri, 08 Apr 2016 10:27:58 +0200 >> From: laetitia.lalla at inserm.fr >> To: fieldtrip at science.ru.nl >> Subject: [FieldTrip] Using FieldTrip to analyse LFP recordings in rat >> Message-ID: <628babdc107aebd4cc7588ea87ce5ea6 at inserm.fr> >> Content-Type: text/plain; charset="utf-8" >> >> >> >> Hello everyone, >> >> my name is Laetitia and I'm a Phd student in Marseille (France). I'm >> doing in-vivo recording in freely-moving rats : I implant them with 2 >> electrodes deep into 2 different regions of the brain. I'm studying the >> Local Field Potentials and I want to use FieldTrip to analyse the data. >> >> To simplify : >> >> - I have 2 rats. >> >> - Each rat did 20 sessions of the task (on 20 different days). >> >> - Each session consists of 20 trials of condition 1 and 20 trials of >> condition 2. >> >> I have 2 questions. >> >> 1) I have the feeling it would be meaningless to do "source >> reconstruction" because my electrodes are already deep inside my >> "source" and the LFP I am recording is very local. (My electrodes have >> 32 channels separated by 20-200 ?m. The LFP is very very similar across >> all the channels, so I averaged over the 32 channels to have one signal >> for each region.) >> >> However, I see that 2 different functions exist for the statistics : >> FT_FREQSTATISTICS AND FT_SOURCESTATISTICS. So far, I've been using >> ft_freqstatistics but I encounter some issues (for exemple, doing >> monte-carlo permutation test to assess the imaginary coherence). I >> thought of computing it manually, but I'm thinking that maybe more stuff >> are implemented in ft_sourcestatisctics ? >> >> ? Are these 2 functions fundamentally different or do they call the same >> sub-fonctions (and my problem has actually nothing to do with that) ? >> >> 2) I'm a bit confused with the vocabulary from EEG and MEG studies (I'm >> not used to it yet...). From what I understood, in human studies, you >> can do comparison for a single subject (across trials) or across >> subjects. But I have 3 levels of comparisons in my design : >> >> - WITHIN A SESSION, I WANT TO COMPARE ACROSS TRIALS (the 20 trials of >> condition 1 VS the 20 trials of condition 2). >> >> - WITHIN A RAT, I WANT TO COMPARE ACROSS SESSIONS (between the 2 >> conditions) >> >> - then - in the very end - ACROSS RATS. But I have only 2 rats so far, >> so I will deal with this later. >> >> I'm a bit confused when reading the tutorials and the mailing list, >> especially when it comes to the statistics... For example : this is from >> an email from 2013 by Eric Maris about "Nonparametric statistical >> testing of phase coherence" >> (http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006401.html) >> "To compare coherence between conditions across subjects (instead of >> trials), you need a different statfun: depsamplesT (for a >> within-subjects design; subjects have participated in all conditions) or >> indepsamplesT (for a between-subjects design; subjects have participated >> in only one condition)." >> >> ? If I want to compare across sessions (for a same rat), can I actually >> consider that my different sessions are "subjects"? And then compare >> coherence "across subjects" would be doing it "across sessions" ? And I >> would be in a "within-subject design" since my sessions involve the 2 >> conditions every time ? >> >> I realise that it may be very confusing... I hope you will understand my >> problem ! >> >> And if anyone already applied fieldtrip functions to do statistics on a >> different framework that the usual EEG/MEG, please let me know ! >> >> Thanks a lot, >> >> Laetitia Lalla >> >> PhD Student in Neuroscience >> >> INMED, Marseille, France >> >> >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> URL: < >> http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160408/2aed96c1/attachment-0001.html >> > >> >> ------------------------------ >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> >> End of fieldtrip Digest, Vol 65, Issue 7 >> **************************************** >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> > > > > -- > > Debora Desideri, PhD Student > BNP Lab - Neurology Department > University Hospital Tübingen > Eberhard Karls University Tübingen > Hoppe-Seyler Str. 3 > D-72076 Tübingen > Tel: +49 7071/29 80478 > > _______________________________________________ > 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 > -- Debora Desideri, PhD Student BNP Lab - Neurology Department University Hospital Tübingen Eberhard Karls University Tübingen Hoppe-Seyler Str. 3 D-72076 Tübingen Tel: +49 7071/29 80478 -------------- next part -------------- An HTML attachment was scrubbed... URL: From Max.Cantor at Colorado.EDU Fri Apr 15 21:48:38 2016 From: Max.Cantor at Colorado.EDU (Max Cantor) Date: Fri, 15 Apr 2016 13:48:38 -0600 Subject: [FieldTrip] TFR mask stats question; Baselined vs unbaselined statistics question In-Reply-To: References: Message-ID: As a followup, I'd like to note that there was a mistake in the multiplot code in my prior post (I had in that code 1,3,5 instead of 1,2,3 as my indices for the stat cell array), and the comment for zlim was not relevant (that was for when I was plotting powspctrm, since the data were freqbaselined). Since the time I posted this, I've tried a few more things that have been somewhat successful. I have set frequency to [1 30], because gamma seemed to be very noisy and the data were bandpass filtered at [0.1 50]hz in the first place so I figured there would be no meaningful effect as high as 50hz. I have also played with the latency, testing a priori assumptions of the time window, as well as a general [0 1.8] window for TFR (and [0 1] window for ERP). Finally, I have tried the analyses using the nonparametric permutation test, but without the cluster correction (and setting cfg.alpha to 0.05 as opposed to 0.025, for the cluster statistics). When I do just the permutation test, I get the effects that I was anticipating in both ERP and TFR. It's only when I add in the cluster correction that I get no significant effects. Does anyone have an idea as to why this might be happening? Best, Max On Fri, Apr 8, 2016 at 3:02 PM, Max Cantor wrote: > Hi fieldtrippers, > > I have two unrelated stats questions, but I figured I'd post them together: > > 1. I've run within subjects permutation statistics testing the difference > between an anomaly and control condition for three different language > conditions; preposition, morphosyntax, and semantics. The code is nearly > identical for both my ERPs and TFRs, except that when I plot my ERPs with > cfg.maskparameter = 'mask', cfg.parameter = 'stat', and cfg.maskalpha = > 0.025, it seems to multiplot just fine, whereas when I try to do the same > for the TFRs, my multiplotted plots are blank, but when I comment out the > mask, the stat plots are fine. I'll attach the code, but is there something > I'm doing obviously wrong? Also, am I correct that my maskalpha should > correspond to my alpha, and not my cluster alpha? > > This is the TFR code, but the ERP code is the exact same except for with > timelocked data as the input and ft_timelockstatistics as the function. > > cfg = []; > cfg.method = 'montecarlo'; > cfg.statistic = 'depsamplesT'; > cfg.correctm = 'cluster'; > cfg.clusteralpha = 0.05; > cfg.clusterstatistic = 'maxsum'; > cfg.minnbchan = 2; > cfg.neighbours = neighbours; > cfg.tail = 0; > cfg.clustertail = 0; > cfg.alpha = 0.025; > cfg.numrandomization = 1000; > > nsubj = length(tot_tfr2_bl{1}); > design = zeros(2,2*nsubj); > for i = 1:nsubj > design(1,i) = i; > end > for i = 1:nsubj > design(1,nsubj+i) = i; > end > design(2,1:nsubj) = 1; > design(2,nsubj+1:2*nsubj) = 2; > > cfg.design = design; > cfg.uvar = 1; > cfg.ivar = 2; > > % Anomaly vs Control > stat_tfr{1} = ft_freqstatistics(cfg, tot_tfr2_bl{1}{:}, > tot_tfr2_bl{2}{:}); % Preposition > stat_tfr{2} = ft_freqstatistics(cfg, tot_tfr2_bl{3}{:}, > tot_tfr2_bl{4}{:}); % Semantics > stat_tfr{3} = ft_freqstatistics(cfg, tot_tfr2_bl{5}{:}, > tot_tfr2_bl{6}{:}); % Morphosyntax > > This is the plotting code. Again, it is virtually the same for the ERPs > except the non-stats configurations would be what makes sense for ERPs. > > % Anomaly vs Control TFR stats multiplot > > cfg = []; > cfg.xlim = [-0.2 1]; > cfg.zlim = [-3 3]; % proportion from baseline > cfg.layout = [max_dir '/quickcap64.mat']; > cfg.maskparameter = 'mask'; > cfg.parameter = 'stat'; > cfg.maskalpha = 0.025; > > ft_multiplotTFR(cfg, stat_tfr{1}); title('Preposition'); > ft_multiplotTFR(cfg, stat_tfr{3}); title('Semantic'); > ft_multiplotTFR(cfg, stat_tfr{5}); title('Morphosyntactic'); > > > 2. The second question is about analyzing baselined vs unbaselined data. > I've seen in the tutorials that there is a somewhat different method for > analyzing trial vs baseline period. However, what I've done instead (for > both ERP and TFR), is use the same within-subjects statistics as with > anomaly vs control, except with the inputs being baselined vs unbaselined > ERPs or TFRs, e.g. Baselined Preposition Anomaly vs Unbaselined Preposition > Anomaly, etc. I understand that the proposed method and my method are not > testing the same thing exactly, but is this a reasonable way of testing the > effect of the baselining anyway? > > Thanks, > > Max > > -- > Max Cantor > Graduate Student > Cognitive Neuroscience of Language Lab > University of Colorado Boulder > -- Max Cantor Graduate Student Cognitive Neuroscience of Language Lab University of Colorado Boulder -------------- next part -------------- An HTML attachment was scrubbed... URL: From j.vorwerk at uni-muenster.de Sun Apr 17 15:34:48 2016 From: j.vorwerk at uni-muenster.de (Johannes Vorwerk) Date: Sun, 17 Apr 2016 07:34:48 -0600 Subject: [FieldTrip] Simbio works with ft_volumereslice but leadfield In-Reply-To: References: <1460557552027.85876@nin.knaw.nl> <82D66CB4-DE42-409C-B350-E5DA0984A07E@googlemail.com> Message-ID: <24BC90ED-EEAA-4AAD-A0A3-0AB6E16E8108@googlemail.com> Hi, could you check if it’s the calculation of the transfer matrix (ft_prepare_vol_sens), which you can recoginze since the #electrode many equations are solved, or the call of leadfield_simbio that takes up the most time? It is normal that the matlab-code takes more time than the SimBio-standalon binary, since it includes some loops. I’ve never experienced such long computations as you did in my testings, so I didn’t think about it very much so far. One might try to find a way to formulate these parts without loops or use parallel loops at some points. Best, Johannes > Am 15.04.2016 um 01:55 schrieb Debora Desideri : > > Dear Johannes, > the time consuming part is when I call ft_prepare_leadfield. The I used this precomputed leadfields for the computation of the dipole solution and this is actually quite fast. > I started to use the FEM model only recently and I thought the long lasting calculation was normal. Is there a way to have a faster compuatation of leadfields? > > Best, > Debora > > > On Thu, Apr 14, 2016 at 11:28 PM, Johannes Vorwerk > wrote: > Hi Debora, > > could you indicate which part of the computation is the most time consuming, i.e., calculation of the transfer matrix or the subsequent computation of the dipole solutions? Principally, it should be possible to parallelize many of these steps, however, this wasn’t added to the checked-in code yet for reasons of stability/compatibility. > > Best, > Johannes > >> Am 14.04.2016 um 02:21 schrieb Debora Desideri >: >> >> Dear Rajat, >> I am also using Simbio and I usually run the leadfield calculation overnight since it takes approximatelly 12-15 hours for 64 EEG channels with a grid of 6 mm resolution ( 2.60 GHz, 32 GB RAM). >> I don't know whether there is a way to speed the process up. Maybe we just need to be patient, or work on a very powerful machine. >> >> Best, >> Debora >> >> >> On Wed, Apr 13, 2016 at 4:25 PM, Rajat Thomas > wrote: >> Dear all, >> >> Last week I asked for help with Simbio and after following the suggestion of volume reslicing magically the >> simbio based headmodel was created. >> >> But my leadfield calculations are taking way too long. >> It is a 128^3 grid and am running it on my desktop. (2.4 GHz, plenty of memory 32GB) >> >> Could anyone give me a rough ball park on how long it should take to create a leadfield? >> >> Thank you. >> Rajat >> >> >> >> Rajat Mani Thomas >> Social Brain Lab >> Netherlands Institute for Neuroscience >> Amsterdam >> >> ________________________________________ >> From: fieldtrip-bounces at science.ru.nl > on behalf of fieldtrip-request at science.ru.nl > >> Sent: 08 April 2016 12:00 >> To: fieldtrip at science.ru.nl >> Subject: fieldtrip Digest, Vol 65, Issue 7 >> >> Send fieldtrip mailing list submissions to >> fieldtrip at science.ru.nl >> >> To subscribe or unsubscribe via the World Wide Web, visit >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> or, via email, send a message with subject or body 'help' to >> fieldtrip-request at science.ru.nl >> >> You can reach the person managing the list at >> fieldtrip-owner at science.ru.nl >> >> When replying, please edit your Subject line so it is more specific >> than "Re: Contents of fieldtrip digest..." >> >> >> Today's Topics: >> >> 1. Re: FEM using Simbio (Johannes Vorwerk) >> 2. Re: FEM using Simbio (Cristiano Micheli) >> 3. Dipole fitting (Giovanni Pellegrino) >> 4. Birmingham-Illinois BRIDGE Fellowships (Ole Jensen) >> 5. Using FieldTrip to analyse LFP recordings in rat >> (laetitia.lalla at inserm.fr ) >> >> >> ---------------------------------------------------------------------- >> >> Message: 1 >> Date: Thu, 7 Apr 2016 14:25:42 +0200 >> From: Johannes Vorwerk > >> To: FieldTrip discussion list > >> Subject: Re: [FieldTrip] FEM using Simbio >> Message-ID: <435735E3-7D87-4DD6-A2C1-E2BBFBBF4B44 at googlemail.com > >> Content-Type: text/plain; charset="utf-8" >> >> Hi, >> >> this question was already answered in this thread >> >> http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html > >> >> If ft_volumereslice is not applied before the mesh generation, the afterwards applied transformation might flip the directions of the mesh, leading to the described error. >> >> Best, >> Johannes >> >> > Am 06.04.2016 um 16:03 schrieb Carsten Wolters >: >> > >> > Dear Rajat, >> > >> > the element-node cards of SimBio-NeuroFEM need to follow certain orientations (see www.simbio.de >). >> > >> > If you do not want to struggle with meshing/ordering, use the SimBio-VGRID mesher >> > http://vgrid.simbio.de/ > >> > that follows the required ordering of nodes. You might use this mesher to produce 1mm geometry-adapted FEM meshes >> > that show good overall performance, see >> > http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf > >> > and >> > http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf > >> > (latter was just accepted by NeuroImage). >> > >> > Best regards >> > Carsten >> > >> > Am 06.04.2016 um 15:10 schrieb Rajat Thomas: >> >> Dear all, >> >> >> >> Has anyone used the FEM approach to Headmodels using Simbio recently? >> >> >> >> If so, I get this error: >> >> "Elements have wrong orientation or are degenerated" >> >> >> >> Any ideas? >> >> >> >> cfg = []; >> >> cfg.method ='simbio'; >> >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows mesh.tissyelabel >> >> vol = ft_prepare_headmodel(cfg, mesh); >> >> >> >> And; >> >> ? >> >> disp(mesh) >> >> hex: [545883x8 double] >> >> pnt: [569722x3 double] >> >> labels: [545883x1 double] >> >> tissue: [545883x1 double] >> >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >> >> unit: 'mm' >> >> cfg: [1x1 struct] >> >> >> >> Any help would be highly appreciated. >> >> >> >> Rajat >> >> >> >> >> >> >> >> >> >> >> >> >> >> Rajat Mani Thomas >> >> Social Brain Lab >> >> Netherlands Institute for Neuroscience >> >> Amsterdam >> >> >> >> >> >> _______________________________________________ >> >> 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 > >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> URL: > >> >> ------------------------------ >> >> Message: 2 >> Date: Thu, 7 Apr 2016 17:36:37 +0200 >> From: Cristiano Micheli > >> To: FieldTrip discussion list > >> Subject: Re: [FieldTrip] FEM using Simbio >> Message-ID: >> > >> Content-Type: text/plain; charset="utf-8" >> >> Hi Rajat >> >> My guess is that the orientations of your hexahedrons are not correct. >> According to a low-level file's internal rules, elements' orientations have >> to abide strict rules (not sure what exactly the contraints are in this >> case though...). >> I had same problems when for example the triangular boundaries used to >> define the 3d hexahedral mesh were not topologically correct, to start with. >> Admittedly this approach requires a lot of technical expertise. >> Can I ask you what do you need a FEM model for? >> >> Regards >> Cris Micheli >> >> >> >> >> On Wed, Apr 6, 2016 at 3:10 PM, Rajat Thomas > wrote: >> >> > Dear all, >> > >> > >> > Has anyone used the FEM approach to Headmodels using Simbio recently? >> > >> > >> > If so, I get this error: >> > "Elements have wrong orientation or are degenerated" >> > >> > Any ideas? >> > >> > cfg = []; >> > >> > cfg.method ='simbio'; >> > >> > cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows >> > mesh.tissyelabel >> > >> > vol = ft_prepare_headmodel(cfg, mesh); >> > >> > >> > And; >> > >> > ? >> > disp(mesh) >> > hex: [545883x8 double] >> > pnt: [569722x3 double] >> > labels: [545883x1 double] >> > tissue: [545883x1 double] >> > tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >> > unit: 'mm' >> > cfg: [1x1 struct] >> > >> > >> > Any help would be highly appreciated. >> > >> > Rajat >> > >> > >> > >> > >> > >> > >> > Rajat Mani Thomas >> > Social Brain Lab >> > Netherlands Institute for Neuroscience >> > Amsterdam >> > >> > _______________________________________________ >> > fieldtrip mailing list >> > fieldtrip at donders.ru.nl >> > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> > >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> URL: > >> >> ------------------------------ >> >> Message: 3 >> Date: Thu, 7 Apr 2016 15:02:05 -0400 >> From: Giovanni Pellegrino > >> To: fieldtrip at science.ru.nl >> Subject: [FieldTrip] Dipole fitting >> Message-ID: >> > >> Content-Type: text/plain; charset="utf-8" >> >> Dear Fieldtrippers, >> >> Do you know if the FieldTrip Dipole Fitting has been compared to the CTF, >> Elekta, BESA or Curry? Are you aware of any study on this topic? >> >> Thanks in advance for your help >> >> Giovanni >> >> -- >> Giovanni Pellegrino, MD >> Multimodal Functional Imaging Laboratory >> Montreal Neurological Institute, McGill University >> Address: 332 Duff Medical Building, 3775 rue University, Montreal, QC, H3A >> 2B4, Canada >> Phone: (514) 398?1678 >> Fax: (514) 398?7461 >> Email: giovannipellegrino at gmail.com , giovanni.pellegrino2 at mcgill.ca >> Homepage: http://www.bic.mni.mcgill.ca/ResearchLabsMFIL/PeopleGiovanni >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> URL: > >> >> ------------------------------ >> >> Message: 4 >> Date: Fri, 8 Apr 2016 09:23:46 +0200 >> From: Ole Jensen > >> To: fieldtrip at science.ru.nl >> Subject: [FieldTrip] Birmingham-Illinois BRIDGE Fellowships >> Message-ID: <57075C82.8030309 at donders.ru.nl > >> Content-Type: text/plain; charset=utf-8; format=flowed >> >> Dear all, >> >> I would like to point you to a set of Birmingham-Illinois BRIDGE >> Fellowships providing some exciting research and career prospects: >> http://www.birminghamillinoisbridge.org/index.php/fellows/ >> >> In particular the areas 'Cognition and Ageing' and 'Brain Trauma' could >> be relevant for candidates with EEG/MEG expertise. >> >> All the best, >> >> Ole >> >> -- >> Prof. dr. Ole Jensen >> http://www.neuosc.com >> >> >> >> ------------------------------ >> >> Message: 5 >> Date: Fri, 08 Apr 2016 10:27:58 +0200 >> From: laetitia.lalla at inserm.fr >> To: fieldtrip at science.ru.nl >> Subject: [FieldTrip] Using FieldTrip to analyse LFP recordings in rat >> Message-ID: <628babdc107aebd4cc7588ea87ce5ea6 at inserm.fr > >> Content-Type: text/plain; charset="utf-8" >> >> >> >> Hello everyone, >> >> my name is Laetitia and I'm a Phd student in Marseille (France). I'm >> doing in-vivo recording in freely-moving rats : I implant them with 2 >> electrodes deep into 2 different regions of the brain. I'm studying the >> Local Field Potentials and I want to use FieldTrip to analyse the data. >> >> To simplify : >> >> - I have 2 rats. >> >> - Each rat did 20 sessions of the task (on 20 different days). >> >> - Each session consists of 20 trials of condition 1 and 20 trials of >> condition 2. >> >> I have 2 questions. >> >> 1) I have the feeling it would be meaningless to do "source >> reconstruction" because my electrodes are already deep inside my >> "source" and the LFP I am recording is very local. (My electrodes have >> 32 channels separated by 20-200 ?m. The LFP is very very similar across >> all the channels, so I averaged over the 32 channels to have one signal >> for each region.) >> >> However, I see that 2 different functions exist for the statistics : >> FT_FREQSTATISTICS AND FT_SOURCESTATISTICS. So far, I've been using >> ft_freqstatistics but I encounter some issues (for exemple, doing >> monte-carlo permutation test to assess the imaginary coherence). I >> thought of computing it manually, but I'm thinking that maybe more stuff >> are implemented in ft_sourcestatisctics ? >> >> ? Are these 2 functions fundamentally different or do they call the same >> sub-fonctions (and my problem has actually nothing to do with that) ? >> >> 2) I'm a bit confused with the vocabulary from EEG and MEG studies (I'm >> not used to it yet...). From what I understood, in human studies, you >> can do comparison for a single subject (across trials) or across >> subjects. But I have 3 levels of comparisons in my design : >> >> - WITHIN A SESSION, I WANT TO COMPARE ACROSS TRIALS (the 20 trials of >> condition 1 VS the 20 trials of condition 2). >> >> - WITHIN A RAT, I WANT TO COMPARE ACROSS SESSIONS (between the 2 >> conditions) >> >> - then - in the very end - ACROSS RATS. But I have only 2 rats so far, >> so I will deal with this later. >> >> I'm a bit confused when reading the tutorials and the mailing list, >> especially when it comes to the statistics... For example : this is from >> an email from 2013 by Eric Maris about "Nonparametric statistical >> testing of phase coherence" >> (http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006401.html ) >> "To compare coherence between conditions across subjects (instead of >> trials), you need a different statfun: depsamplesT (for a >> within-subjects design; subjects have participated in all conditions) or >> indepsamplesT (for a between-subjects design; subjects have participated >> in only one condition)." >> >> ? If I want to compare across sessions (for a same rat), can I actually >> consider that my different sessions are "subjects"? And then compare >> coherence "across subjects" would be doing it "across sessions" ? And I >> would be in a "within-subject design" since my sessions involve the 2 >> conditions every time ? >> >> I realise that it may be very confusing... I hope you will understand my >> problem ! >> >> And if anyone already applied fieldtrip functions to do statistics on a >> different framework that the usual EEG/MEG, please let me know ! >> >> Thanks a lot, >> >> Laetitia Lalla >> >> PhD Student in Neuroscience >> >> INMED, Marseille, France >> >> >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> URL: > >> >> ------------------------------ >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> >> End of fieldtrip Digest, Vol 65, Issue 7 >> **************************************** >> >> _______________________________________________ >> fieldtrip mailing list >> fieldtrip at donders.ru.nl >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >> >> >> >> -- >> >> Debora Desideri, PhD Student >> BNP Lab - Neurology Department >> University Hospital Tübingen >> Eberhard Karls University Tübingen >> Hoppe-Seyler Str. 3 >> D-72076 Tübingen >> Tel: +49 7071/29 80478 >> >> _______________________________________________ >> 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 > > > > -- > > Debora Desideri, PhD Student > BNP Lab - Neurology Department > University Hospital Tübingen > Eberhard Karls University Tübingen > Hoppe-Seyler Str. 3 > D-72076 Tübingen > Tel: +49 7071/29 80478 > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From deb.desideri at gmail.com Sun Apr 17 21:08:32 2016 From: deb.desideri at gmail.com (Debora Desideri) Date: Sun, 17 Apr 2016 21:08:32 +0200 Subject: [FieldTrip] Simbio works with ft_volumereslice but leadfield In-Reply-To: <24BC90ED-EEAA-4AAD-A0A3-0AB6E16E8108@googlemail.com> References: <1460557552027.85876@nin.knaw.nl> <82D66CB4-DE42-409C-B350-E5DA0984A07E@googlemail.com> <24BC90ED-EEAA-4AAD-A0A3-0AB6E16E8108@googlemail.com> Message-ID: Dear Johannes, yes, the calculation of the transfer matrix is actually the part that takes so long (ft_prepare_vol_sens). But as you point out, it is maybe just a not efficient matlab implementation... Best, Debora On Sun, Apr 17, 2016 at 3:34 PM, Johannes Vorwerk wrote: > Hi, > > could you check if it’s the calculation of the transfer matrix > (ft_prepare_vol_sens), which you can recoginze since the #electrode many > equations are solved, or the call of leadfield_simbio that takes up the > most time? > > It is normal that the matlab-code takes more time than the > SimBio-standalon binary, since it includes some loops. I’ve never > experienced such long computations as you did in my testings, so I didn’t > think about it very much so far. One might try to find a way to formulate > these parts without loops or use parallel loops at some points. > > Best, > Johannes > > Am 15.04.2016 um 01:55 schrieb Debora Desideri : > > Dear Johannes, > the time consuming part is when I call ft_prepare_leadfield. The I used > this precomputed leadfields for the computation of the dipole solution and > this is actually quite fast. > I started to use the FEM model only recently and I thought the long > lasting calculation was normal. Is there a way to have a faster > compuatation of leadfields? > > Best, > Debora > > > On Thu, Apr 14, 2016 at 11:28 PM, Johannes Vorwerk < > j.vorwerk at uni-muenster.de> wrote: > >> Hi Debora, >> >> could you indicate which part of the computation is the most time >> consuming, i.e., calculation of the transfer matrix or the subsequent >> computation of the dipole solutions? Principally, it should be possible to >> parallelize many of these steps, however, this wasn’t added to the >> checked-in code yet for reasons of stability/compatibility. >> >> Best, >> Johannes >> >> Am 14.04.2016 um 02:21 schrieb Debora Desideri : >> >> Dear Rajat, >> I am also using Simbio and I usually run the leadfield calculation >> overnight since it takes approximatelly 12-15 hours for 64 EEG channels >> with a grid of 6 mm resolution ( 2.60 GHz, 32 GB RAM). >> I don't know whether there is a way to speed the process up. Maybe we >> just need to be patient, or work on a very powerful machine. >> >> Best, >> Debora >> >> >> On Wed, Apr 13, 2016 at 4:25 PM, Rajat Thomas >> wrote: >> >>> Dear all, >>> >>> Last week I asked for help with Simbio and after following the >>> suggestion of volume reslicing magically the >>> simbio based headmodel was created. >>> >>> But my leadfield calculations are taking way too long. >>> It is a 128^3 grid and am running it on my desktop. (2.4 GHz, plenty of >>> memory 32GB) >>> >>> Could anyone give me a rough ball park on how long it should take to >>> create a leadfield? >>> >>> Thank you. >>> Rajat >>> >>> >>> >>> Rajat Mani Thomas >>> Social Brain Lab >>> Netherlands Institute for Neuroscience >>> Amsterdam >>> >>> ________________________________________ >>> From: fieldtrip-bounces at science.ru.nl >>> on behalf of fieldtrip-request at science.ru.nl < >>> fieldtrip-request at science.ru.nl> >>> Sent: 08 April 2016 12:00 >>> To: fieldtrip at science.ru.nl >>> Subject: fieldtrip Digest, Vol 65, Issue 7 >>> >>> Send fieldtrip mailing list submissions to >>> fieldtrip at science.ru.nl >>> >>> To subscribe or unsubscribe via the World Wide Web, visit >>> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >>> or, via email, send a message with subject or body 'help' to >>> fieldtrip-request at science.ru.nl >>> >>> You can reach the person managing the list at >>> fieldtrip-owner at science.ru.nl >>> >>> When replying, please edit your Subject line so it is more specific >>> than "Re: Contents of fieldtrip digest..." >>> >>> >>> Today's Topics: >>> >>> 1. Re: FEM using Simbio (Johannes Vorwerk) >>> 2. Re: FEM using Simbio (Cristiano Micheli) >>> 3. Dipole fitting (Giovanni Pellegrino) >>> 4. Birmingham-Illinois BRIDGE Fellowships (Ole Jensen) >>> 5. Using FieldTrip to analyse LFP recordings in rat >>> (laetitia.lalla at inserm.fr) >>> >>> >>> ---------------------------------------------------------------------- >>> >>> Message: 1 >>> Date: Thu, 7 Apr 2016 14:25:42 +0200 >>> From: Johannes Vorwerk >>> To: FieldTrip discussion list >>> Subject: Re: [FieldTrip] FEM using Simbio >>> Message-ID: <435735E3-7D87-4DD6-A2C1-E2BBFBBF4B44 at googlemail.com> >>> Content-Type: text/plain; charset="utf-8" >>> >>> Hi, >>> >>> this question was already answered in this thread >>> >>> http://mailman.science.ru.nl/pipermail/fieldtrip/2016-March/010274.html >>> >> > >>> >>> If ft_volumereslice is not applied before the mesh generation, the >>> afterwards applied transformation might flip the directions of the mesh, >>> leading to the described error. >>> >>> Best, >>> Johannes >>> >>> > Am 06.04.2016 um 16:03 schrieb Carsten Wolters < >>> carsten.wolters at uni-muenster.de>: >>> > >>> > Dear Rajat, >>> > >>> > the element-node cards of SimBio-NeuroFEM need to follow certain >>> orientations (see www.simbio.de ). >>> > >>> > If you do not want to struggle with meshing/ordering, use the >>> SimBio-VGRID mesher >>> > http://vgrid.simbio.de/ >>> > that follows the required ordering of nodes. You might use this mesher >>> to produce 1mm geometry-adapted FEM meshes >>> > that show good overall performance, see >>> > >>> http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf >>> < >>> http://www.sci.utah.edu/~wolters/PaperWolters/2007/WoltersEtAl_IEEE_TBME_2007.pdf >>> > >>> > and >>> > >>> http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf >>> < >>> http://www.sci.utah.edu/~wolters/PaperWolters/2016/WagnerLuckaVorwerkHerrmannNolteBurgerWolters_NeuroImage_2016.pdf >>> > >>> > (latter was just accepted by NeuroImage). >>> > >>> > Best regards >>> > Carsten >>> > >>> > Am 06.04.2016 um 15:10 schrieb Rajat Thomas: >>> >> Dear all, >>> >> >>> >> Has anyone used the FEM approach to Headmodels using Simbio recently? >>> >> >>> >> If so, I get this error: >>> >> "Elements have wrong orientation or are degenerated" >>> >> >>> >> Any ideas? >>> >> >>> >> cfg = []; >>> >> cfg.method ='simbio'; >>> >> cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows >>> mesh.tissyelabel >>> >> vol = ft_prepare_headmodel(cfg, mesh); >>> >> >>> >> And; >>> >> ? >>> >> disp(mesh) >>> >> hex: [545883x8 double] >>> >> pnt: [569722x3 double] >>> >> labels: [545883x1 double] >>> >> tissue: [545883x1 double] >>> >> tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >>> >> unit: 'mm' >>> >> cfg: [1x1 struct] >>> >> >>> >> Any help would be highly appreciated. >>> >> >>> >> Rajat >>> >> >>> >> >>> >> >>> >> >>> >> >>> >> >>> >> Rajat Mani Thomas >>> >> Social Brain Lab >>> >> Netherlands Institute for Neuroscience >>> >> Amsterdam >>> >> >>> >> >>> >> _______________________________________________ >>> >> fieldtrip mailing list >>> >> fieldtrip at donders.ru.nl >>> >> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip < >>> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip> >>> > _______________________________________________ >>> > fieldtrip mailing list >>> > fieldtrip at donders.ru.nl >>> > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip < >>> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip> >>> -------------- next part -------------- >>> An HTML attachment was scrubbed... >>> URL: < >>> http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160407/2ea995ee/attachment-0001.html >>> > >>> >>> ------------------------------ >>> >>> Message: 2 >>> Date: Thu, 7 Apr 2016 17:36:37 +0200 >>> From: Cristiano Micheli >>> To: FieldTrip discussion list >>> Subject: Re: [FieldTrip] FEM using Simbio >>> Message-ID: >>> < >>> CADW7XCAQONsZ_ujPhkffskZ+j-mnHnAzunS68CdKU6MLSosUPA at mail.gmail.com> >>> Content-Type: text/plain; charset="utf-8" >>> >>> Hi Rajat >>> >>> My guess is that the orientations of your hexahedrons are not correct. >>> According to a low-level file's internal rules, elements' orientations >>> have >>> to abide strict rules (not sure what exactly the contraints are in this >>> case though...). >>> I had same problems when for example the triangular boundaries used to >>> define the 3d hexahedral mesh were not topologically correct, to start >>> with. >>> Admittedly this approach requires a lot of technical expertise. >>> Can I ask you what do you need a FEM model for? >>> >>> Regards >>> Cris Micheli >>> >>> >>> >>> >>> On Wed, Apr 6, 2016 at 3:10 PM, Rajat Thomas >>> wrote: >>> >>> > Dear all, >>> > >>> > >>> > Has anyone used the FEM approach to Headmodels using Simbio recently? >>> > >>> > >>> > If so, I get this error: >>> > "Elements have wrong orientation or are degenerated" >>> > >>> > Any ideas? >>> > >>> > cfg = []; >>> > >>> > cfg.method ='simbio'; >>> > >>> > cfg.conductivity = [0.33 0.14 1.79 0.01 0.43]; % order follows >>> > mesh.tissyelabel >>> > >>> > vol = ft_prepare_headmodel(cfg, mesh); >>> > >>> > >>> > And; >>> > >>> > ? >>> > disp(mesh) >>> > hex: [545883x8 double] >>> > pnt: [569722x3 double] >>> > labels: [545883x1 double] >>> > tissue: [545883x1 double] >>> > tissuelabel: {'csf' 'gray' 'scalp' 'skull' 'white'} >>> > unit: 'mm' >>> > cfg: [1x1 struct] >>> > >>> > >>> > Any help would be highly appreciated. >>> > >>> > Rajat >>> > >>> > >>> > >>> > >>> > >>> > >>> > Rajat Mani Thomas >>> > Social Brain Lab >>> > Netherlands Institute for Neuroscience >>> > Amsterdam >>> > >>> > _______________________________________________ >>> > fieldtrip mailing list >>> > fieldtrip at donders.ru.nl >>> > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >>> > >>> -------------- next part -------------- >>> An HTML attachment was scrubbed... >>> URL: < >>> http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160407/4adfe55a/attachment-0001.html >>> > >>> >>> ------------------------------ >>> >>> Message: 3 >>> Date: Thu, 7 Apr 2016 15:02:05 -0400 >>> From: Giovanni Pellegrino >>> To: fieldtrip at science.ru.nl >>> Subject: [FieldTrip] Dipole fitting >>> Message-ID: >>> >> u8GDw at mail.gmail.com> >>> Content-Type: text/plain; charset="utf-8" >>> >>> Dear Fieldtrippers, >>> >>> Do you know if the FieldTrip Dipole Fitting has been compared to the CTF, >>> Elekta, BESA or Curry? Are you aware of any study on this topic? >>> >>> Thanks in advance for your help >>> >>> Giovanni >>> >>> -- >>> Giovanni Pellegrino, MD >>> Multimodal Functional Imaging Laboratory >>> Montreal Neurological Institute, McGill University >>> Address: 332 Duff Medical Building, 3775 rue University, Montreal, QC, >>> H3A >>> 2B4, Canada >>> Phone: (514) 398?1678 >>> Fax: (514) 398?7461 >>> Email: giovannipellegrino at gmail.com, giovanni.pellegrino2 at mcgill.ca >>> Homepage: http://www.bic.mni.mcgill.ca/ResearchLabsMFIL/PeopleGiovanni >>> -------------- next part -------------- >>> An HTML attachment was scrubbed... >>> URL: < >>> http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160407/d01144bd/attachment-0001.html >>> > >>> >>> ------------------------------ >>> >>> Message: 4 >>> Date: Fri, 8 Apr 2016 09:23:46 +0200 >>> From: Ole Jensen >>> To: fieldtrip at science.ru.nl >>> Subject: [FieldTrip] Birmingham-Illinois BRIDGE Fellowships >>> Message-ID: <57075C82.8030309 at donders.ru.nl> >>> Content-Type: text/plain; charset=utf-8; format=flowed >>> >>> Dear all, >>> >>> I would like to point you to a set of Birmingham-Illinois BRIDGE >>> Fellowships providing some exciting research and career prospects: >>> http://www.birminghamillinoisbridge.org/index.php/fellows/ >>> >>> In particular the areas 'Cognition and Ageing' and 'Brain Trauma' could >>> be relevant for candidates with EEG/MEG expertise. >>> >>> All the best, >>> >>> Ole >>> >>> -- >>> Prof. dr. Ole Jensen >>> http://www.neuosc.com >>> >>> >>> >>> ------------------------------ >>> >>> Message: 5 >>> Date: Fri, 08 Apr 2016 10:27:58 +0200 >>> From: laetitia.lalla at inserm.fr >>> To: fieldtrip at science.ru.nl >>> Subject: [FieldTrip] Using FieldTrip to analyse LFP recordings in rat >>> Message-ID: <628babdc107aebd4cc7588ea87ce5ea6 at inserm.fr> >>> Content-Type: text/plain; charset="utf-8" >>> >>> >>> >>> Hello everyone, >>> >>> my name is Laetitia and I'm a Phd student in Marseille (France). I'm >>> doing in-vivo recording in freely-moving rats : I implant them with 2 >>> electrodes deep into 2 different regions of the brain. I'm studying the >>> Local Field Potentials and I want to use FieldTrip to analyse the data. >>> >>> To simplify : >>> >>> - I have 2 rats. >>> >>> - Each rat did 20 sessions of the task (on 20 different days). >>> >>> - Each session consists of 20 trials of condition 1 and 20 trials of >>> condition 2. >>> >>> I have 2 questions. >>> >>> 1) I have the feeling it would be meaningless to do "source >>> reconstruction" because my electrodes are already deep inside my >>> "source" and the LFP I am recording is very local. (My electrodes have >>> 32 channels separated by 20-200 ?m. The LFP is very very similar across >>> all the channels, so I averaged over the 32 channels to have one signal >>> for each region.) >>> >>> However, I see that 2 different functions exist for the statistics : >>> FT_FREQSTATISTICS AND FT_SOURCESTATISTICS. So far, I've been using >>> ft_freqstatistics but I encounter some issues (for exemple, doing >>> monte-carlo permutation test to assess the imaginary coherence). I >>> thought of computing it manually, but I'm thinking that maybe more stuff >>> are implemented in ft_sourcestatisctics ? >>> >>> ? Are these 2 functions fundamentally different or do they call the same >>> sub-fonctions (and my problem has actually nothing to do with that) ? >>> >>> 2) I'm a bit confused with the vocabulary from EEG and MEG studies (I'm >>> not used to it yet...). From what I understood, in human studies, you >>> can do comparison for a single subject (across trials) or across >>> subjects. But I have 3 levels of comparisons in my design : >>> >>> - WITHIN A SESSION, I WANT TO COMPARE ACROSS TRIALS (the 20 trials of >>> condition 1 VS the 20 trials of condition 2). >>> >>> - WITHIN A RAT, I WANT TO COMPARE ACROSS SESSIONS (between the 2 >>> conditions) >>> >>> - then - in the very end - ACROSS RATS. But I have only 2 rats so far, >>> so I will deal with this later. >>> >>> I'm a bit confused when reading the tutorials and the mailing list, >>> especially when it comes to the statistics... For example : this is from >>> an email from 2013 by Eric Maris about "Nonparametric statistical >>> testing of phase coherence" >>> (http://mailman.science.ru.nl/pipermail/fieldtrip/2013-April/006401.html >>> ) >>> "To compare coherence between conditions across subjects (instead of >>> trials), you need a different statfun: depsamplesT (for a >>> within-subjects design; subjects have participated in all conditions) or >>> indepsamplesT (for a between-subjects design; subjects have participated >>> in only one condition)." >>> >>> ? If I want to compare across sessions (for a same rat), can I actually >>> consider that my different sessions are "subjects"? And then compare >>> coherence "across subjects" would be doing it "across sessions" ? And I >>> would be in a "within-subject design" since my sessions involve the 2 >>> conditions every time ? >>> >>> I realise that it may be very confusing... I hope you will understand my >>> problem ! >>> >>> And if anyone already applied fieldtrip functions to do statistics on a >>> different framework that the usual EEG/MEG, please let me know ! >>> >>> Thanks a lot, >>> >>> Laetitia Lalla >>> >>> PhD Student in Neuroscience >>> >>> INMED, Marseille, France >>> >>> >>> -------------- next part -------------- >>> An HTML attachment was scrubbed... >>> URL: < >>> http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160408/2aed96c1/attachment-0001.html >>> > >>> >>> ------------------------------ >>> >>> _______________________________________________ >>> fieldtrip mailing list >>> fieldtrip at donders.ru.nl >>> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >>> >>> End of fieldtrip Digest, Vol 65, Issue 7 >>> **************************************** >>> >>> _______________________________________________ >>> fieldtrip mailing list >>> fieldtrip at donders.ru.nl >>> http://mailman.science.ru.nl/mailman/listinfo/fieldtrip >>> >> >> >> >> -- >> >> Debora Desideri, PhD Student >> BNP Lab - Neurology Department >> University Hospital Tübingen >> Eberhard Karls University Tübingen >> Hoppe-Seyler Str. 3 >> D-72076 Tübingen >> Tel: +49 7071/29 80478 >> >> _______________________________________________ >> 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 >> > > > > -- > > Debora Desideri, PhD Student > BNP Lab - Neurology Department > University Hospital Tübingen > Eberhard Karls University Tübingen > Hoppe-Seyler Str. 3 > D-72076 Tübingen > Tel: +49 7071/29 80478 > > _______________________________________________ > 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 > -- Debora Desideri, PhD Student BNP Lab - Neurology Department University Hospital Tübingen Eberhard Karls University Tübingen Hoppe-Seyler Str. 3 D-72076 Tübingen Tel: +49 7071/29 80478 -------------- next part -------------- An HTML attachment was scrubbed... URL: From icelandhouse at gmail.com Mon Apr 18 10:45:33 2016 From: icelandhouse at gmail.com (Maris Skujevskis) Date: Mon, 18 Apr 2016 10:45:33 +0200 Subject: [FieldTrip] fieldtrip Digest, Vol 65, Issue 14 In-Reply-To: References: Message-ID: Dear Fieldtrip users, When constructing an EEG forward model, the function ft_prepare_sourcemodel has an option cfg.inwardshift. When plotting the grid of the source model over the brain volume, I get the following differences between a negative and a zero inwardshift (skull and scalp layers not shown): https://drive.google.com/file/d/0B9QSyDy3RhMIUkdxaHBPV2FtODg/view?usp=sharing >From this I conclude that a negative inward shift means that grid points that in reality are outside the brain get treated as inside the brain in the source model. Based on this observation, I have two questions: a) why could a shift be necessary? -- naively, it doesn't make sense that a grid point needs to be labeled as being in the brain when it actually is outside. b) how can a shift be justified? -- it seems that the outer grid points that get labeled as 'inside' due to the shift would have incorrect conductivity values when the leadfield matrix is calculated. This would be the case because in the volume conduction model the coordinates of those points correspond to the skull and not to the brain tissue. Any explanations/corrections of the above outline of what cfg.inwardshift does will be highly appreciated, Maris. On Sat, Apr 16, 2016 at 12:00 PM, wrote: > Send fieldtrip mailing list submissions to > fieldtrip at science.ru.nl > > To subscribe or unsubscribe via the World Wide Web, visit > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > or, via email, send a message with subject or body 'help' to > fieldtrip-request at science.ru.nl > > You can reach the person managing the list at > fieldtrip-owner at science.ru.nl > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of fieldtrip digest..." > > > Today's Topics: > > 1. Re: TFR mask stats question; Baselined vs unbaselined > statistics question (Max Cantor) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Fri, 15 Apr 2016 13:48:38 -0600 > From: Max Cantor > To: FieldTrip discussion list > Subject: Re: [FieldTrip] TFR mask stats question; Baselined vs > unbaselined statistics question > Message-ID: > < > CAOv1Hy1VumqCGBuzCpTOo7KPLDfTPXMGMoWVrhzbO2+cvqjRdQ at mail.gmail.com> > Content-Type: text/plain; charset="utf-8" > > As a followup, I'd like to note that there was a mistake in the multiplot > code in my prior post (I had in that code 1,3,5 instead of 1,2,3 as my > indices for the stat cell array), and the comment for zlim was not relevant > (that was for when I was plotting powspctrm, since the data were > freqbaselined). > > Since the time I posted this, I've tried a few more things that have been > somewhat successful. I have set frequency to [1 30], because gamma seemed > to be very noisy and the data were bandpass filtered at [0.1 50]hz in the > first place so I figured there would be no meaningful effect as high as > 50hz. I have also played with the latency, testing a priori assumptions of > the time window, as well as a general [0 1.8] window for TFR (and [0 1] > window for ERP). > > Finally, I have tried the analyses using the nonparametric permutation > test, but without the cluster correction (and setting cfg.alpha to 0.05 as > opposed to 0.025, for the cluster statistics). When I do just the > permutation test, I get the effects that I was anticipating in both ERP and > TFR. It's only when I add in the cluster correction that I get no > significant effects. > > Does anyone have an idea as to why this might be happening? > > Best, > > Max > > On Fri, Apr 8, 2016 at 3:02 PM, Max Cantor > wrote: > > > Hi fieldtrippers, > > > > I have two unrelated stats questions, but I figured I'd post them > together: > > > > 1. I've run within subjects permutation statistics testing the difference > > between an anomaly and control condition for three different language > > conditions; preposition, morphosyntax, and semantics. The code is nearly > > identical for both my ERPs and TFRs, except that when I plot my ERPs with > > cfg.maskparameter = 'mask', cfg.parameter = 'stat', and cfg.maskalpha = > > 0.025, it seems to multiplot just fine, whereas when I try to do the same > > for the TFRs, my multiplotted plots are blank, but when I comment out the > > mask, the stat plots are fine. I'll attach the code, but is there > something > > I'm doing obviously wrong? Also, am I correct that my maskalpha should > > correspond to my alpha, and not my cluster alpha? > > > > This is the TFR code, but the ERP code is the exact same except for with > > timelocked data as the input and ft_timelockstatistics as the function. > > > > cfg = []; > > cfg.method = 'montecarlo'; > > cfg.statistic = 'depsamplesT'; > > cfg.correctm = 'cluster'; > > cfg.clusteralpha = 0.05; > > cfg.clusterstatistic = 'maxsum'; > > cfg.minnbchan = 2; > > cfg.neighbours = neighbours; > > cfg.tail = 0; > > cfg.clustertail = 0; > > cfg.alpha = 0.025; > > cfg.numrandomization = 1000; > > > > nsubj = length(tot_tfr2_bl{1}); > > design = zeros(2,2*nsubj); > > for i = 1:nsubj > > design(1,i) = i; > > end > > for i = 1:nsubj > > design(1,nsubj+i) = i; > > end > > design(2,1:nsubj) = 1; > > design(2,nsubj+1:2*nsubj) = 2; > > > > cfg.design = design; > > cfg.uvar = 1; > > cfg.ivar = 2; > > > > % Anomaly vs Control > > stat_tfr{1} = ft_freqstatistics(cfg, tot_tfr2_bl{1}{:}, > > tot_tfr2_bl{2}{:}); % Preposition > > stat_tfr{2} = ft_freqstatistics(cfg, tot_tfr2_bl{3}{:}, > > tot_tfr2_bl{4}{:}); % Semantics > > stat_tfr{3} = ft_freqstatistics(cfg, tot_tfr2_bl{5}{:}, > > tot_tfr2_bl{6}{:}); % Morphosyntax > > > > This is the plotting code. Again, it is virtually the same for the ERPs > > except the non-stats configurations would be what makes sense for ERPs. > > > > % Anomaly vs Control TFR stats multiplot > > > > cfg = []; > > cfg.xlim = [-0.2 1]; > > cfg.zlim = [-3 3]; % proportion from baseline > > cfg.layout = [max_dir '/quickcap64.mat']; > > cfg.maskparameter = 'mask'; > > cfg.parameter = 'stat'; > > cfg.maskalpha = 0.025; > > > > ft_multiplotTFR(cfg, stat_tfr{1}); title('Preposition'); > > ft_multiplotTFR(cfg, stat_tfr{3}); title('Semantic'); > > ft_multiplotTFR(cfg, stat_tfr{5}); title('Morphosyntactic'); > > > > > > 2. The second question is about analyzing baselined vs unbaselined data. > > I've seen in the tutorials that there is a somewhat different method for > > analyzing trial vs baseline period. However, what I've done instead (for > > both ERP and TFR), is use the same within-subjects statistics as with > > anomaly vs control, except with the inputs being baselined vs unbaselined > > ERPs or TFRs, e.g. Baselined Preposition Anomaly vs Unbaselined > Preposition > > Anomaly, etc. I understand that the proposed method and my method are not > > testing the same thing exactly, but is this a reasonable way of testing > the > > effect of the baselining anyway? > > > > Thanks, > > > > Max > > > > -- > > Max Cantor > > Graduate Student > > Cognitive Neuroscience of Language Lab > > University of Colorado Boulder > > > > > > -- > Max Cantor > Graduate Student > Cognitive Neuroscience of Language Lab > University of Colorado Boulder > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: < > http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20160415/4cd234cd/attachment-0001.html > > > > ------------------------------ > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > > End of fieldtrip Digest, Vol 65, Issue 14 > ***************************************** > -------------- next part -------------- An HTML attachment was scrubbed... URL: From seymourr at aston.ac.uk Mon Apr 18 11:13:29 2016 From: seymourr at aston.ac.uk (Seymour, Robert (Research Student)) Date: Mon, 18 Apr 2016 09:13:29 +0000 Subject: [FieldTrip] Recombining Trials for Source Analysis Message-ID: Dear Fieldtrippers, I am trying to use an LCMV beamformer to project 5 minutes of resting state data to the source level. During my data cleaning procedure I segment my continuous recording into 1 second "trials" and reject those with high amplitudes (using the ft_rejectvisual summary window). However I would then like to recombine these "trials" (to make 1 long "trial") before I do ft_timelockanalysis. Is there a way to do this whilst keeping the Fieldtrip structure intact . My current code is below: % Segment into 1s chunks. Input is preprocessed variable called data. cfg = []; cfg.length = 1; cfg.overlap = 0; data_segmented = ft_redefinetrial(cfg,data); % Reject deviant trials cfg = []; cfg.method = 'summary'; cfg.keepchannel = 'yes'; cfg.channel = 'MEGMAG'; clean1 = ft_rejectvisual(cfg,data_segmented); % Now load this cfg.channel = 'MEGGRAD'; clean2 = ft_rejectvisual(cfg,clean1); data_clean_rs = clean2 clear clean1 clean2 save data_clean_rs data_clean_rs % Now to recombine trials data_clean_rs.trial = horzcat(data_clean_rs.trial{1,:}); % (This distorts the fieldtrip structure meaning ft_timelockanalysis doesn't work) Many thanks, Robert -------------- next part -------------- An HTML attachment was scrubbed... URL: From magazzinil at gmail.com Mon Apr 18 11:24:48 2016 From: magazzinil at gmail.com (Lorenzo Magazzini) Date: Mon, 18 Apr 2016 10:24:48 +0100 Subject: [FieldTrip] Recombining Trials for Source Analysis In-Reply-To: References: Message-ID: Hi Robert, I'm not sure, but my guess would be that you need to adjust the .time field in your data_clean_rs structure, so that it matches the length of the .trial field. Best wishes, Lorenzo Lorenzo Magazzini PhD Student magazzinil at cardiff.ac.uk CUBRIC Building Maindy Road Cardiff CF24 4HQ On 18 April 2016 at 10:13, Seymour, Robert (Research Student) < seymourr at aston.ac.uk> wrote: > Dear Fieldtrippers, > > > I am trying to use an LCMV beamformer to project 5 minutes of resting > state data to the source level. During my data cleaning procedure I segment > my continuous recording into 1 second "trials" and reject those with high > amplitudes (using the ft_rejectvisual summary window). However I would then > like to recombine these "trials" (to make 1 long "trial") before I do > ft_timelockanalysis. Is there a way to do this whilst keeping the Fieldtrip > structure intact . My current code is below: > > > % Segment into 1s chunks. Input is preprocessed variable called data. > > cfg = []; > > cfg.length = 1; > > cfg.overlap = 0; > > data_segmented = ft_redefinetrial(cfg,data); > > > % Reject deviant trials > > cfg = []; > > cfg.method = 'summary'; > > cfg.keepchannel = 'yes'; > > cfg.channel = 'MEGMAG'; > > clean1 = ft_rejectvisual(cfg,data_segmented); > > % Now load this > > cfg.channel = 'MEGGRAD'; > > clean2 = ft_rejectvisual(cfg,clean1); > > data_clean_rs = clean2 > > > clear clean1 clean2 > > save data_clean_rs data_clean_rs > > > % Now to recombine trials > > data_clean_rs.trial = horzcat(data_clean_rs.trial{1,:}); % (This distorts > the fieldtrip structure meaning ft_timelockanalysis doesn't work) > > > > Many thanks, > > > Robert > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From mi_mayer at gmx.de Tue Apr 19 20:07:09 2016 From: mi_mayer at gmx.de (Irene Sophia Mayer) Date: Tue, 19 Apr 2016 20:07:09 +0200 Subject: [FieldTrip] ft_channelrepair: index exceeds matrix dimensions Message-ID: An HTML attachment was scrubbed... URL: From XDu at mprc.umaryland.edu Tue Apr 19 20:38:10 2016 From: XDu at mprc.umaryland.edu (Xiaoming Du) Date: Tue, 19 Apr 2016 14:38:10 -0400 Subject: [FieldTrip] ft_channelrepair: index exceeds matrix dimensions In-Reply-To: References: Message-ID: <571642D3020000DC0001A139@MPRC.UMARYLAND.EDU> Hello, I am not a fieldtrip expert, but I happen to use ft_channelrepair recently. In you code, does the 'data' have FT9 or CP6? Are those electrodes missing or bad? If you construct neighbours based on less number of electrodes, you may still lack the neighbour-info to interpolate them. I suggest to check the dimension of neighbours and see if it contains the neighbours info for all electrodes (especially for FT9 and CP6). Also, you can try cfg.missingchannel instead of cfg.badchannel and see if that helps. p.s., in my case, I used a good data (meaning without missing or bad channels) to create the neighbours and use it for all others dataset with same type of EEG caps. Best, Xiaoming >>> "Irene Sophia Mayer" 4/19/2016 2:07 PM >>> Dear fieldtrippers, When trying to repair bad channels, I get the following error message: Index exceeds matrix dimensions. Error in ft_channelrepair (line 177) goodsensindx = a(b); Error in prepro_neu (line 129) data = ft_channelrepair(cfg,data); This seems to happen for specific channels, e.g. 'FT9' and 'CP6', but the script works fine, if I don't try to interpolate those channels. Any ideas what the problem could be? My code: cfg = []; cfg.method = 'template'; cfg.layout = 'EEG1010.lay'; cfg.feedback = 'yes'; neighbours = ft_prepare_neighbours(cfg,data); cfg = []; cfg.method = 'average'; % 'nearest', 'average', 'spline' or 'slap' (default='nearest') cfg.badchannel = bad_chan{x}; % predefined list of channels cfg.elec = ft_read_sens('path'); cfg.neighbours = neighbours; cfg.trials = 'all'; cfg.lambda = 1e-5; cfg.order = 4; data = ft_channelrepair(cfg,data); -------------- next part -------------- An HTML attachment was scrubbed... URL: From anne.urai at gmail.com Wed Apr 20 08:19:44 2016 From: anne.urai at gmail.com (Anne Urai) Date: Wed, 20 Apr 2016 08:19:44 +0200 Subject: [FieldTrip] ft_megrealign - complete CTF275 grad struct wanted Message-ID: Dear Fieldtrippers, tl;dr 1. I'm looking for a gradiometer structure that includes coils (so a subject or dummy measurement) with *all* squids present.  2. Can I rename the CTF HLC0011 etc... to {'nasX';'nasY';'nasZ';'lpaX';'lpaY';'lpaZ';'rpaX';'rpaY';'rpaZ'}? --------- 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.  After making the headmodel (and ensuring it's aligned with the gradiometers), this works quite well: % realign to template sensor positions cfg             = []; cfg.template    = {'ctf275.mat'};  cfg.headmodel   = headmodel;   % For a realistic single-shell volume conduction model based on the brain surface, you % should probably use an inward shift of about 1 cm. cfg.inwardshift  = 1; cfg.feedback     = 'no'; data2            = ft_megrealign(cfg, data); 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 ftp://ftp.fieldtriptoolbox.org/pub/fieldtrip/example/megrealign, 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. 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. 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.  In ft_headmovement (and also buried somewhere in the CTF documentation), I could find % HLC0011 HLC0012 HLC0013 x, y, z coordinates of nasion-coil in m. % HLC0021 HLC0022 HLC0023 x, y, z coordinates of lpa-coil in m. % HLC0031 HLC0032 HLC0033 x, y, z coordinates of rpa-coil in m. 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.  Thanks! —  Anne E. Urai, MSc PhD student | Institut für Neurophysiologie und Pathophysiologie  Universitätsklinikum Hamburg-Eppendorf | Martinistrasse 52, 20246 | Hamburg, Germany  www.anneurai.net / @AnneEUrai -------------- next part -------------- An HTML attachment was scrubbed... URL: From mi_mayer at gmx.de Wed Apr 20 09:07:15 2016 From: mi_mayer at gmx.de (Irene Sophia Mayer) Date: Wed, 20 Apr 2016 09:07:15 +0200 Subject: [FieldTrip] ft_channelrepair: index exceeds matrix dimensions In-Reply-To: <571642D3020000DC0001A139@MPRC.UMARYLAND.EDU> References: , <571642D3020000DC0001A139@MPRC.UMARYLAND.EDU> Message-ID: An HTML attachment was scrubbed... URL: From XDu at mprc.umaryland.edu Wed Apr 20 11:19:23 2016 From: XDu at mprc.umaryland.edu (Xiaoming Du) Date: Wed, 20 Apr 2016 05:19:23 -0400 Subject: [FieldTrip] ft_channelrepair: index exceeds matrix dimensions In-Reply-To: References: , <571642D3020000DC0001A139@MPRC.UMARYLAND.EDU> Message-ID: <5717115B020000DC0001A158@MPRC.UMARYLAND.EDU> Hi Irene, Here is the code I used: cfg = []; cfg.method = 'triangulation' cfg.senstype = 'EEG' neighbours_66 = ft_prepare_neighbours(cfg, data_intact); cfg = []; cfg.method = 'average'; cfg.neighbours = neighbours_66; cfg.missingchannel = missingChann; cfg.senstype = 'EEG'; data_clean = ft_channelrepair(cfg, data); Here is an example from Fieldtrip website http://www.fieldtriptoolbox.org/tutorial/natmeg/timefrequency?s[]=ft&s[]=channelrepair Regards, Xiaoming >>> "Irene Sophia Mayer" 4/20/2016 3:07 AM >>> Hello, The data does always have those channels, they are bad and not missing. All electrodes have neighbours assigned to them and I'm doing this on the original data without having changed anything before that. Did you use the same code as I did? Best, Irene Gesendet: Dienstag, 19. April 2016 um 20:38 Uhr Von: "Xiaoming Du" An: fieldtrip at science.ru.nl Betreff: Re: [FieldTrip] ft_channelrepair: index exceeds matrix dimensions Hello, I am not a fieldtrip expert, but I happen to use ft_channelrepair recently. In you code, does the 'data' have FT9 or CP6? Are those electrodes missing or bad? If you construct neighbours based on less number of electrodes, you may still lack the neighbour-info to interpolate them. I suggest to check the dimension of neighbours and see if it contains the neighbours info for all electrodes (especially for FT9 and CP6). Also, you can try cfg.missingchannel instead of cfg.badchannel and see if that helps. p.s., in my case, I used a good data (meaning without missing or bad channels) to create the neighbours and use it for all others dataset with same type of EEG caps. Best, Xiaoming >>> "Irene Sophia Mayer" 4/19/2016 2:07 PM >>> Dear fieldtrippers, When trying to repair bad channels, I get the following error message: Index exceeds matrix dimensions. Error in ft_channelrepair (line 177) goodsensindx = a(b); Error in prepro_neu (line 129) data = ft_channelrepair(cfg,data); This seems to happen for specific channels, e.g. 'FT9' and 'CP6', but the script works fine, if I don't try to interpolate those channels. Any ideas what the problem could be? My code: cfg = []; cfg.method = 'template'; cfg.layout = 'EEG1010.lay'; cfg.feedback = 'yes'; neighbours = ft_prepare_neighbours(cfg,data); cfg = []; cfg.method = 'average'; % 'nearest', 'average', 'spline' or 'slap' (default='nearest') cfg.badchannel = bad_chan{x}; % predefined list of channels cfg.elec = ft_read_sens('path'); cfg.neighbours = neighbours; cfg.trials = 'all'; cfg.lambda = 1e-5; cfg.order = 4; data = ft_channelrepair(cfg,data); _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From elmeri.syrjanen at gmail.com Wed Apr 20 14:05:20 2016 From: elmeri.syrjanen at gmail.com (=?UTF-8?Q?Elmeri_Syrj=C3=A4nen?=) Date: Wed, 20 Apr 2016 14:05:20 +0200 Subject: [FieldTrip] Plotting combining figures Message-ID: Dear all, I'am trying to build a figure in Matlab composed of multiple elements. For example I would like to have a upper part of the figure with mean amplitudes and CIs. The lower part of the figure would be composed of the output from ft_singleplotER and ft_clusterplot. Is this possible? So far i tried various combinations of the set(), hold and subplot() commands in Matlab. I suspect that the problem arises from that FieldTrip creates a new figure each time one of the plotting functions are called. Is there a handle to the figure that is created? It would be great if this would be possible. The advantage is obvious if it's possible to build the complete figure in Matlab with consistent font sizes etc. /elmeri -------------- next part -------------- An HTML attachment was scrubbed... URL: From fosco.bernasconi at gmail.com Wed Apr 20 14:53:32 2016 From: fosco.bernasconi at gmail.com (fosco bernasconi) Date: Wed, 20 Apr 2016 14:53:32 +0200 Subject: [FieldTrip] ft_sourceplot NaN, connectivity degree Message-ID: Dear list, I am trig to plot the connectivity degree of my beamforming sources, after interpolation. What happens, is that also the NaN values outside the headmodel are plotted (see figure below). Is there an easy fix for this? or did I do some errors in my computation? My code: cfg = []; cfg.method = 'ortho'; cfg.funparameter = 'degrees'; cfg.maskparameter = 'mask'; cfg.funcolormap = 'jet'; cfg.location = 'max'; ft_sourceplot(cfg,source_degint_S); and my data structure: source_degint_S = anatomy: [91x109x91 double] coordsys: 'spm' dim: [91 109 91] transform: [4x4 double] unit: 'mm' inside: [91x109x91 logical] degrees: [91x109x91 double] cfg: [1x1 struct] Thanks a lot in advance! fosco [image: Immagine incorporata 2] -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: Screenshot from 2016-04-20 13:38:28.png Type: image/png Size: 74696 bytes Desc: not available URL: From icelandhouse at gmail.com Wed Apr 20 17:11:24 2016 From: icelandhouse at gmail.com (Maris Skujevskis) Date: Wed, 20 Apr 2016 17:11:24 +0200 Subject: [FieldTrip] why are grid points located outside the brain? Message-ID: Dear Fieldtrip users, Can someone please explain the reason why in the tutorial http://www.fieldtriptoolbox.org/tutorial/sourcemodel (or in general, for that matter) the outer layer of grid points of the source model lie outside the brain though they are defined as being inside? This is what I am refering to: http://www.fieldtriptoolbox.org/_detail/example/mnispace/mni_fig1a.png?id=tutorial%3Asourcemodel http://www.fieldtriptoolbox.org/_detail/example/mnispace/mni_fig2b.png?id=tutorial%3Asourcemodel According to my naive understanding, this means that in this model the potential neural sources may also lie outside the brain, which makes no sense. Clearly, I am missing something here... Thanks! Maris -------------- next part -------------- An HTML attachment was scrubbed... URL: From nicholas.balderston at nih.gov Wed Apr 20 23:27:00 2016 From: nicholas.balderston at nih.gov (Balderston, Nicholas (NIH/NIMH) [F]) Date: Wed, 20 Apr 2016 21:27:00 +0000 Subject: [FieldTrip] why are grid points located outside the brain? In-Reply-To: References: Message-ID: Dear all, Thanks for the question Maris, I have been wondering the same. Along those lines, I was wondering if it is appropriate to scale the resulting beamformer grids to match the size of the MNI template after the fact? thanks, -nick ________________________________ From: Maris Skujevskis [icelandhouse at gmail.com] Sent: Wednesday, April 20, 2016 11:11 AM To: fieldtrip at science.ru.nl Subject: [FieldTrip] why are grid points located outside the brain? Dear Fieldtrip users, Can someone please explain the reason why in the tutorial http://www.fieldtriptoolbox.org/tutorial/sourcemodel (or in general, for that matter) the outer layer of grid points of the source model lie outside the brain though they are defined as being inside? This is what I am refering to: http://www.fieldtriptoolbox.org/_detail/example/mnispace/mni_fig1a.png?id=tutorial%3Asourcemodel http://www.fieldtriptoolbox.org/_detail/example/mnispace/mni_fig2b.png?id=tutorial%3Asourcemodel According to my naive understanding, this means that in this model the potential neural sources may also lie outside the brain, which makes no sense. Clearly, I am missing something here... Thanks! Maris -------------- next part -------------- An HTML attachment was scrubbed... URL: From muthuraman10 at hotmail.com Fri Apr 22 14:19:33 2016 From: muthuraman10 at hotmail.com (Muthuraman Muthuraman) Date: Fri, 22 Apr 2016 12:19:33 +0000 Subject: [FieldTrip] PhD Position on Brian Imaging in Multiple Sclerosis! Message-ID: Doctoral Student Neuroscientist with focus on brain imaging in multiple sclerosis diagnosis The medical faculty of the University of Mainz, Germany, invites applications for a PhD Student for a functional translational neuroscience (FTN) scholarship three year position to work on the Multiple sclerosis imaging with modalities like structural MRI, diffusion tensor imaging, functional magnetic resonance imaging and Electro encephalography (EEG). The successful applicant holds a Master’s degree (or equivalent) in a relevant academic area such as basic life sciences, neuropsychology, applied mathematics, computer science or biomedical engineering or similar disciplines. The working language at the institute is English. Experience with brain imaging and the analysis of brain signals is advantageous, but not essential. The applicant’s merits are assessed on the basis of the quality of Master’s level studies and thesis, previous experience with the brain imaging, motivation and research interests. The location for this research will mainly be the workgroups “Section of movement disorders, neurostimulation and neuroimaging“ of Prof. Sergiu Groppa at the Department of Neurology and “Multimodal signal processing and statistical analyses” of Prof. Muthuraman Muthuraman, both at the Focus Program Translational Neurosciences (http://www.ftn.uni-mainz.de/) and Neuroimaging Centre Mainz (http://www.ftn.nic.uni-mainz.de/). Expected close collaborations with national and international partners. The application should include a statement of research interests and reasons for applying to the project, a curriculum vitae (max. 4 pages) composed according to good scientific practice, a certificate of Master’s degree, copy of the master’s thesis and grades of Master’s level studies, the names and e-mail addresses of two referees and a proof of proficiency in English. The position will be open until filled. To apply for the position, please send the above documents as pdfs until 15.05.2016 to Prof. Sergiu Groppa, Department of Neurology, Section of movement disorders and neurostimulation, University of Mainz, Langenbeckstrasse 1, 55131 Mainz, Germany, or by Email to segroppa(at)uni-mainz.de. For additional information please contact Sergiu Groppa. -------------- next part -------------- An HTML attachment was scrubbed... URL: From 9605 at eng.asu.edu.eg Fri Apr 22 16:52:36 2016 From: 9605 at eng.asu.edu.eg (Mina Romany Meshriky) Date: Fri, 22 Apr 2016 14:52:36 +0000 Subject: [FieldTrip] FW: From a .csv data file, to a recognized dataset by fieldtrip In-Reply-To: <006c01d19ca6$65683f50$3038bdf0$@gmail.com> References: <006c01d19ca6$65683f50$3038bdf0$@gmail.com> Message-ID: Dears, My name is Mina, and I am working with event related potentials. I think my question is somehow basic but, it's been a day and I am still stuck. I am working with the Emotiv Epoc device, and I am using Labview and Matlab for real time acquisition and processing. Until recently I was using my own functions to read and process the data, however now I would like to use the fieldtrip toolbox. When I receive data from the device using Labview I store it directly to a .csv file and then start the processing on Matlab I would like to change this .csv file to a format recognized by field trip What I have separately now is 1- The data 2- The channel names 3- The channel locations 4- The markers 5- The sampling frequency Best Regards Mina Meshriky -------------- next part -------------- An HTML attachment was scrubbed... URL: From WILLIAM.DEWISPELAERE at UCDENVER.EDU Fri Apr 22 18:27:11 2016 From: WILLIAM.DEWISPELAERE at UCDENVER.EDU (Dewispelaere, William B) Date: Fri, 22 Apr 2016 16:27:11 +0000 Subject: [FieldTrip] ft_sourceinterpolate and ft_sourcestatistics outputs Message-ID: Hey all, I have a few questions about the output that results from ft_sourceinterpolate and ft_sourcestatistics. For some background, I ran ft_sourcestatistics on un-interpolated data in order to save some memory space. I then interpolated this stat output onto my realigned and resliced anatomical MRI. Everything looks alright, I just want to know: 1) Positive vs negative clusters - I'm assuming positive clusters are where condition 1 (as defined in the design matrix) is greater than condition 2 (I only have 2 conditions). Correct me if I'm wrong! 2) The 'prob' field - Before I interpolate my ft_sourcestatistics output, the 'prob' field contains the p-values for each voxel. After interpolation, I'm not sure what the 'prob' field is, since the values range from above 1 to below -1. If someone could clarify the meaning of these values, that would make my day. Thanks! Will -------------- next part -------------- An HTML attachment was scrubbed... URL: From laxmi.shaw22 at gmail.com Fri Apr 22 19:05:40 2016 From: laxmi.shaw22 at gmail.com (Laxmi Shaw) Date: Fri, 22 Apr 2016 22:35:40 +0530 Subject: [FieldTrip] Fieldtrip_issues Message-ID: Dear list, I am having an situation . I am having data in excels file which i have converted to.mat file. The file content as each columns indicates number of channels and the data points are indicates the corresponding amplitude. I want to use ft_topoplotER and ft_clusterplot,for that i need to convert .mat to structure file . How can i use topoplot in that way. Could you please help me in this regard. Thanks and Regards -- Laxmi Shaw Research Scholar(PhD) IIT Kharagpur West Bengal Ph no-08388837821 -------------- next part -------------- An HTML attachment was scrubbed... URL: From dlozanosoldevilla at gmail.com Fri Apr 22 19:27:38 2016 From: dlozanosoldevilla at gmail.com (Diego Lozano-Soldevilla) Date: Fri, 22 Apr 2016 19:27:38 +0200 Subject: [FieldTrip] Fieldtrip_issues In-Reply-To: References: Message-ID: Dear Laxmi, These two pages should definitely help you: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat http://www.fieldtriptoolbox.org/getting_started best, Diego On 22 April 2016 at 19:05, Laxmi Shaw wrote: > Dear list, > I am having an situation . I am having data in excels file which i have > converted to.mat file. The file content as each columns indicates number of > channels and the data points are indicates the corresponding amplitude. I > want to use ft_topoplotER and ft_clusterplot,for that i need to convert > .mat to structure file . How can i use topoplot in that way. Could you > please help me in this regard. > > > > > Thanks and Regards > > -- > Laxmi Shaw > Research Scholar(PhD) > IIT Kharagpur > West Bengal > Ph no-08388837821 > > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip > -------------- next part -------------- An HTML attachment was scrubbed... URL: From gaur-p at email.ulster.ac.uk Fri Apr 22 19:34:09 2016 From: gaur-p at email.ulster.ac.uk (Pramod Gaur) Date: Fri, 22 Apr 2016 18:34:09 +0100 Subject: [FieldTrip] Fieldtrip_issues In-Reply-To: References: Message-ID: <2099a01d19cbd$2f7b3250$8e7196f0$@email.ulster.ac.uk> Dear Users, I am newbie to fieldtrip and just wanted to analyse BCI competition IV datasets. I have seen many format are mentioned but nothing is given for GDF format. Could you please help me and point me to the correct link, so I can start working on EEG data. Best regards, Pramod From: fieldtrip-bounces at science.ru.nl [mailto:fieldtrip-bounces at science.ru.nl] On Behalf Of Diego Lozano-Soldevilla Sent: 22 April 2016 18:28 To: FieldTrip discussion list Subject: Re: [FieldTrip] Fieldtrip_issues Dear Laxmi, These two pages should definitely help you: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat http://www.fieldtriptoolbox.org/getting_started best, Diego On 22 April 2016 at 19:05, Laxmi Shaw > wrote: Dear list, I am having an situation . I am having data in excels file which i have converted to.mat file. The file content as each columns indicates number of channels and the data points are indicates the corresponding amplitude. I want to use ft_topoplotER and ft_clusterplot,for that i need to convert .mat to structure file . How can i use topoplot in that way. Could you please help me in this regard. Thanks and Regards -- Laxmi Shaw Research Scholar(PhD) IIT Kharagpur West Bengal Ph no-08388837821 _______________________________________________ fieldtrip mailing list fieldtrip at donders.ru.nl http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -------------- next part -------------- An HTML attachment was scrubbed... URL: From sauer.mpih at googlemail.com Sun Apr 24 18:36:06 2016 From: sauer.mpih at googlemail.com (Andreas Sauer) Date: Sun, 24 Apr 2016 18:36:06 +0200 Subject: [FieldTrip] Why does ft_selectdata remove "pow" from sourcedata during statistics? Message-ID: Dear all, unfortunately, I am having problems to run source statistics on ERF mismatch negativity data (recorded with a 4D system). With the following data structure as input (output from ft_sourcegrandaverage), fieldtrip gives a warning that it „could not determine dimord of „pow“ in the following data“ pow: [16x37696 double] dim: [31 38 32] inside: [37696x1 logical] pos: [37696x3 double] time: [1x900 double] cfg: [1x1 struct] and later throws an error that „field „pow“ (is) not present in data“. I checked the ft_sourcestatistic script step by step and found out that ft_selectdata removes it after being called by ft_sourcestatistics. I am using the fieldtrip version from 15/05/2015. I also tried with older versions, one from late 2014 and late 2013, but nothing worked. Unfortunately, since ft_selectdata removes the field "pow" from the data during the call to ft_sourcestatistic, I can’t put it back in to the structure. Any help with this (esp. why „pow“ is being removed) is highly appreciated! Thanks and best wishes, Andreas -- Dipl.-Psych. Andreas Sauer Max Planck Institute for Brain Research Deutschordenstraße 46 60528 Frankfurt am Main Germany T: +49 69 96769 278 F: +49 69 96769 327 Email: sauer.mpih at gmail.com www.brain.mpg.de -------------- next part -------------- An HTML attachment was scrubbed... URL: From pantev at uni-muenster.de Mon Apr 25 11:18:51 2016 From: pantev at uni-muenster.de (Christo Pantev) Date: Mon, 25 Apr 2016 11:18:51 +0200 Subject: [FieldTrip] Full Professor (W3 Position) for Biomagnetism and Biosignalanalysis with focus on Magnetoencephalography and Multimodal Imaging of Neural Systems Message-ID: Dear colleagues, The Medical Faculty of the University of Münster offers the position of a Full Professor (W3) for "Biomagnetism and Biosignalanalysis with focus on Magnetoencephalography and Multimodal Imaging of Neural Systems” at the nearest possible time. The Institute for Biomagnetism and Biosignalanalysis of the University of Münster has an excellent structure and it is “state-of-the art” equipped. Therefore I would like to encourage all qualified colleagues to apply. Furthermore, Münster is a wonderful city to live! The Medical Faculty of the University of Münster offers the position of a Full Professor (W3) for Biomagnetism and Biosignalanalysis with focus on Magnetoencephalography and Multimodal Imaging of Neural Systems at the nearest possible time. The position is an appointment as a Head of the Institute for Biomagnestism and Biosignalanalysis at the Medical Faculty Münster. The holder of this position-to-be (she/he) should have the ability to represent the discipline entirely in research and teaching as well. The candidates should have medical or natural science training and an outstanding qualification in scientific research and teaching. An internationally recognized research profile in application of Magnetoencephalography and other Neuroimaging-Methods in particular EEG, MRI/fMRI, TMS/tDCS, PET are expected. Beside the ability to formulate and solve theoretical and analytical tasks, a successful cooperation with the clinical neuro-scientific research field of the Faculty is presumed. The active collaboration with the scientific main topic oft the faculty “Neural Systems” is explicitly required. Further important criteria are excellent research- and publication-records. Likewise, convincing experience in modern scientific management, particularly in raising of national and international scientific funds, ability for collaboration, interdisciplinarity, and administrative and social competence are requirements for application. The scientific networking and close cooperation with adjacent disciplines are expected. The Medical Faculty anticipates a collaboration with existing research foci and research associations e.g. the excellence cluster “Cells in motion” (EXC 1003), the interdisciplinary clinical research center (IZKF), the center for clinical studies (ZKS), the existing research associations (SFB) and the MPI “Molecular biomedicine”. Prerequisites for the application are scientific achievements, which have been yielded within Junior-Professorship, Habilitation, or scientific work at university or non-university institutions. We point additionally on the required qualification given in § 36 of the Hochschulgesetz. The University of Münster is an equal opportunity employer and is committed to increasing the proportion of senior female academics. Consequently, we actively encourage applications by women. Female candidates with equivalent qualifications and academic achievements will be preferentially considered within the framework of the legal possibilities. We also welcome applications from candidates with severe disabilities. Disabled candidates with equivalent qualifications will be preferentially considered. Applications including the standard documents (CV, scientific career, structured publication list, raised funds) inclusively the summary of the teaching accomplishments with detailed and profound teaching concept together with reprints of the six most important publications should be submitted to the Dean of the Medical Faculty, Westfälische Wilhelms-Universität Münster, Albert-Schweitzer-Campus 1, Gebäude D3, 48149 Münster, by 27.05.2016. Please take into account the hints about Professorial Nominations at our website: www.campus.uni-muenster.de . Best regards --- Univ.-Prof. Dr. Christo Pantev Direktor des Instituts für Biomagnetismus und Biosignalanalyse WWU Münster Adjunct Professor Rotman Research Institute for Neuroscience University of Toronto, Canada Malmedyweg 15 D-48149 Münster Telefon: +49 (0)251 83 56865 (56885) fax: +49 (0)251 83 56874 E-Mail: pantev at uni-muenster.de http://biomag.uni-muenster.de -------------- next part -------------- An HTML attachment was scrubbed... URL: From j.brehm at uu.nl Mon Apr 25 15:55:53 2016 From: j.brehm at uu.nl (Brehm, J. (Julia)) Date: Mon, 25 Apr 2016 13:55:53 +0000 Subject: [FieldTrip] Problems with filterpadding in ft_artifact_zvalue Message-ID: <385DDA785CF9764B8E184EF28D01ADE05995E2@WP0046.soliscom.uu.nl> Dear list, I am currently working on implementing an automatic artifact rejection using ft_artifact_zvalue. It already works quite nicely for detecting jumps and EOG artifacts. However, when trying to detect high frequency noise I am often getting edge effects. I am already using filterpadding for the eog artifacts were it does a good job, but for the higher frequencies it suddenly almost only detects artifacts at the outermost trials (first and last) even though there are also obvious artifacts in different trials. The data is previously demeaned and filtered using a notch filter and a bandpass filter from 1-100 Hz. These are my settings for the artifact detection now: cfg = []; cfg.trl = temptrl; % all trials in this case cfg.artfctdef.zvalue.channel = channel{ch}; % single channel cfg.artfctdef.zvalue.cutoff = 3; cfg.artfctdef.zvalue.fltpadding = 0.1; cfg.artfctdef.zvalue.bpfilter = 'yes'; cfg.artfctdef.zvalue.bpfilttype = 'but'; cfg.artfctdef.zvalue.bpfreq = [70 100]; cfg.artfctdef.zvalue.bpfiltord = 2; cfg.artfctdef.zvalue.hilbert = 'yes'; cfg.artfctdef.zvalue.boxcar = 0.2; [cfg, artifact] = ft_artifact_zvalue(cfg, data); I already tried changing the settings around but that didn't do much good. Any help would be appreciated and please tell me if I am doing anything terribly wrong! Best, Julia -------------- next part -------------- An HTML attachment was scrubbed... URL: From icelandhouse at gmail.com Mon Apr 25 23:51:34 2016 From: icelandhouse at gmail.com (Maris Skujevskis) Date: Mon, 25 Apr 2016 23:51:34 +0200 Subject: [FieldTrip] transformation matrix Message-ID: Dear Fieldtrip users, A quick simple question (maybe it's been answered somewhere already but really I cannot find it...) Functions like ft_read_mri and ft_volumerealign attach the field 'transform' (a 4 x 4 matrix) to the data structure ( http://www.fieldtriptoolbox.org/faq/how_to_coregister_an_anatomical_mri_with_the_gradiometer_or_electrode_positions ) My question is: what operations do each of the values in this transformation matrix correspond to? Thanks for your help! Maris -------------- next part -------------- An HTML attachment was scrubbed... URL: From jorn at artinis.com Tue Apr 26 09:26:25 2016 From: jorn at artinis.com (=?UTF-8?Q?J=C3=B6rn_M._Horschig?=) Date: Tue, 26 Apr 2016 09:26:25 +0200 Subject: [FieldTrip] transformation matrix In-Reply-To: References: Message-ID: <003301d19f8c$f1442d70$d3cc8850$@artinis.com> Hi Maris, The transformation matrix contains the rotation, scaling (so to say, the upper-left 3x3 matrix) and other components, e.g. a translational component (the 4th column). You can think of the fourth row as a sort of a mathematical trick to end up with a square matrix, making a lot of operations easier and computationally more efficient. This 4x4 transformation matrix is actually called a projection matrix (widely used in 3D programming), and there the 4th row actually plays a big role in perspective mapping (e.g. being able to make objects farther away seem smaller). This explanation should be roughly correct - I am not a mathematician though ;) Best regards, Jörn -- Jörn M. Horschig, PhD, Software Engineer Artinis Medical Systems | +31 481 350 980 From: fieldtrip-bounces at science.ru.nl [mailto:fieldtrip-bounces at science.ru.nl] On Behalf Of Maris Skujevskis Sent: Monday, April 25, 2016 23:52 To: fieldtrip at science.ru.nl Subject: [FieldTrip] transformation matrix Dear Fieldtrip users, A quick simple question (maybe it's been answered somewhere already but really I cannot find it...) Functions like ft_read_mri and ft_volumerealign attach the field 'transform' (a 4 x 4 matrix) to the data structure ( http://www.fieldtriptoolbox.org/faq/how_to_coregister_an_anatomical_mri_with_the_gradiometer_or_electrode_positions ) My question is: what operations do each of the values in this transformation matrix correspond to? Thanks for your help! Maris -------------- next part -------------- An HTML attachment was scrubbed... URL: From zsoltturi at gmail.com Tue Apr 26 14:14:34 2016 From: zsoltturi at gmail.com (Zsolt Turi) Date: Tue, 26 Apr 2016 14:14:34 +0200 Subject: [FieldTrip] cluster plot Message-ID: Dear Filedtrip users, I recently performed a non-parametric cluster-based permutation test on time-frequency data using a within-subjects design. I have two related questions/issues: 1) Size issues: For 11 participants the size of the file containing the time-frequency grand averages is 1.4 GB for each condition (I have two conditions), which is really hard to load in for the permutation test. Is this size reasonable? powspctrm: [4-D double] label: {64x1 cell} freq: [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20] time: [1x26 double] dimord: 'subj_chan_freq_time' cfg: [1x1 struct] 2) Cluster plot issue: Related to the first issue, after generating the plots for the stat, the computer stops responding and it is impossible to save the figure or even close it. cfg = []; cfg.alpha = 0.05; cfg.parameter = 'stat'; cfg.zlim = [-4 4]; cfg.layout = 'EEG1010.lay'; ft_clusterplot(cfg, stat); Have some of you encountered such kind of issues? I use 64 bit Win 7 OS, 8 GB RAM, Intel Core i5 CPU, 9.0.0.341360 (R2016a) Matlab and fieldtrip-20160424 versions. Thanks for your help in advance! Zsolt -------------- next part -------------- An HTML attachment was scrubbed... URL: From p.taesler at uke.de Tue Apr 26 14:45:03 2016 From: p.taesler at uke.de (Philipp Taesler) Date: Tue, 26 Apr 2016 14:45:03 +0200 Subject: [FieldTrip] cluster plot In-Reply-To: References: Message-ID: <571F62CF.6000201@uke.de> Hi Zsolt, I've had some similar problems with data from a very long analysis pipeline. It also failed to plot. A quick and dirty solution for me was to get rid of the "cfg" field in the struct, as it had somehow accumulated lots of data. newdata = rmfield(olddata, 'cfg'); Maybe this will help, otherwise I'm out of ideas for now :) Cheers, Phil Am 26.04.2016 um 14:14 schrieb Zsolt Turi: > Dear Filedtrip users, > > I recently performed a non-parametric cluster-based permutation test on > time-frequency data using a within-subjects design. I have two related > questions/issues: > > 1) Size issues: > > For 11 participants the size of the file containing the time-frequency > grand averages is 1.4 GB for each condition (I have two conditions), > which is really hard to load in for the permutation test. Is this size > reasonable? > > > powspctrm: [4-D double] > label: {64x1 cell} > freq: [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20] > time: [1x26 double] > dimord: 'subj_chan_freq_time' > cfg: [1x1 struct] > > > 2) Cluster plot issue: > > Related to the first issue, after generating the plots for the stat, the > computer stops responding and it is impossible to save the figure or > even close it. > > cfg = []; > cfg.alpha = 0.05; > cfg.parameter = 'stat'; > cfg.zlim = [-4 4]; > cfg.layout = 'EEG1010.lay'; > ft_clusterplot(cfg, stat); > > Have some of you encountered such kind of issues? > > > I use 64 bit Win 7 OS, 8 GB RAM, Intel Core i5 CPU, 9.0.0.341360 > (R2016a) Matlab and fieldtrip-20160424 versions. > > Thanks for your help in advance! > > Zsolt -- Philipp Taesler Department of Systems Neuroscience University Medical Center Hamburg-Eppendorf Martinistr. 52, W34, 20248 Hamburg, Germany Phone: +49-40-7410-59902 Fax: +49-40-7410-59955 Email: p.taesler at uke.de -- _____________________________________________________________________ Universitätsklinikum Hamburg-Eppendorf; Körperschaft des öffentlichen Rechts; Gerichtsstand: Hamburg | www.uke.de Vorstandsmitglieder: Prof. Dr. Burkhard Göke (Vorsitzender), Prof. Dr. Dr. Uwe Koch-Gromus, Joachim Prölß, Rainer Schoppik _____________________________________________________________________ SAVE PAPER - THINK BEFORE PRINTING From rb643 at medschl.cam.ac.uk Tue Apr 26 23:12:27 2016 From: rb643 at medschl.cam.ac.uk (Richard Bethlehem) Date: Tue, 26 Apr 2016 21:12:27 +0000 Subject: [FieldTrip] PostDoc/Bioinformatician post available at Cambridge Message-ID: <3188FAB8621D294696F13E80A7BBC97E01013D9C2D@me-mbx3.medschl.cam.ac.uk> Dear all, Our lab is current looking hire a bio-information to work and a large genetics data project and in a wonderful team! http://www.jobs.cam.ac.uk/job/10224/ It might be beyond the remit of the mailing list so please feel free toward to anyone you think might be interested! Cheers, Richard -------------- next part -------------- An HTML attachment was scrubbed... URL: From zsoltturi at gmail.com Wed Apr 27 09:46:34 2016 From: zsoltturi at gmail.com (Zsolt Turi) Date: Wed, 27 Apr 2016 09:46:34 +0200 Subject: [FieldTrip] cluster plot In-Reply-To: <571F62CF.6000201@uke.de> References: <571F62CF.6000201@uke.de> Message-ID: Dear Phil, thanks for the suggestion, I tried and it worked out! Cheers, Zsolt 2016-04-26 14:45 GMT+02:00 Philipp Taesler : > Hi Zsolt, > > I've had some similar problems with data from a very long analysis > pipeline. It also failed to plot. A quick and dirty solution for me was > to get rid of the "cfg" field in the struct, as it had somehow > accumulated lots of data. > > newdata = rmfield(olddata, 'cfg'); > > Maybe this will help, otherwise I'm out of ideas for now :) > > Cheers, > Phil > > > Am 26.04.2016 um 14:14 schrieb Zsolt Turi: > > Dear Filedtrip users, > > > > I recently performed a non-parametric cluster-based permutation test on > > time-frequency data using a within-subjects design. I have two related > > questions/issues: > > > > 1) Size issues: > > > > For 11 participants the size of the file containing the time-frequency > > grand averages is 1.4 GB for each condition (I have two conditions), > > which is really hard to load in for the permutation test. Is this size > > reasonable? > > > > > > powspctrm: [4-D double] > > label: {64x1 cell} > > freq: [1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20] > > time: [1x26 double] > > dimord: 'subj_chan_freq_time' > > cfg: [1x1 struct] > > > > > > 2) Cluster plot issue: > > > > Related to the first issue, after generating the plots for the stat, the > > computer stops responding and it is impossible to save the figure or > > even close it. > > > > cfg = []; > > cfg.alpha = 0.05; > > cfg.parameter = 'stat'; > > cfg.zlim = [-4 4]; > > cfg.layout = 'EEG1010.lay'; > > ft_clusterplot(cfg, stat); > > > > Have some of you encountered such kind of issues? > > > > > > I use 64 bit Win 7 OS, 8 GB RAM, Intel Core i5 CPU, 9.0.0.341360 > > (R2016a) Matlab and fieldtrip-20160424 versions. > > > > Thanks for your help in advance! > > > > Zsolt > > > -- > Philipp Taesler > Department of Systems Neuroscience > University Medical Center Hamburg-Eppendorf > Martinistr. 52, W34, 20248 Hamburg, Germany > > Phone: +49-40-7410-59902 > Fax: +49-40-7410-59955 > Email: p.taesler at uke.de > -- > > _____________________________________________________________________ > > Universitätsklinikum Hamburg-Eppendorf; Körperschaft des öffentlichen > Rechts; Gerichtsstand: Hamburg | www.uke.de > Vorstandsmitglieder: Prof. Dr. Burkhard Göke (Vorsitzender), Prof. Dr. Dr. > Uwe Koch-Gromus, Joachim Prölß, Rainer Schoppik > _____________________________________________________________________ > > SAVE PAPER - THINK BEFORE PRINTING > > _______________________________________________ > fieldtrip mailing list > fieldtrip at donders.ru.nl > http://mailman.science.ru.nl/mailman/listinfo/fieldtrip -- Post-doctoral Research Fellow Department of Clinical Neurophysiology Georg-August University, Göttingen Robert-Koch-Str. 40 37075 Goettingen -------------- next part -------------- An HTML attachment was scrubbed... URL: From ph442 at cam.ac.uk Wed Apr 27 12:49:18 2016 From: ph442 at cam.ac.uk (parham hashemzadeh) Date: Wed, 27 Apr 2016 11:49:18 +0100 Subject: [FieldTrip] MNE-sample data set on Fieldtrip. Message-ID: <96d4943980d708a2b7d8b6ffbc439792@cam.ac.uk> Dear All I was hoping to perform a complete source analysis using FieldTrip on the MNE-sample data set. The link to the MNE data set link is given below: http://martinos.org/mne/dev/manual/sample_dataset.html#babdhifj I am terribly confused on how to align the MRI coordinates to MEG. The MEG system is a neuromag306. The function hdr=ft_read_header(raw_data_set_filename) reads fiducial marks HPI. It is contained in hdr.orig.dig. Also shape = ft_read_headshape(raw_data_set_filename) gives a structure shape = pos: [143x3 double] fid: [1x1 struct] label: {143x1 cell} coordsys: 'neuromag' unit: 'cm' pnt: [143x3 double] where the shape.fid has the nasion, lpa and rpa. I have the following questions: 1. It appears to me that the MRI coordinate system is already spm. Axis X :Left to right. Axis Y: Posterior to Anterior. Axis Z: bottom to top. 2. How can I realign the MRI to MEG? a) Interactively: ft_volumerealign or b) Should I use the information in shape to have it done automatically? I think, it would be unwise to define my own lpa, rpa and nasion. 3. What is the relationship between HPI coil coordinates and the lpa, rpa and nasion coordinates? Are there scripts that relate the two. 4. Has anyone ever created a script to use Fieldtrip to analyze this specific data set? 5. The MEG sensors are in a different coordinate frame "1" as opposed to head coordinates (Electrodes). Do I have to make sure that these coordinates are transformed to head coordinates prior to ft_prepare_leadfield calculations? or is this done automatically by fieldtrip? I just have the feeling that it would be unwise to do this interactively because of the existence of the fiducial markers. Many thanks if you are able to help me. -- best regards Parham Hashemzadeh Research Associate Department of Applied Mathematics and Theoretical Physics University of Cambridge, UK. email: hashemzadeh at damtp.cam.ac.uk From gina.joue at univr.it Wed Apr 27 18:24:16 2016 From: gina.joue at univr.it (gj) Date: Wed, 27 Apr 2016 18:24:16 +0200 Subject: [FieldTrip] FW: From a .csv data file, to a recognized dataset by fieldtrip In-Reply-To: References: Message-ID: <5720E7B0.4060207@univr.it> Hi Mina, I'm definitely not a FieldTrip expert, but I recently did something similar with .dat files that was just tab-delimited EEG data in the format [nsamples x nchan]. I followed this page closely: http://www.fieldtriptoolbox.org/faq/how_can_i_import_my_own_dataformat Basically, I created the following FT data structure: data.label % [nchan x 1] cell array of string labels for channels data.fsample % sampling frequency in Hz % for each trial t: data.trial{t} = load('eeg.dat'); % load your EEG data file -- should be [nchan x nsamples] data.time{t} % [1 x nsamples] vector corresponding to the time axis for each trial in SECONDS at each sampling point! If you've set all of that, you should be able to doublecheck your data by plotting it, e.g. cfg = []; cfg.viewmode = 'vertical'; % 'butterfly" superimposes channels cfg.continuous = 'no'; ft_databrowser(cfg,data); To prepare your channel layouts in FT data format, it seems like you need the electrodes in the ff formats 1. in mm in MNI coordinates and FT 2-D data format (see also templates in your FT subfolder: template/electrode/). If you don't have this, you can prepare your channel layout by using ft_prepare_layout() (check out the comments in the code or 'help ft_prepare_layout'). Then check that you've set up your data structure correctly with ft_plot_lay(); 2. in phi/theta coordinates of FT_DATATYPE_SENS format (some templates in FT subfolder template/layout/). Check out "help FT_DATATYPE_SENS" Your fiducials should be at the beginning of the list of your channels. Hope that is somewhat useful. Good luck! g From runna90 at 126.com Thu Apr 28 03:15:05 2016 From: runna90 at 126.com (CRN) Date: Thu, 28 Apr 2016 09:15:05 +0800 Subject: [FieldTrip] filter in continuous data and then epoch Message-ID: Dear fieldtrippers, I am processing MEG data acquired by CTF275 and I want to do filters in continuous raw data and then epoch them according to triggers. But I got warnings which were displayed below the code. Here is my code: cfg = []; cfg.dataset = dataset.ds; cfg.continuous = 'yes'; cfg.channel = 'meg'; raw_data = ft_preprocessing(cfg); cfg = []; cfg.lpfilter = 'yes'; cfg.lpfreq = 30; cfg.hpfilter = 'yes'; cfg.hpfreq = 1; cfg.dftfilte = 'yes'; cfg.dftfreq = 50; conti_filt = ft_preprocessing(cfg,raw_data); cfg=[]; cfg.dataset = [subjectdata.subjectdir filesep subjectdata.datadir{f_n}]; cfg.trialdef.eventtype = 'frontpanel trigger'; cfg.trialdef.eventvalue = 3; cfg.trialdef.pre = 0.5; cfg.trialdef.post = 1.2; cfg.continuous = 'yes'; cfg.trialfun = 'ft_trialfun_crn'; % self defined trl function cfg.channel = 'MEG'; cfg.layout = 'MEG.lay'; cfg = ft_definetrial(cfg); data_filt = ft_preprocessing(cfg, conti_filt); Warning: The field cfg.trl is forbidden, it will be removed from your configuration The field cfg.dataset is forbidden, it will be removed from your configuration The field cfg.datafile is forbidden, it will be removed from your configuration The field cfg.headerfile is forbidden, it will be removed from your configuration I have stuck in this question a whole night, please help! Thank you very much! Best wishes, Runnan runna90 at 126.com Institute of Biophysics, Chinese Academy of Science, Beijing, China -------------- next part -------------- An HTML attachment was scrubbed... URL: From icelandhouse at gmail.com Thu Apr 28 21:06:35 2016 From: icelandhouse at gmail.com (Maris Skujevskis) Date: Thu, 28 Apr 2016 21:06:35 +0200 Subject: [FieldTrip] Electrode position effects on leadfield values Message-ID: Dear Fieldtrip users, It is common knowledge that due to noise/measurement error, it is hard, if not impossible to match Polhemus digitized electrode locations with the MR head shape precisely. Even after manual and iterative alignment some electrodes remain "hanging" in the air above the head surface, while some others get buried below the head surface. Here is an illustration of what I mean: https://goo.gl/aSm7YU I am wondering what effect this type of electrode misplacement has on the values in the leadfield matrix as calculated by ft_prepare_leadfield? How does fieldtrip deal with electrodes placed in such a way? It seems that there is some magic involved there, since in theory the lead field matrix values for the electrodes not touching the surface of the head should be zero (which is not the case in the lead field matrix produced by ft_prepare_leadfield). I am currently testing how moving a "floating" and a "buried" electrode to its nearest point on the scalp affects the leadfield matrix values. I do not have any definite answers yet, but I did want to check in with some more experienced users out there before spending too much time on this (and possibly reinventing the wheel, so to speak). Thanks! Maris -------------- next part -------------- An HTML attachment was scrubbed... URL: From A.Reid at psych.ru.nl Fri Apr 29 14:01:38 2016 From: A.Reid at psych.ru.nl (Reid, A.T. (Andrew)) Date: Fri, 29 Apr 2016 12:01:38 +0000 Subject: [FieldTrip] Unit error using ft_topoplotTFR.m Message-ID: <5AE33796-5433-4D90-AE5F-A3ABD85E0C00@donders.ru.nl> Hi all, I am trying to do a simple topo plot of some time-locked HCP data. Running ft_multiplotTFR on the TFR output structure works fine. When I run ft_topoplotTFR on the same structure, I get the following error: creating layout from data.grad undoing the invcomp balancing for the gradiometer definition Error using ft_scalingfactor (line 181) cannot convert T to unknown Error in ft_scalingfactor (line 94) factor = cellfun(@ft_scalingfactor, old(:), new(:)); Error in ft_apply_montage (line 309) scale = ft_scalingfactor(input.chanunit, montage.chanunitorg); Error in undobalancing (line 37) sens = ft_apply_montage(sens, sens.balance.(sens.balance.current), 'inverse', 'yes', 'keepunused', 'yes', 'warning', 'no'); Error in ft_prepare_layout>sens2lay (line 957) sens = undobalancing(sens); Error in ft_prepare_layout (line 430) layout = sens2lay(data.grad, cfg.rotate, cfg.projection, cfg.style, cfg.overlap); Error in ft_topoplotTFR (line 192) cfg.layout = ft_prepare_layout(cfg, varargin{:}); The data.grad.balance.invcomp.chanunitnew cell array appears to be the culprit, as it contains “unknown” while the main data.chanunit has unit “T”. Not sure how to proceed here.. Thanks! Andrew ____________________________________________________ Andrew Reid Postdoctoral Fellow Department of Cognitive Artificial Intelligence Donders Institute for Brain, Cognition and Behaviour Radboud University Nijmegen Web: http://andrew.modelgui.org/ Tel: +31 (0)24 36 55931 -------------- next part -------------- An HTML attachment was scrubbed... URL: From gina.joue at univr.it Fri Apr 29 17:49:05 2016 From: gina.joue at univr.it (gj) Date: Fri, 29 Apr 2016 17:49:05 +0200 Subject: [FieldTrip] Fwd: ft_sourcegrandaverage and ft_sourceplot usage In-Reply-To: <57238213.5090103@univr.it> References: <57238213.5090103@univr.it> Message-ID: <57238271.70009@univr.it> Hi, I had computed source reconstruction in the frequency domain of my EEG data -- followed by * ft_sourcedescriptives with cfg.projectmom="yes" * set the resulting source_proj.dim = grid.dim source_proj.pos = grid.pos * ft_sourceinterpolate onto an MNI template brain but for some conditions of some subjects, this resulting localizations were predominantly in the center of the head. So, I was thinking of calculating the grand average of the source (though is this kosher when I have obvious individual source modeling problems?): ----- cfg.parameter = 'avg.pow'; cfg.keepindividual = 'yes'; cfg.outputfile = 'srcGrandAvg'; srcGrandAvg = ft_sourcegrandaverage(cfg, source_interp{:}); % source_interp = output of ft_sourceinterpolate ----- I'm not sure if my approach is correct because this results in a HUGE (several hundred MBs) srcGrandAvg matrix per condition that takes forever to write to disk. Moreover I cannot seem to plot it with ft_sourceplot (doesn't plot the source averaging results): ----- cfg = []; cfg.funparameter = 'pow'; cfg.method='ortho'; srcGrandAvg.anatomy = mri.anatomy; % from load('standard_mri.mat'); figure ft_sourceplot(cfg,srcGrandAvg); ----- ft_sourceplot gives me the messages: ----- the input is source data with 7109137 brainordinates on a [181 217 181] grid scaling anatomy to [0 1] not plotting functional data not applying a mask on the functional data not using an atlas not using a region-of-interest ----- My output from ft_sourcegrandaverage looks like this: ----- srcGrandAvg = pow: [19x7109137 double] coordsys: 'spm' dim: [181 217 181] freq: 12 inside: [7109137x1 logical] pos: [7109137x3 double] unit: 'mm' cfg: [1x1 struct] anatomy: [1x1 struct] ----- Thanks in advance for any help or advice!!! Gina