From dahliash at STANFORD.EDU Tue Dec 1 00:33:04 2009 From: dahliash at STANFORD.EDU (Dahlia Sharon) Date: Tue, 1 Dec 2009 00:33:04 +0100 Subject: t statistic of coherence difference between stimulus conditions Message-ID: Hi, Since the coherence spectrum is different from the power spectrum in not being a simple average over trials, I am wondering how the point-by-point statistic should be calculated. I.e. does it make sense to take the difference in coherence between the two conditions and divide by the standard error? A shorter version of this question is: how does one test for a statistically significant coherence difference between two stimulus conditions in fieldtrip? Thanks, Dahlia. ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From j.schoffelen at PSY.GLA.AC.UK Tue Dec 1 09:03:12 2009 From: j.schoffelen at PSY.GLA.AC.UK (Jan-Mathijs Schoffelen) Date: Tue, 1 Dec 2009 09:03:12 +0100 Subject: single trial source signal In-Reply-To: <58ccc8240911301202j7c6a55e1w3cc8227ed18605e9@mail.gmail.com> Message-ID: Vasan, I feel that FieldTrip has the capability of extracting the single trial source signals. I think that MNE and LORETA do not fully support it yet, but in order to get there, you may have to hack the code a bit. With LCMV it is certainly possible. The only thing you have to do is specify cfg.keepfilter = 'yes' prior to sourceanalysis. The output to sourceanalysis will contain a field source.avg.filter, which contain per voxel the beamformer weights. You can get the single trial source data per voxel by doing something like this on the command line: singletrialvoxeldataofvoxelXintrialY = source.avg.filter{X} * data.trial{Y}. Et voilà. MNE and LORETA provide the projection matrix in one big shot, and as far as I know do not yet output the filt-matrix directly, but it should be possible to extract these from the functions and apply the same logic. Good luck, Jan-Mathijs On 30 Nov 2009, at 21:02, Sreenivasan Rajamoni Nadar wrote: > Dear FieldTrip users, > > I personally feel that the FieldTrip (latest version) does not seems > to having the capability to extract single trial source signals > using any of the the time domain beamformers: LCMV, MNE, SAM, > LORETA, RV or using the frequency domain beamformer methods like > DICS and PCC !! > > Please let me know if any of you made plugin codes to Fieldtrip to > get single trial source data? Robert, Could you let me know if there > is any other version which does the above? > > Thank you, > Vasan > > > > > > > > > > > ---------------------------------- > > The aim of this list is to facilitate the discussion between users > of the FieldTrip toolbox, to share experiences and to discuss new > ideas for MEG and EEG analysis. > > http://listserv.surfnet.nl/archives/fieldtrip.html > > http://www.ru.nl/fcdonders/fieldtrip/ > ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From jan.schoffelen at DONDERS.RU.NL Tue Dec 1 08:57:53 2009 From: jan.schoffelen at DONDERS.RU.NL (jan-mathijs schoffelen) Date: Tue, 1 Dec 2009 08:57:53 +0100 Subject: t statistic of coherence difference between stimulus conditions In-Reply-To: Message-ID: Dear Dahlia, Your question has been asked before, so it may be worthwile to browse the archive of the mailing list a bit. In short, the way to go depends on what you want: 1) Do you want to test for significance within a subject? Then it may be worthwhile to have a look at Maris et al 2007 J.Neurosci.Methods. Here we describe a way to test for significant coherence differences using permutation tests. 2) If you want to test for significance across subjects (which I generally prefer), I would compute the coherence difference per subject and apply a Z-transformation to the difference. Subsequently I do a permutation test across subjects. By randomly swapping the sign of the Z-transformed difference you obtain a distribution under the null-hypothesis, i.e. no difference in coherence across subjects. (for a formulation of the z-statistic you can have a look at the Maris paper). Both options are possible in fieldtrip, but it may require some coding yourself. Best wishes, Jan-Mathijs On 1 Dec 2009, at 00:33, Dahlia Sharon wrote: > Hi, > > Since the coherence spectrum is different from the power spectrum in > not > being a simple average over trials, I am wondering how the point-by- > point > statistic should be calculated. I.e. does it make sense to take the > difference in coherence between the two conditions and divide by the > standard error? > > A shorter version of this question is: how does one test for a > statistically > significant coherence difference between two stimulus conditions in > fieldtrip? > > Thanks, > Dahlia. > > ---------------------------------- > The aim of this list is to facilitate the discussion between users > of the FieldTrip toolbox, to share experiences and to discuss new > ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html > and http://www.ru.nl/neuroimaging/fieldtrip. > Dr. J.M. (Jan-Mathijs) Schoffelen Donders Institute for Brain, Cognition and Behaviour, Centre for Cognitive Neuroimaging, Radboud University Nijmegen, The Netherlands J.Schoffelen at donders.ru.nl Telephone: 0031-24-3668063 ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From Hanneke.vanDijk at MED.UNI-DUESSELDORF.DE Tue Dec 1 11:59:38 2009 From: Hanneke.vanDijk at MED.UNI-DUESSELDORF.DE (Hanneke Van Dijk) Date: Tue, 1 Dec 2009 11:59:38 +0100 Subject: single trial source signal Message-ID: Dear Vasan, I also feel single-trial source-analysis does work, I have done it and published it J Neurosci (using pcc for just power data). The problem as you sent it in the mail below is that the cfg.grid.pos that you entered is not inside your headmodel: 0 dipoles inside, 1 dipoles outside brain There wil not be any data in there. You could try to plot the functional data interpolated on the mri with cfg.interactive = 'yes'; and then click on the location you want to do the single-trial analysis on. The coordinates will be printed in the workspace. These can be entered in cfg.grid.pos. If you have any more questions could you then send the cfg you used as well? This might give some hints as to what went wrong. It's just not the case that you can use some-one elses code and run your data through it. The choises you make for the data analysis depend a lot on the kind of data and what you want to do. But this mailing list is there to help you allong the way! Hope it helps, Best, Hanneke -----Oorspronkelijk bericht----- Van: van Dijk, Hanneke Verzonden: zo 29.11.2009 09:38 Aan: FieldTrip discussion list Onderwerp: RE: [FIELDTRIP] single trial source signal Dear Vasan, Since I don't know exactly how far you are in doing the analysis, I just send you the basic script that shows the most important parameters. Don't forget to do freqanalysis with cfg.output = 'fourier' and cfg.method = 'mtmfft' for the specific frequency (cfg.foilim) you want to focus on. cfg = []; cfg.grid.pos = location of source coordinate;% [x y z] to fill in cfg.frequency = frequency of interest; cfg.vol = headmodel; %to make yourself see http://fieldtrip.fcdonders.nl/example/make_leadfields_using_different_headmodels cfg.projectnoise = 'yes';%to compute the neural activity index using sourcedescriptives cfg.lambda = '10%';%the amount of noice to estimate estimated cfg.method = 'pcc'; cfg.keeptrials = 'yes'; Virtual_channeldata = sourceanalysis(cfg,freq); You can do sourcedescriptives after that. 'help freqanalysis', 'help sourceanalysis' and 'help sourcedescriptives' should also help you further. Or you could have a look at the fieldtrip website. There are a lot of options to taylor the analysis to your data. Hope this helps! Best, Hanneke van Dijk ------------------------------------------------------------ Institute for Clinical Neuroscience and Medical Psychology Heinrich Heine Universitaet, Duesseldorf, Germany ------------------------------------------------------------ -----Oorspronkelijk bericht----- Van: FieldTrip discussion list namens Rajamoni Nadar, Sreenivasan (NIH/NIMH) [E] Verzonden: do 26.11.2009 14:53 Aan: FIELDTRIP at NIC.SURFNET.NL Onderwerp: [FIELDTRIP] single trial source signal FieldTrip Users, Is it possible to get single trial source signal using FieldTrip? I would appreciate if anybody could provide code for the same. Thank you, Vasan ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From sreenivasan.r.nadar at GMAIL.COM Tue Dec 1 17:20:24 2009 From: sreenivasan.r.nadar at GMAIL.COM (Sreenivasan Rajamoni Nadar) Date: Tue, 1 Dec 2009 11:20:24 -0500 Subject: single trial source signal In-Reply-To: <72E993C35FB11743B79FF9286E5B6D8B0F353C@Mail2-UKD.VMED.UKD> Message-ID: Dear Hanneke and FieldTripers, Thank you Hanneke. I extracted the single trial source signal using a time domain beamformer Please find below the script: clear all ds = sprintf('/rajamoni/MEG_ds/AEDTPJOU_nback_20050422_01-f.ds') cfg = []; cfg.dataset = ds; cfg.trialdef.eventtype = '?'; definetrial(cfg); cfg.trialdef.eventtype = 'r0'; cfg.trialdef.prestim = 0.25; cfg.trialdef.poststim = 0.25; cfg = definetrial(cfg); data = preprocessing(cfg); %~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ cfg.channel = {'MEG','-MRF43', '-MRO13'}; cfg.latency = [-0.25 0.25]; cfg.covariance = 'yes'; cfg.covariancewindow = [-0.0 0.25]; cfg.keeptrials = 'yes'; cfg.blcwindow = [-0.25 0.25]; cfg.bpfreq = [1 60]; [timelock] = timelockanalysis(cfg,data); %~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ctf_ss = read_ctf_hdm('/rajamoni/AEDTPJOU_nback_20050422_01-f.ds/default.hdm'); cfg = []; cfg.method = 'lcmv'; %'rv'; %'mvl', % 'pcc'; 'loreta'; %'mne'; cfg.grid.pos = [7.3 -3.9 3.9; 7.7 1.8,4.0]; %arbitrary source location cfg.singletrial = 'yes'; cfg.rawtrial = 'no'; cfg.keepfilter = 'yes'; cfg.keepmom = 'yes'; %cfg.hdmfile = strcat(ds, '/default.hdm'); cfg.channel = {'MEG','-MRF43', '-MRO13'}; cfg.vol = ctf_ss; [source] = sourceanalysis(cfg, timelock); % extraction of single trial source signals % %for trial all trials for i=1:66 trial{i}=source.trial(i).mom{1}; % 1 for the 1st source location and |||ly you could do for other source coord trial{i}=sqrt((sum(trial{i}.*trial{i}))); end; %~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ It seems to be working. I will report the other methods using freqanalysis after play with the FieldTrip for a while!! Any comments? -Vasan On Tue, Dec 1, 2009 at 4:28 AM, wrote: > Dear Vasan, > > I also feel single-trial source-analysis does work, I have done it and > published it J Neurosci (using pcc for just power data). > > The problem as you sent it in the mail below is that the cfg.grid.pos that > you entered is not inside your headmodel: > > 0 dipoles inside, 1 dipoles outside brain > > There wil not be any data in there. You could try to plot the functional > data interpolated on the mri with cfg.interactive = 'yes'; and then click on > the location you want to do the single-trial analysis on. The coordinates > will be printed in the workspace. These can be entered in cfg.grid.pos. > > If you have any more questions could you then send the cfg you used as > well? This might give some hints as to what went wrong. > > It's just not the case that you can use some-one elses code and run your > data through it. The choises you make for the data analysis depend a lot on > the kind of data and what you want to do. > But this mailing list is there to help you allong the way! > > Hope it helps, > > Best, Hanneke > > > > -----Oorspronkelijk bericht----- > Van: Sreenivasan Rajamoni Nadar [mailto:sreenivasan.r.nadar at gmail.com > ] > Verzonden: ma 30.11.2009 16:21 > Aan: van Dijk, Hanneke > Onderwerp: Re: [FIELDTRIP] single trial source signal > > > Dear Hanneke, > > I did the freq analysis and source analysis as suggested by you. I get the > following error: > > the input is freq data with 273 channels, 30 frequencybins and no timebins > using headmodel specified in the configuration > using gradiometers specified in the configuration > creating dipole grid based on user specified dipole positions > 0 dipoles inside, 1 dipoles outside brain > ??? Error using ==> nearest>mbscalar at 47 > Argument to mbscalar must be scalar > > Error in ==> nearest at 15 > mbscalar(val); > > Error in ==> prepare_freq_matrices at 72 > fbin = nearest(freq.freq, cfg.frequency); > > Error in ==> sourceanalysis at 359 > [Cf, Cr, Pr, Ntrials, tmpcfg] = prepare_freq_matrices(tmpcfg, data); > > ~~~~~~~~~~~~~~~~~~~~~~~ > > Do you know the way to fix it? > > Thanks, Vasan > > > > > On Sun, Nov 29, 2009 at 3:38 AM, Hanneke Van Dijk < > Hanneke.vanDijk at med.uni-duesseldorf.de> wrote: > > > Dear Vasan, > > > > Since I don't know exactly how far you are in doing the analysis, I just > > send you the basic script that shows the most important parameters. Don't > > forget to do freqanalysis with cfg.output = 'fourier' and cfg.method = > > 'mtmfft' for the specific frequency (cfg.foilim) you want to focus on. > > > > cfg = []; > > cfg.grid.pos = location of source coordinate;% [x y z] to fill in > > cfg.frequency = frequency of interest; > > cfg.vol = headmodel; %to make yourself see > > > http://fieldtrip.fcdonders.nl/example/make_leadfields_using_different_headmodels > > cfg.projectnoise = 'yes';%to compute the neural activity index using > > sourcedescriptives > > cfg.lambda = '10%';%the amount of noice to estimate estimated > > cfg.method = 'pcc'; > > cfg.keeptrials = 'yes'; > > Virtual_channeldata = sourceanalysis(cfg,freq); > > > > You can do sourcedescriptives after that. > > > > 'help freqanalysis', 'help sourceanalysis' and 'help sourcedescriptives' > > should also help you further. Or you could have a look at the fieldtrip > > website. There are a lot of options to taylor the analysis to your data. > > > > Hope this helps! > > > > Best, > > > > Hanneke van Dijk > > > > ------------------------------------------------------------ > > Institute for Clinical Neuroscience and Medical Psychology > > Heinrich Heine Universitaet, Duesseldorf, Germany > > ------------------------------------------------------------ > > > > -----Oorspronkelijk bericht----- > > Van: FieldTrip discussion list namens Rajamoni Nadar, Sreenivasan > > (NIH/NIMH) [E] > > Verzonden: do 26.11.2009 14:53 > > Aan: FIELDTRIP at NIC.SURFNET.NL > > Onderwerp: [FIELDTRIP] single trial source signal > > > > FieldTrip Users, > > > > Is it possible to get single trial source signal using FieldTrip? I would > > appreciate if anybody could provide code for the same. > > > > Thank you, > > Vasan > > ---------------------------------- > > The aim of this list is to facilitate the discussion between users of the > > FieldTrip toolbox, to share experiences and to discuss new ideas for MEG > > and EEG analysis. See also > > http://listserv.surfnet.nl/archives/fieldtrip.html and > > http://www.ru.nl/neuroimaging/fieldtrip. > > > > > > ---------------------------------- > > The aim of this list is to facilitate the discussion between users of the > > FieldTrip toolbox, to share experiences and to discuss new ideas for MEG > > and EEG analysis. See also > > http://listserv.surfnet.nl/archives/fieldtrip.html and > > http://www.ru.nl/neuroimaging/fieldtrip. > > > > > ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From gsudre at POBOX.COM Tue Dec 1 17:24:48 2009 From: gsudre at POBOX.COM (Gustavo Sudre) Date: Tue, 1 Dec 2009 11:24:48 -0500 Subject: source localization of frequency bands Message-ID: Hello, I have a generic question about source localization. From what I've seen so far, when the goal is to localize the activity in certain frequency bands, it's common to use methods such as DICS or the variant of MCE for frequency bands. I was wondering if it is also correct to do source localization using a different method (e.g. MNE) with the whole signal (i.e. prior to band-pass filtering to specific bands) and then convert the signal in the localized sources to frequency domain. Another alternative would be to band-pass the signal to a certain frequency band in source space, and then run a different source localization method on it (e.g. MNE). Could anyone elaborate on the advantages / disadvantages ( / validity) of these two methods? Thank you, Gus ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From Jan.Hirschmann at MED.UNI-DUESSELDORF.DE Thu Dec 3 17:00:07 2009 From: Jan.Hirschmann at MED.UNI-DUESSELDORF.DE (Jan Hirschmann) Date: Thu, 3 Dec 2009 17:00:07 +0100 Subject: minor problem loading fiff file Message-ID: Hi, this is my very first day with fieldtrip so there is some chance that the error is due to the user rather than to the code... Anyways, I had the following problem. I loaded a fif file using preprocessing which did not start a time 0 but later. I got an a error from the mne function fiff_read_raw_segment saying that there is no data in this range. I tried to define the trial differently setting trl in different ways but it didn't help so I looked at the code. Preprocessing calls the function read_header which said that nSamplesPre were -6031500 in my case. So I guess this means that there are samples missing between a trigger (I don"t know which) and the start of the file. Later in preprocessing the function read_data calls fiff_read_raw_segment with the following arguments: read_data.m, line 691.m: dat = fiff_read_raw_segment(hdr.orig.raw,begsample+hdr.nSamplesPre-1,endsample+hdr.nSamplesPre-1,chanindx); Thus fiff_read_raw_segment is launched with negative to and from values which finally causes the error. nSamples should have been subtracted here and not added (it is a negative integer). I would suggest that in the future the call to the function should be only with arguments coming from the header file, i.e. from = hdr.orig.raw.last_samp and to = hdr.orig.raw.first_samp or that the pluses in the quoted line should be changed to minuses (which I did now in my version). However, I don't know if my file is strange (neg nSamplesPre) or if the code has a bug. Hope this helps anyone Best, Jan ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From fredericroux at HOTMAIL.DE Fri Dec 4 12:50:58 2009 From: fredericroux at HOTMAIL.DE (Frederic Roux) Date: Fri, 4 Dec 2009 12:50:58 +0100 Subject: interpolated source activity values = NaN Message-ID: Hi everyone, I would like to use the values that correspond to the interpolated statistics at source level. The problem is that most of these values are NaNs, even tough I can visualize them with sourceplot. Here are the steps I am doing to compute these values: [signal1] = sourcegrandaverage(cfg,data); [signal2] = sourcegrandaverage(cfg,data); [Stats] = sourcestatistics(cfg,signal1,signal2);%the statistics used here is depsamplesT using fdr and clusterstatistics = maxsum [SourceInterpolatedSats] = sourceinterpolate(cfg,Stats,template_mri); This yields: SourceInterpolatedSats = inside: [91x109x91 logical] stat: [91x109x91 double] dim: [91 109 91] transform: [4x4 double] anatomy: [91x109x91 double] cfg: [1x1 struct] But when I try : SourceInterpolatedStats.stat([20 45 68]) = NaN. And this holds true for almost any index. Does anyone know if it's possible to access these values? Frederic _________________________________________________________________ http://redirect.gimas.net/?n=M0912xIWHM2 Hotmail - Mein E-Mail Anbieter ohne Kosten ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From ingrid.nieuwenhuis at FCDONDERS.RU.NL Fri Dec 4 13:21:17 2009 From: ingrid.nieuwenhuis at FCDONDERS.RU.NL (Ingrid Nieuwenhuis) Date: Fri, 4 Dec 2009 13:21:17 +0100 Subject: interpolated source activity values = NaN In-Reply-To: Message-ID: Hi Frederic, Probably the NaN's are the voxels outside the brain. The source estimate is only performed for voxels inside the brain, the voxels outside are put to NaN. In the field "inside" it is coded which voxels lay inside the brain. Try: SourceInterpolatedStats.stat(SourceInterpolatedStats.inside) This should give you the non-NaN values. Hope this helps, Ingrid _____ From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of Frederic Roux Sent: Friday, December 04, 2009 12:51 PM To: FIELDTRIP at NIC.SURFNET.NL Subject: [FIELDTRIP] interpolated source activity values = NaN Hi everyone, I would like to use the values that correspond to the interpolated statistics at source level. The problem is that most of these values are NaNs, even tough I can visualize them with sourceplot. Here are the steps I am doing to compute these values: [signal1] = sourcegrandaverage(cfg,data); [signal2] = sourcegrandaverage(cfg,data); [Stats] = sourcestatistics(cfg,signal1,signal2);%the statistics used here is depsamplesT using fdr and clusterstatistics = maxsum [SourceInterpolatedSats] = sourceinterpolate(cfg,Stats,template_mri); This yields: SourceInterpolatedSats = inside: [91x109x91 logical] stat: [91x109x91 double] dim: [91 109 91] transform: [4x4 double] anatomy: [91x109x91 double] cfg: [1x1 struct] But when I try : SourceInterpolatedStats.stat([20 45 68]) = NaN. And this holds true for almost any index. Does anyone know if it's possible to access these values? Frederic _____ Alle E-Mail-Adressen online auf einen Blick Ich will Hotmail! ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From fredericroux at HOTMAIL.DE Fri Dec 4 14:50:39 2009 From: fredericroux at HOTMAIL.DE (Frederic Roux) Date: Fri, 4 Dec 2009 14:50:39 +0100 Subject: interpolated source activity values = NaN In-Reply-To: <20091204122107.4BEE5EC09D@smtp.ru.nl> Message-ID: Hi Ingrid, thanks for the quick reply. I will try your suggestion but I am pretty much sure that the values I want to look at are inside the brain. My approach is the following: I want to indentify the voxels that show significant activation. So first I visualized my data with sourceplot and cfg.interactive = 'yes' and then I write down the indices of the voxels onto which I click. When I feed these indices into SourceInterpolatedStats.stat([x y z]) this returns me NaNs, even tough the voxel was clearly located inside the brain. Do you have any idea of why this happens? Frederic Date: Fri, 4 Dec 2009 13:21:17 +0100 From: ingrid.nieuwenhuis at FCDONDERS.RU.NL Subject: Re: [FIELDTRIP] interpolated source activity values = NaN To: FIELDTRIP at NIC.SURFNET.NL Hi Frederic, Probably the NaN’s are the voxels outside the brain. The source estimate is only performed for voxels inside the brain, the voxels outside are put to NaN. In the field “inside” it is coded which voxels lay inside the brain. Try: SourceInterpolatedStats.stat(SourceInterpolatedStats.inside) This should give you the non-NaN values. Hope this helps, Ingrid From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of Frederic Roux Sent: Friday, December 04, 2009 12:51 PM To: FIELDTRIP at NIC.SURFNET.NL Subject: [FIELDTRIP] interpolated source activity values = NaN Hi everyone, I would like to use the values that correspond to the interpolated statistics at source level. The problem is that most of these values are NaNs, even tough I can visualize them with sourceplot. Here are the steps I am doing to compute these values: [signal1] = sourcegrandaverage(cfg,data); [signal2] = sourcegrandaverage(cfg,data); [Stats] = sourcestatistics(cfg,signal1,signal2);%the statistics used here is depsamplesT using fdr and clusterstatistics = maxsum [SourceInterpolatedSats] = sourceinterpolate(cfg,Stats,template_mri); This yields: SourceInterpolatedSats = inside: [91x109x91 logical] stat: [91x109x91 double] dim: [91 109 91] transform: [4x4 double] anatomy: [91x109x91 double] cfg: [1x1 struct] But when I try : SourceInterpolatedStats.stat([20 45 68]) = NaN. And this holds true for almost any index. Does anyone know if it's possible to access these values? Frederic Alle E-Mail-Adressen online auf einen Blick Ich will Hotmail! ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ _________________________________________________________________ http://redirect.gimas.net/?n=M0912xXMasGreetings2 Nie mehr um Weihnachtsgrüße verlegen: mit tollen Weihnachts-E-Mails ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From ingrid.nieuwenhuis at FCDONDERS.RU.NL Fri Dec 4 14:58:23 2009 From: ingrid.nieuwenhuis at FCDONDERS.RU.NL (Ingrid Nieuwenhuis) Date: Fri, 4 Dec 2009 14:58:23 +0100 Subject: interpolated source activity values = NaN In-Reply-To: Message-ID: Dear Frederic, Could it be that you wrote down the indices of the voxels before interpolating? Since the voxels before interpolating do not match anymore after interpolating onto the template_mri. Best, Ingrid _____ From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of Frederic Roux Sent: Friday, December 04, 2009 2:51 PM To: FIELDTRIP at NIC.SURFNET.NL Subject: Re: [FIELDTRIP] interpolated source activity values = NaN Hi Ingrid, thanks for the quick reply. I will try your suggestion but I am pretty much sure that the values I want to look at are inside the brain. My approach is the following: I want to indentify the voxels that show significant activation. So first I visualized my data with sourceplot and cfg.interactive = 'yes' and then I write down the indices of the voxels onto which I click. When I feed these indices into SourceInterpolatedStats.stat([x y z]) this returns me NaNs, even tough the voxel was clearly located inside the brain. Do you have any idea of why this happens? Frederic _____ Date: Fri, 4 Dec 2009 13:21:17 +0100 From: ingrid.nieuwenhuis at FCDONDERS.RU.NL Subject: Re: [FIELDTRIP] interpolated source activity values = NaN To: FIELDTRIP at NIC.SURFNET.NL Hi Frederic, Probably the NaN’s are the voxels outside the brain. The source estimate is only performed for voxels inside the brain, the voxels outside are put to NaN. In the field “inside” it is coded which voxels lay inside the brain. Try: SourceInterpolatedStats.stat(SourceInterpolatedStats.inside) This should give you the non-NaN values. Hope this helps, Ingrid _____ From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of Frederic Roux Sent: Friday, December 04, 2009 12:51 PM To: FIELDTRIP at NIC.SURFNET.NL Subject: [FIELDTRIP] interpolated source activity values = NaN Hi everyone, I would like to use the values that correspond to the interpolated statistics at source level. The problem is that most of these values are NaNs, even tough I can visualize them with sourceplot. Here are the steps I am doing to compute these values: [signal1] = sourcegrandaverage(cfg,data); [signal2] = sourcegrandaverage(cfg,data); [Stats] = sourcestatistics(cfg,signal1,signal2);%the statistics used here is depsamplesT using fdr and clusterstatistics = maxsum [SourceInterpolatedSats] = sourceinterpolate(cfg,Stats,template_mri); This yields: SourceInterpolatedSats = inside: [91x109x91 logical] stat: [91x109x91 double] dim: [91 109 91] transform: [4x4 double] anatomy: [91x109x91 double] cfg: [1x1 struct] But when I try : SourceInterpolatedStats.stat([20 45 68]) = NaN. And this holds true for almost any index. Does anyone know if it's possible to access these values? Frederic _____ Alle E-Mail-Adressen online auf einen Blick Ich will Hotmail! ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ _____ Nie mehr um Weihnachtsgrüße verlegen: mit tollen Weihnachts-E-Mails ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From fredericroux at HOTMAIL.DE Fri Dec 4 15:06:10 2009 From: fredericroux at HOTMAIL.DE (Frederic Roux) Date: Fri, 4 Dec 2009 15:06:10 +0100 Subject: interpolated source activity values = NaN In-Reply-To: <20091204135813.EF177EC2BD@smtp.ru.nl> Message-ID: Actually I don't think so. I first computed the sourcestatistics. Then I interpolated the Stats and visualized them with sourceplot and cfg.interactive = yes. Frederic Date: Fri, 4 Dec 2009 14:58:23 +0100 From: ingrid.nieuwenhuis at FCDONDERS.RU.NL Subject: Re: [FIELDTRIP] interpolated source activity values = NaN To: FIELDTRIP at NIC.SURFNET.NL Dear Frederic, Could it be that you wrote down the indices of the voxels before interpolating? Since the voxels before interpolating do not match anymore after interpolating onto the template_mri. Best, Ingrid From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of Frederic Roux Sent: Friday, December 04, 2009 2:51 PM To: FIELDTRIP at NIC.SURFNET.NL Subject: Re: [FIELDTRIP] interpolated source activity values = NaN Hi Ingrid, thanks for the quick reply. I will try your suggestion but I am pretty much sure that the values I want to look at are inside the brain. My approach is the following: I want to indentify the voxels that show significant activation. So first I visualized my data with sourceplot and cfg.interactive = 'yes' and then I write down the indices of the voxels onto which I click. When I feed these indices into SourceInterpolatedStats.stat([x y z]) this returns me NaNs, even tough the voxel was clearly located inside the brain. Do you have any idea of why this happens? Frederic Date: Fri, 4 Dec 2009 13:21:17 +0100 From: ingrid.nieuwenhuis at FCDONDERS.RU.NL Subject: Re: [FIELDTRIP] interpolated source activity values = NaN To: FIELDTRIP at NIC.SURFNET.NL Hi Frederic, Probably the NaN’s are the voxels outside the brain. The source estimate is only performed for voxels inside the brain, the voxels outside are put to NaN. In the field “inside” it is coded which voxels lay inside the brain. Try: SourceInterpolatedStats.stat(SourceInterpolatedStats.inside) This should give you the non-NaN values. Hope this helps, Ingrid From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of Frederic Roux Sent: Friday, December 04, 2009 12:51 PM To: FIELDTRIP at NIC.SURFNET.NL Subject: [FIELDTRIP] interpolated source activity values = NaN Hi everyone, I would like to use the values that correspond to the interpolated statistics at source level. The problem is that most of these values are NaNs, even tough I can visualize them with sourceplot. Here are the steps I am doing to compute these values: [signal1] = sourcegrandaverage(cfg,data); [signal2] = sourcegrandaverage(cfg,data); [Stats] = sourcestatistics(cfg,signal1,signal2);%the statistics used here is depsamplesT using fdr and clusterstatistics = maxsum [SourceInterpolatedSats] = sourceinterpolate(cfg,Stats,template_mri); This yields: SourceInterpolatedSats = inside: [91x109x91 logical] stat: [91x109x91 double] dim: [91 109 91] transform: [4x4 double] anatomy: [91x109x91 double] cfg: [1x1 struct] But when I try : SourceInterpolatedStats.stat([20 45 68]) = NaN. And this holds true for almost any index. Does anyone know if it's possible to access these values? Frederic Alle E-Mail-Adressen online auf einen Blick Ich will Hotmail! ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ Nie mehr um Weihnachtsgrüße verlegen: mit tollen Weihnachts-E-Mails ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ _________________________________________________________________ http://redirect.gimas.net/?n=M0912xXMasGreetings2 Nie mehr um Weihnachtsgrüße verlegen: mit tollen Weihnachts-E-Mails ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From fredericroux at HOTMAIL.DE Fri Dec 4 15:17:06 2009 From: fredericroux at HOTMAIL.DE (Frederic Roux) Date: Fri, 4 Dec 2009 15:17:06 +0100 Subject: problem solved Message-ID: The solution to my problem is: SourceInterpolatedSats(Voxel) and not SourceInterpolatedStats([x y z]). Thanks for helping. Frederic _________________________________________________________________ http://redirect.gimas.net/?n=M0912xIE2 Internet Explorer aktualisieren – sicher im Internet! ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From lhunt at FMRIB.OX.AC.UK Sun Dec 6 23:47:58 2009 From: lhunt at FMRIB.OX.AC.UK (Laurence Hunt) Date: Sun, 6 Dec 2009 22:47:58 +0000 Subject: minor problem loading fiff file In-Reply-To: <72E993C35FB11743B79FF9286E5B6D8BA2E4F4@Mail2-UKD.VMED.UKD> Message-ID: Hi Jan, Thanks for the example file. It looks like a change was made to read_header after I initally wrote it, which was to take the first_samp field from fiff_setup_read_raw (called in read_header), and make this negative rather than positive (line 817 of read_header). This is causing read_data to crash. @Robert, could we either change read_header back, or change read_data with the amendment suggested by Jan? Basically first_samp (returned by fiff_setup_read_raw) can be positive or negative, I think depending upon how the recording is made - but more positive numbers mean further forward in time, and more negative numbers further backward. If fieldtrip typically makes nSamplesPre always increase positively as we go backwards in time, then we would need to make the change Jan suggested in line 691 of read_data (and anywhere else that depends on nSamplesPre in the neuromag_mne code). Cheers, Laurence =========================================== Laurence Hunt, DPhil Student Centre for Functional MRI of the Brain (FMRIB), University of Oxford lhunt at fmrib.ox.ac.uk Phone: (+44)1865-(2)22738 =========================================== On 4 Dec 2009, at 12:24, wrote: > Hi Laurence, > > I did not upload my data to the server but I am sending you the > first few seconds of my file with this mail. For me the error occurs > with this file, too. With the changes I have suggested everything > seems fine. > > Best, > > Jan > > ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From e.glerean at GMAIL.COM Tue Dec 8 13:10:54 2009 From: e.glerean at GMAIL.COM (Enrico Glerean) Date: Tue, 8 Dec 2009 14:10:54 +0200 Subject: private/senslabel.m missing on latest builds? Message-ID: Hello developers of FT, hopefully this is the best place for these kind of notifications. In the latest builds of FT the function private/senslabel.m is not there anymore. This throws errors such: ??? Undefined function or method 'senslabel' for input arguments of type 'char'. Error in ==> channelselection at 96 label1020 = senslabel('eeg1020'); % use external helper function Error in ==> preprocessing at 306 cfg.channel = channelselection(cfg.channel, hdr.label); Error in ==> ft_test1 at 9 dataPrepro = preprocessing(cfg1); (This error was obtained by running a basic preprocessing script as in http://fieldtrip.fcdonders.nl/tutorial/introduction using Subject01.ds from your tutorial data). Please let me know when the function is back. thanks -- Enrico Glerean, MSc Researcher Department of Biomedical Engineering and Computational Science Helsinki University of Technology ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From r.oostenveld at FCDONDERS.RU.NL Tue Dec 8 21:49:34 2009 From: r.oostenveld at FCDONDERS.RU.NL (Robert Oostenveld) Date: Tue, 8 Dec 2009 21:49:34 +0100 Subject: private/senslabel.m missing on latest builds? In-Reply-To: Message-ID: Dear Enrico, The senslabel function is now located elsewhere, in >> which senslabel.m /Users/robert/matlab/fieldtrip/forwinv/senslabel.m We try to avoid replicating functions, and this function (which used to be private) is now part of the public API of the forwinv module. That means that it does not have to be replicated any more in fieldtrip/private. If channelselection does not find it, then it seems that fieldtripdefs (which is called at the begin of channelselection) did not add the fieldtrip/forwinv directory correctly to your path. Could you try "clear all" and then "fieldtripdefs" and then "which senslabel"? Best regards, Robert ----------------------------------------------------------- Robert Oostenveld, PhD Senior Researcher Donders Institute for Brain, Cognition and Behaviour Centre for Cognitive Neuroimaging Radboud University Nijmegen tel.: +31 (0)24 3619695 e-mail: r.oostenveld at donders.ru.nl web: http://www.ru.nl/neuroimaging skype: r.oostenveld ----------------------------------------------------------- On 8 Dec 2009, at 13:10, Enrico Glerean wrote: > Hello developers of FT, > > hopefully this is the best place for these kind of notifications. In > the latest builds of FT the function private/senslabel.m > is not there anymore. This throws errors such: > > ??? Undefined function or method 'senslabel' for input arguments of type 'char'. > > Error in ==> channelselection at 96 > label1020 = senslabel('eeg1020'); % use external helper function > > Error in ==> preprocessing at 306 > cfg.channel = channelselection(cfg.channel, hdr.label); > > Error in ==> ft_test1 at 9 > dataPrepro = preprocessing(cfg1); > > > (This error was obtained by running a basic preprocessing script as in > http://fieldtrip.fcdonders.nl/tutorial/introduction using Subject01.ds > from your tutorial data). > > > Please let me know when the function is back. > thanks > > -- > Enrico Glerean, MSc > Researcher > Department of Biomedical Engineering and Computational Science > Helsinki University of Technology > > ---------------------------------- > The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. > ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From e.glerean at GMAIL.COM Wed Dec 9 08:40:55 2009 From: e.glerean at GMAIL.COM (Enrico Glerean) Date: Wed, 9 Dec 2009 09:40:55 +0200 Subject: private/senslabel.m missing on latest builds? In-Reply-To: Message-ID: Hello Robert thanks for this. There was a path conflict with EEGLAB (which also had an entry for the forwinv toolbox in its external/fieldtrip folder), hence the hastoolbox('forwinv', 1, 1); command on fieldtripdefs did not add the correct forwinv. Now everything seems fine again. Best -- Enrico Glerean, MSc Researcher Department of Biomedical Engineering and Computational Science Helsinki University of Technology 2009/12/8 Robert Oostenveld : > Dear Enrico, > The senslabel function is now located elsewhere, in >>> which senslabel.m > /Users/robert/matlab/fieldtrip/forwinv/senslabel.m > We try to avoid replicating functions, and this function (which used to be > private) is now part of the public API of the forwinv module. That means > that it does not have to be replicated any more in fieldtrip/private. > If channelselection does not find it, then it seems that fieldtripdefs > (which is called at the begin of channelselection) did not add the > fieldtrip/forwinv directory correctly to your path. Could you try "clear > all" and then "fieldtripdefs" and then "which senslabel"? > Best regards, > Robert > ----------------------------------------------------------- > Robert Oostenveld, PhD > Senior Researcher > Donders Institute for Brain, Cognition and Behaviour > Centre for Cognitive Neuroimaging > Radboud University Nijmegen > tel.: +31 (0)24 3619695 > e-mail: r.oostenveld at donders.ru.nl > web: http://www.ru.nl/neuroimaging > skype: r.oostenveld > ----------------------------------------------------------- > > On 8 Dec 2009, at 13:10, Enrico Glerean wrote: > > Hello developers of FT, > > hopefully this is the best place for these kind of notifications. In > the latest builds of FT the function private/senslabel.m > is not there anymore. This throws errors such: > > ??? Undefined function or method 'senslabel' for input arguments of type > 'char'. > > Error in ==> channelselection at 96 > label1020 = senslabel('eeg1020'); % use external helper function > > Error in ==> preprocessing at 306 >  cfg.channel = channelselection(cfg.channel, hdr.label); > > Error in ==> ft_test1 at 9 > dataPrepro   = preprocessing(cfg1); > > > (This error was obtained by running a basic preprocessing script as in > http://fieldtrip.fcdonders.nl/tutorial/introduction using Subject01.ds > from your tutorial data). > > > Please let me know when the function is back. > thanks > > -- > Enrico Glerean, MSc > Researcher > Department of Biomedical Engineering and Computational Science > Helsinki University of Technology > > ---------------------------------- > The aim of this list is to facilitate the discussion between users of the > FieldTrip  toolbox, to share experiences and to discuss new ideas for MEG > and EEG analysis. See also > http://listserv.surfnet.nl/archives/fieldtrip.html and > http://www.ru.nl/neuroimaging/fieldtrip. > > > ---------------------------------- > > The aim of this list is to facilitate the discussion between users of the > FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and > EEG analysis. > > http://listserv.surfnet.nl/archives/fieldtrip.html > > http://www.ru.nl/fcdonders/fieldtrip/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From d.gupta at DONDERS.RU.NL Wed Dec 9 12:09:23 2009 From: d.gupta at DONDERS.RU.NL (Disha Gupta) Date: Wed, 9 Dec 2009 12:09:23 +0100 Subject: Common spatial patterns Message-ID: I was looking for documentation/tutorial for CSP in fieldtrip. I can see some documentation in the code at Files\MATLAB\R2008b\work\fieldtrip-20091114\classification\toolboxes\herman\csp\ If there is a fieldtrip tutorial I am missing out on, it will be very useful to know. Disha ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From Erin.Oakman at NYUMC.ORG Thu Dec 10 22:48:29 2009 From: Erin.Oakman at NYUMC.ORG (Oakman, Erin) Date: Thu, 10 Dec 2009 16:48:29 -0500 Subject: problem with freqstatistics Message-ID: Hi, I am following the cluster-based statistics tutorial called cluster_permutation_freq, "within trial experiments." When defining "baseline" and "activation" times with 1 subject, I have an error using redefinetrial to choose the nonoverlapping and equal length trials. For example, % redefine cfg = []; cfg.toilim = [-0.5 0]; data_baseline = redefinetrial(cfg, data); ??? Error using ==> redefinetrial at 66 the trial definition is inconsistent with the data Specifically, there is no trl field in my data. Somehow the trl field was lost after channelrepair and appenddata. However, it is possible to redefine the activation and baseline time manually. Then I make the time-frequency files on baseline and activation, and test with freqstatistics: %freqstatistics with cluster cfg=[]; cfg.method='montecarlo'; cfg.statistic= 'actvsblT'; cfg.parameter='powspctrm'; cfg.channel='all'; cfg.avgoverchan='no'; cfg.latency='all'; %[0.05 0.45]; cfg.avgovertime='no'; cfg.frequency=[39 41]; %'all'; cfg.avgoverfreq='yes'; cfg.correctm='cluster'; cfg.clusteralpha=0.05; cfg.clusterstatistic='maxsum'; cfg.elecfile='/home/eo/science/layout/biosemi.sfp'; cfg.neighbourdist=2.5; % cfg.minnbchan=2; %default=0 cfg.tail=0; %default=0 cfg.alpha=0.05; cfg.numrandomization=500; stat = freqstatistics(cfg, data_baseline, data_activation); ??? Undefined variable "data" or class "data.biol". Error in ==> prepare_design at 85 nrepl=size(data.biol,1); Error in ==> statistics_wrapper at 233 [cfg] = prepare_design(cfg); Error in ==> freqstatistics at 89 [stat, cfg] = statistics_wrapper(cfg, varargin{:}); The powspctrm field in data_baseline.powspctrm and data_activation.powspctrm is 4D (rptxchanxfreqxtime), and the rpt,freq,time, and label fields have the same dimensions. Do I have to use redefinetrial before freqanalysis? Any advice is appreciated. Erin ------------------------------------------------------------ This email message, including any attachments, is for the sole use of the intended recipient(s) and may contain information that is proprietary, confidential, and exempt from disclosure under applicable law. Any unauthorized review, use, disclosure, or distribution is prohibited. If you have received this email in error please notify the sender by return email and delete the original message. Please note, the recipient should check this email and any attachments for the presence of viruses. The organization accepts no liability for any damage caused by any virus transmitted by this email. ================================= ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From a.maye at UKE.DE Fri Dec 11 14:58:11 2009 From: a.maye at UKE.DE (Alexander Maye) Date: Fri, 11 Dec 2009 14:58:11 +0100 Subject: Warning: nanmean Message-ID: Dear List! If you install fieldtrip by adding the directory with subfolders, then read on. I just noticed that my scripts were using fieldtrip's nanmean function from the classification/utilities directory, which is not doing what it promises: Instead of ignoring NaNs it considers them as zeros. While this might make sense for the classification utilities, for most of the time it does not. If Matlab searches the fieldtrip folder only (no subfolders thereof), then the correct nanmean from the statistics toolbox is used. I couldn't find any instructions if the installation directory should be added to the Matlab path with or without the subfolders, so everyone might want to check which nanmean you use. Good luck, ALEX. -- Pflichtangaben gem�� Gesetz �ber elektronische Handelsregister und Genossenschaftsregister sowie das Unternehmensregister (EHUG): Universit�tsklinikum Hamburg-Eppendorf K�rperschaft des �ffentlichen Rechts Gerichtsstand: Hamburg Vorstandsmitglieder: Prof. Dr. J�rg F. Debatin (Vorsitzender) Dr. Alexander Kirstein Prof. Dr. Dr. Uwe Koch-Gromus ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From r.oostenveld at FCDONDERS.RU.NL Mon Dec 14 15:52:50 2009 From: r.oostenveld at FCDONDERS.RU.NL (Robert Oostenveld) Date: Mon, 14 Dec 2009 15:52:50 +0100 Subject: Warning: nanmean In-Reply-To: <200912111458.12036.a.maye@uke.de> Message-ID: Dear Alex, I also detected the buggy nanmean in the classification/utilities directory. They were fixed last week by Marcel and now contain the correct functions with a slightly different name. Please update your fieldtrip version to the most recent one. About the directory adding: please see http://fieldtrip.fcdonders.nl/faq/should_i_add_fieldtrip_with_all_subdirectories_to_my_matlab_path (which I just created). best regards, Robert On 11 Dec 2009, at 14:58, Alexander Maye wrote: > Dear List! > > If you install fieldtrip by adding the directory with subfolders, > then read > on. I just noticed that my scripts were using fieldtrip's nanmean > function > from the classification/utilities directory, which is not doing what > it > promises: Instead of ignoring NaNs it considers them as zeros. While > this > might make sense for the classification utilities, for most of the > time it > does not. > > If Matlab searches the fieldtrip folder only (no subfolders > thereof), then the > correct nanmean from the statistics toolbox is used. I couldn't find > any > instructions if the installation directory should be added to the > Matlab path > with or without the subfolders, so everyone might want to check which > nanmean you use. > > Good luck, > > ALEX. > > > > > > -- > Pflichtangaben gemäß Gesetz über elektronische Handelsregister und > Genossenschaftsregister sowie das Unternehmensregister (EHUG): > > Universitätsklinikum Hamburg-Eppendorf > Körperschaft des öffentlichen Rechts > Gerichtsstand: Hamburg > > Vorstandsmitglieder: > Prof. Dr. Jörg F. Debatin (Vorsitzender) > Dr. Alexander Kirstein > Prof. Dr. Dr. Uwe Koch-Gromus > > ---------------------------------- > The aim of this list is to facilitate the discussion between users > of the FieldTrip toolbox, to share experiences and to discuss new > ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html > and http://www.ru.nl/neuroimaging/fieldtrip. > ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From r.oostenveld at FCDONDERS.RU.NL Wed Dec 16 11:06:40 2009 From: r.oostenveld at FCDONDERS.RU.NL (Robert Oostenveld) Date: Wed, 16 Dec 2009 11:06:40 +0100 Subject: important: all fieldtrip functions will be renamed to ft_xxx Message-ID: Dear FieldTrip users As some of you may know, Matlab (and specifically the older versions that we still support) does not have a good way of separating functions in different toolboxes from each other. The fieldtrip version of preprocessing (or read_data) might be completely different from a function with the same name in another toolbox. That is not a problem for some of the unusual function names, but some function names like "preprocessing" are very generic and therefore likely to be used in completely different contexts. After repeated discussion with the developers of the SPM Matlab toolbox, we have decided to start adopting the same naming scheme that SPM is using. That naming scheme consists of prefixing the function name with the name of the toolbox, e.g. spm_contrasts. The prefix that FieldTrip will use is "ft_". So that means that the FieldTrip preprocessing function will be renamed into ft_preprocessing, sourceanalysis will become ft_sourceanalysis, freqanalysis will become ft_freqanalysis, etc. This will affect all publicly available FieldTrip functions, i.e. the main functions that you are using. The advantage of this change in function names is that it further facilitates the already very good collaboration of the FieldTrip project with other EEG/MEG method development groups, such as SPM, EEGLAB, BrainStorm and others. Note that this is not an easy choice to make and we have carefully considered the consequences. Of course all users have existing scripts that use the old function names. We will do our utmost best to ensure that your old scripts will remain functional, also with new versions of the fieldtrip toolbox. To make this possible, we will provide backward compatibility wrappers, e.g. there will be a preprocessing.m function that calls ft_preprocessing.m and the likes. Not only the existing analysis scripts are affected, but also the documentation on the fieldtrip wiki will have to be updated. Furthermore, fieldtrip functions often call each other, which means that inside the fieldtrip functions the function names also have to be changed. On the short time scale, we will provide backward compatibility wrapper functions. On the medium time scale, we will ensure that the fieldtrip code and documentation is internally consistent. On the long run everyone (which includes you!) should adopt the new function names. Please start using these new function names in your scripts and in your derived functions as soon as possible. At a certain point in the future, the backward compatibility to the old/current function names will be removed from the fieldtrip release, so by that time all of your scripts should only be using the new function names, otherwise they won't work any more. The backward compatibility will be ensured throughout 2010, i.e. for a full year. Usually we are able to maintain backward compatibility for a much longer time, so probably you should not have to worry about this too much. best regards, Robert ----------------------------------------------------------- Robert Oostenveld, PhD Senior Researcher Donders Institute for Brain, Cognition and Behaviour Centre for Cognitive Neuroimaging Radboud University Nijmegen tel.: +31 (0)24 3619695 e-mail: r.oostenveld at donders.ru.nl web: http://www.ru.nl/neuroimaging skype: r.oostenveld ----------------------------------------------------------- ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From r.oostenveld at FCDONDERS.RU.NL Wed Dec 16 12:11:21 2009 From: r.oostenveld at FCDONDERS.RU.NL (Robert Oostenveld) Date: Wed, 16 Dec 2009 12:11:21 +0100 Subject: important: all fieldtrip functions will be renamed to ft_xxx In-Reply-To: <057247EE-D280-45B9-8DD9-D93865220423@fcdonders.ru.nl> Message-ID: Dear fieldtrip users One more note: for the backward compatibility to work, you should add the fieldtrip/compat directory to your path. Alternatively (and preferably) you should execute the fieldtrip/fieldtripdefs.m function. The fieldtripdefs function sets the default cfg options and also ensures that all path settings are correct. best regards, Robert On 16 Dec 2009, at 11:06, Robert Oostenveld wrote: > Dear FieldTrip users > > As some of you may know, Matlab (and specifically the older versions > that we still support) does not have a good way of separating > functions in different toolboxes from each other. The fieldtrip > version of preprocessing (or read_data) might be completely > different from a function with the same name in another toolbox. > That is not a problem for some of the unusual function names, but > some function names like "preprocessing" are very generic and > therefore likely to be used in completely different contexts. > > After repeated discussion with the developers of the SPM Matlab > toolbox, we have decided to start adopting the same naming scheme > that SPM is using. That naming scheme consists of prefixing the > function name with the name of the toolbox, e.g. spm_contrasts. The > prefix that FieldTrip will use is "ft_". So that means that the > FieldTrip preprocessing function will be renamed into > ft_preprocessing, sourceanalysis will become ft_sourceanalysis, > freqanalysis will become ft_freqanalysis, etc. This will affect all > publicly available FieldTrip functions, i.e. the main functions that > you are using. The advantage of this change in function names is > that it further facilitates the already very good collaboration of > the FieldTrip project with other EEG/MEG method development groups, > such as SPM, EEGLAB, BrainStorm and others. > > Note that this is not an easy choice to make and we have carefully > considered the consequences. Of course all users have existing > scripts that use the old function names. We will do our utmost best > to ensure that your old scripts will remain functional, also with > new versions of the fieldtrip toolbox. To make this possible, we > will provide backward compatibility wrappers, e.g. there will be a > preprocessing.m function that calls ft_preprocessing.m and the > likes. Not only the existing analysis scripts are affected, but also > the documentation on the fieldtrip wiki will have to be updated. > Furthermore, fieldtrip functions often call each other, which means > that inside the fieldtrip functions the function names also have to > be changed. > > On the short time scale, we will provide backward compatibility > wrapper functions. On the medium time scale, we will ensure that the > fieldtrip code and documentation is internally consistent. On the > long run everyone (which includes you!) should adopt the new > function names. Please start using these new function names in your > scripts and in your derived functions as soon as possible. At a > certain point in the future, the backward compatibility to the old/ > current function names will be removed from the fieldtrip release, > so by that time all of your scripts should only be using the new > function names, otherwise they won't work any more. The backward > compatibility will be ensured throughout 2010, i.e. for a full year. > Usually we are able to maintain backward compatibility for a much > longer time, so probably you should not have to worry about this too > much. > > best regards, > Robert > > > > ----------------------------------------------------------- > Robert Oostenveld, PhD > Senior Researcher > Donders Institute for Brain, Cognition and Behaviour > Centre for Cognitive Neuroimaging > Radboud University Nijmegen > tel.: +31 (0)24 3619695 > e-mail: r.oostenveld at donders.ru.nl > web: http://www.ru.nl/neuroimaging > skype: r.oostenveld > ----------------------------------------------------------- > > ---------------------------------- > The aim of this list is to facilitate the discussion between users > of the FieldTrip toolbox, to share experiences and to discuss new > ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html > and http://www.ru.nl/neuroimaging/fieldtrip. > ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From anette.giani at TUEBINGEN.MPG.DE Thu Dec 17 09:47:33 2009 From: anette.giani at TUEBINGEN.MPG.DE (Anette Giani) Date: Thu, 17 Dec 2009 09:47:33 +0100 Subject: A newbie's question on Fourier using freqanalysis_mtmfft Message-ID: Dear all, I am a beginner on MEG and I have some basic questions on Fourier transformation using the function freqanalysis_mtmfft. It would be great if you could help me! We are interested in Steady State Responses. Therefore we recorded data 60 seconds trials. To transform the time domain into a frequency spectrum we used the function freqanalysis_mtmfft. However, I am not sure which value cfg.tapsmofrq. Since we would like to have the highest frequency resolution possible I set cfg.tapsmofrq to 0.25; the lowest value possible. Do you think that was a good choice? Further, does this value mean that our lowest possible frequency resolution would be 0.25? If that was the case, how could I avoid all smoothing? Second, do you think that it would be useful to pad the signal with zeros to artificially increase the frequency resolution? I guess this could be done using cfg.pad? Lastly, an even more general question: What do you think would be handier: (1) Compute the frequency spectrum over 60 seconds, to get a high frequency resolution or (2) to cut the signal into e.g. 4 second pieces and to average all spectra to increase the signal to noise ratio? Thanks a lot in advance for your help, Anette ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From lulswinnik at GMAIL.COM Thu Dec 17 16:00:32 2009 From: lulswinnik at GMAIL.COM (Katya Vinnik) Date: Thu, 17 Dec 2009 16:00:32 +0100 Subject: A newbie's question on Fourier using freqanalysis_mtmfft In-Reply-To: <-1763973191626696207@unknownmsgid> Message-ID: Dear Anette, If you are looking at the steady state response and are interested in its power only, you should not try to achieve the highest frequency resolution, but rather adjust the parameters (sampling rate and NFFT) to place your SSR frequency exactly in the center of the frequency bin, which may be rather large (around 1 hz). In this way you'd be sure you're capturing all the power coming from from the SSR and will be able to compare this frequency bin between conditions or to the nearby frequency bins. Katya 2009/12/17 Anette Giani > Dear all, > > I am a beginner on MEG and I have some basic questions on Fourier > transformation using the function freqanalysis_mtmfft. It would be great > if you could help me! > > > > We are interested in Steady State Responses. Therefore we recorded data 60 > seconds trials. > > To transform the time domain into a frequency spectrum we used the function > freqanalysis_mtmfft. However, I am not sure which value cfg.tapsmofrq. > Since we would like to have the highest frequency resolution possible I set > cfg.tapsmofrq to 0.25; the lowest value possible. Do you think that was a > good choice? Further, does this value mean that our lowest possible > frequency resolution would be 0.25? If that was the case, how could I avoid > all smoothing? > > > > Second, do you think that it would be useful to pad the signal with zeros > to artificially increase the frequency resolution? I guess this could be > done using cfg.pad? > > > > Lastly, an even more general question: What do you think would be handier: > (1) Compute the frequency spectrum over 60 seconds, to get a high frequency > resolution or (2) to cut the signal into e.g. 4 second pieces and to average > all spectra to increase the signal to noise ratio? > > > > Thanks a lot in advance for your help, > > Anette > > > > ---------------------------------- > > The aim of this list is to facilitate the discussion between users of the > FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and > EEG analysis. > > http://listserv.surfnet.nl/archives/fieldtrip.html > > http://www.ru.nl/fcdonders/fieldtrip/ > -- Ekaterina Vinnik, MD, PhD Tactile Perception and Learning Lab Cognitive neuroscience sector, SISSA, Trieste, Italy +393347032225 lulswinnik at gmail.com ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From ingrid.nieuwenhuis at FCDONDERS.RU.NL Thu Dec 17 16:12:37 2009 From: ingrid.nieuwenhuis at FCDONDERS.RU.NL (Ingrid Nieuwenhuis) Date: Thu, 17 Dec 2009 16:12:37 +0100 Subject: A newbie's question on Fourier using freqanalysis_mtmfft In-Reply-To: <000001ca7ef5$92ef6410$b8ce2c30$%giani@tuebingen.mpg.de> Message-ID: Dear Anette, Cfg.tapsmofrq is an option for multitaper analysis (cfg.taper = 'dpss'), which might not be what you want if you want high frequency resolution. I would recommend looking at the tutorial "Time-frequency analysis using Hanning window, multitapers and wavelets" http://fieldtrip.fcdonders.nl/tutorial/timefrequencyanalysis there you can read about the differences between hanning taper and multitapers. Hope this helps a bit Best Ingrid _____ From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of Anette Giani Sent: Thursday, December 17, 2009 9:48 AM To: FIELDTRIP at NIC.SURFNET.NL Subject: [FIELDTRIP] A newbie's question on Fourier using freqanalysis_mtmfft Dear all, I am a beginner on MEG and I have some basic questions on Fourier transformation using the function freqanalysis_mtmfft. It would be great if you could help me! We are interested in Steady State Responses. Therefore we recorded data 60 seconds trials. To transform the time domain into a frequency spectrum we used the function freqanalysis_mtmfft. However, I am not sure which value cfg.tapsmofrq. Since we would like to have the highest frequency resolution possible I set cfg.tapsmofrq to 0.25; the lowest value possible. Do you think that was a good choice? Further, does this value mean that our lowest possible frequency resolution would be 0.25? If that was the case, how could I avoid all smoothing? Second, do you think that it would be useful to pad the signal with zeros to artificially increase the frequency resolution? I guess this could be done using cfg.pad? Lastly, an even more general question: What do you think would be handier: (1) Compute the frequency spectrum over 60 seconds, to get a high frequency resolution or (2) to cut the signal into e.g. 4 second pieces and to average all spectra to increase the signal to noise ratio? Thanks a lot in advance for your help, Anette ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From justin.ales at GMAIL.COM Thu Dec 17 17:15:49 2009 From: justin.ales at GMAIL.COM (Justin Ales) Date: Thu, 17 Dec 2009 08:15:49 -0800 Subject: A newbie's question on Fourier using freqanalysis_mtmfft In-Reply-To: <-1763973191626696207@unknownmsgid> Message-ID: In my experience with steady-state visual evoked potentials using time-frequency analysis with just power works poorly. This is because it doesn't average out phase incoherent noise sources, and the steady-state response is a driven coherent signal. We usually cut our data into 2 second long "trials", to get .5 Hz resolution, and then coherently average(phase locked) fourier components over these epochs. Bach & Meigen have written a good primer on analysis choices, such as windowing and zeropadding, for steady-state potentials: http://www.uniklinik-freiburg.de/augenklinik/live/homede/mit/bach/ops/fourier_en.html Justin Ales Smith-Kettlewell Eye Research Institute On Thu, Dec 17, 2009 at 12:47 AM, Anette Giani wrote: > Dear all, > > I am a beginner on MEG and I have some basic questions on Fourier > transformation using the function freqanalysis_mtmfft. It would be great if > you could help me! > > > > We are interested in Steady State Responses. Therefore we recorded data 60 > seconds trials. > > To transform the time domain into a frequency spectrum we used the function > freqanalysis_mtmfft. However, I am not sure which value cfg.tapsmofrq. Since > we would like to have the highest frequency resolution possible I set > cfg.tapsmofrq to 0.25; the lowest value possible. Do you think that was a > good choice? Further, does this value mean that our lowest possible > frequency resolution would be 0.25? If that was the case, how could I avoid > all smoothing? > > > > Second, do you think that it would be useful to pad the signal with zeros to > artificially increase the frequency resolution? I guess this could be done > using cfg.pad? > > > > Lastly, an even more general question: What do you think would be handier: > (1) Compute the frequency spectrum over 60 seconds, to get a high frequency > resolution or (2) to cut the signal into e.g. 4 second pieces and to average > all spectra to increase the signal to noise ratio? > > > > Thanks a lot in advance for your help, > >  Anette > > > > ---------------------------------- > > The aim of this list is to facilitate the discussion between users of the > FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and > EEG analysis. > > http://listserv.surfnet.nl/archives/fieldtrip.html > > http://www.ru.nl/fcdonders/fieldtrip/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From michael.wibral at WEB.DE Fri Dec 18 11:12:50 2009 From: michael.wibral at WEB.DE (Michael Wibral) Date: Fri, 18 Dec 2009 11:12:50 +0100 Subject: DICS power localization with real valued coefficients Message-ID: Dear Listusers, this post relates back to an older one where the use of DICS to localize power maxima (without the use of a reference time course) was discussed. For this case it was agreed upon - if I remember correctly - to constrain the filters to be real-valued as only this correctly reflects linear, INSTANTAEUOUS mixing from sources to sensors as it should be given for normal volume conduction, frequencies below 1 kHz and sampling in the same range. Real valued filters also allow to reconstruct real-valued source time-courses. Here's my question now: Real valued filters (i.e. only +/- values) should result in DICS also showing the well known problems for correlated sources (that are circumvented for everything but exactly correlated/anticorrelated sources when using complex coefficients and a reference signal) as in this case the whole equation is not very different from a simple fourier transform of the corresponding LCMV solution. Is this correct? Does DICS have problems localizing source power for correlated/coherent sources when constraining it to real valued coefficients? And if not, could someone give a hint where the differences would come from? Many thanks, Michael ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- A non-text attachment was scrubbed... Name: Michael Wibral.vcf Type: text/x-vcard Size: 336 bytes Desc: not available URL: From awalthermail at GOOGLEMAIL.COM Sun Dec 20 21:59:46 2009 From: awalthermail at GOOGLEMAIL.COM (Walther, Alexander) Date: Sun, 20 Dec 2009 21:59:46 +0100 Subject: clustering after sensor picking? Message-ID: Dear list, I am facing a question regarding the MCP in time-frequency-analysis. In order to boost the effect size, I picked several ROIs on the MEG scalp by running a Task-versus-Basline Comparison (values averaged over all subjects, all conditions, timepoints and frequencies) and selecting the highest raw effect patches. Since FDR-correction seems to be too conservative and yields no results in following analyses, I tried the cluster-method which works pretty well. Is it (statistically) correct to apply clustering after sensor picking? Since its test statistic refers to the clustering of /adjacent/ sensor-pairs of the whole spatiotemporal grid (which does not exist any more after the selection of ROIs), I wonder whether it is still appropriate. Any advice would be helpful. Merry xmas in advance! Best Alex ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From ole.jensen at DONDERS.RU.NL Sun Dec 20 22:42:57 2009 From: ole.jensen at DONDERS.RU.NL (Ole Jensen) Date: Sun, 20 Dec 2009 22:42:57 +0100 Subject: Biomag2010/data analysis competition Message-ID: Dear all, We would like to point you all to the data analysis competition at Biomag2010: http://megcommunity.org/index.php?option=com_content&view=article&id=2&Itemid=24 We would like as many as possible to participate so please consider this and/or spread the word! Best wishes for the holidays, Ole Jensen and Jan Mathijs Schoeffelen -- Ole Jensen Principal Investigator Neuronal Oscillations Group Donders Institute for Brain, Cognition and Behaviour Centre for Cognitive Neuroimaging P.O. Box 9101 NL-6500 HB Nijmegen The Netherlands Office : +31 24 36 10884 MEG lab : +31 24 36 10988 Fax : +31 24 36 10989 e-mail : ole.jensen at donders.ru.nl URL : http://ojensen.ruhosting.nl/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From e.maris at DONDERS.RU.NL Mon Dec 21 18:16:39 2009 From: e.maris at DONDERS.RU.NL (Eric Maris) Date: Mon, 21 Dec 2009 18:16:39 +0100 Subject: clustering after sensor picking? In-Reply-To: <4B2E9042.7020407@googlemail.com> Message-ID: Hi Walther, > I am facing a question regarding the MCP in time-frequency-analysis. In > order to boost the effect size, I picked several ROIs on the MEG scalp > by running a Task-versus-Basline Comparison (values averaged over all > subjects, all conditions, timepoints and frequencies) and selecting the > highest raw effect patches. Since FDR-correction seems to be too > conservative and yields no results in following analyses, I tried the > cluster-method which works pretty well. Is it (statistically) correct to > apply clustering after sensor picking? Since its test statistic refers > to the clustering of /adjacent/ sensor-pairs of the whole spatiotemporal > grid (which does not exist any more after the selection of ROIs), I > wonder whether it is still appropriate. Any advice would be helpful. If you have an independent localizer that you can thrust, then you should use it, and you should use it for as many dimensions as possible. Task-versus-baseline (with "task" being the average over all experimental conditions) is an independent localizer the result of which you can subsequently use for comparing the different experimental conditions. If you want to use the localizer for all three dimensions (space, frequency, and time), then you are done, because your three-dimensional array has been reduced to a scalar. If you want to use the localizer for only a subset of the dimensions, then you could use a cluster-based permutation test with clustering over the remaining dimensions. If you don't thrust your localizer, then you can do cluster-based permutation test with clustering over all three dimensions. Best, Eric Maris dr. Eric Maris Donders Institute for Brain, Cognition and Behavior Center for Cognition and F.C. Donders Center for Cognitive Neuroimaging Radboud University P.O. Box 9104 6500 HE Nijmegen The Netherlands T:+31 24 3612651 Mobile: 06 39584581 F:+31 24 3616066 E: e.maris at donders.ru.nl MSc Cognitive Neuroscience: www.ru.nl/master/cns/ > > Merry xmas in advance! > > > Best > > Alex > > ---------------------------------- > The aim of this list is to facilitate the discussion between users of the FieldTrip > toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. > See also http://listserv.surfnet.nl/archives/fieldtrip.html and > http://www.ru.nl/neuroimaging/fieldtrip. ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From tonychunwei at GMAIL.COM Tue Dec 22 05:19:34 2009 From: tonychunwei at GMAIL.COM (Chun-Wei Lee) Date: Tue, 22 Dec 2009 05:19:34 +0100 Subject: eeg_leadfield4_prepare Message-ID: Hi, I am using the prepare_leadfield() following the toturial "Use your own forward leadfield model in an inverse beamformer computation" but i have faced the problem that when i execute grid = prepare_leadfield(cfg); and I can't find eeg_leadfield4_prepare(), I check the file I download and I can't find this function I guess I ignore some step... can anyone tell me what is going on? ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From nathanweisz at MAC.COM Tue Dec 22 12:21:25 2009 From: nathanweisz at MAC.COM (Nathan Weisz) Date: Tue, 22 Dec 2009 12:21:25 +0100 Subject: A newbie's question on Fourier using freqanalysis_mtmfft In-Reply-To: <000001ca7ef5$92ef6410$b8ce2c30$%giani@tuebingen.mpg.de> Message-ID: > Lastly, an even more general question: What do you think would be handier: (1) Compute the frequency spectrum over 60 seconds, to get a high frequency resolution or (2) to cut the signal into e.g. 4 second pieces and to average all spectra to increase the signal to noise ratio? as suggested before do not average the spectra, but the time series. after that you do your fourier stuff (with cfg.taper='hanning' as ingrid suggested). beware to move the window in steps which are exact multiples of your steady-state frequency cycle (e.g. 100 ms for 10 Hz). when you calculate the amount of sampling points you need to move your window, then first "think" in latencies (for 10 Hz e.g: 0, 100, 200 etc ms, if you move 1 cycle), after that convert to sampling points (e.g. using nearest.m). this is very important, because when you first "think" in sampling points then you might be missing your desired time point each time just a little bit, however the inaccuracy accumulates with each moving of your window. in the end you see no steady-state at all. this mistake did cost me and a phd student a couple of days to figure out while doing auditory steady-state ... good luck, nathan ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From nathanweisz at MAC.COM Tue Dec 22 15:59:21 2009 From: nathanweisz at MAC.COM (Nathan Weisz) Date: Tue, 22 Dec 2009 15:59:21 +0100 Subject: "Changing People, Changing Brain" - Travel Awards for Young Scientists Message-ID: hi everyone, i would like to abuse this list to raise awareness for the upcoming conference "Changing People, Changing Brains" that will take place in Konstanz next year, April 8-10 2010. Diverse experts from various disciplines (e.g. neuroscientists, clinicians) will present their results and views on "adaptation". Keynote speakers are S. Hillyard, M. Merzenich and U. Schnyder. Please take a look at the conference web-page: http://www.psychologie.uni-konstanz.de/abteilungen/clinicalpsychology/changing/ as well as the attached flyer. For the conference we have 16 travel awards for Young scientists (i.e. PhD and Postdoc level) that will cover costs up to 1000€. The deadline for application will be 15. Jan. 2010. Any young scientist who can fit their research topic under the umbrella-terms: "Trauma and Adaptation" and "Markers of Neural Plasticity" is encouraged to send an application to the conference committee (see flyer for details). Feel free to pass this on to any young scientist you know who fits the profile of the conference. Merry christmas and a happy new year, nathan -------------------------------------------- Dr. Nathan Weisz OBOB-Lab University of Konstanz Department of Psychology P.O. Box D23 78457 Konstanz Germany Tel: ++49 - (0)7531 - 88 45 84 Email: nathan.weisz at uni-konstanz.de Homepage: http://www.uni-konstanz.de/obob "Nothing shocks me. I'm a scientist." (Indiana Jones) ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: flyer_conference_thomas_brigitte.pdf Type: application/pdf Size: 710542 bytes Desc: not available URL: -------------- next part -------------- An HTML attachment was scrubbed... URL: From akiko at NYU.EDU Tue Dec 22 16:14:25 2009 From: akiko at NYU.EDU (Akiko Ikkai) Date: Tue, 22 Dec 2009 10:14:25 -0500 Subject: freqanalysis & cfg.channel Message-ID: Hi, I'm trying to run TFR on MEG data and plot the results, and getting puzzling figures. Both freqanalysis and multiplotTFR run fine, and figures are produced, but the first channel (first channel in ft_data.label) is always extremely noisy (barely changing from the baseline, but showing random patches of activations across time and freq). When I take out that channel with cfg.channel = {'all','-1'}; % when the first channel is noisy the second channel (now the first in label) shows the same trend, if I take out the second, the third one is bad, etc... Other channels don't seem to be affected. I'm pasting my code during this process below. Can anyone tell me what might be going wrong, and when the best point to delete bad channels? Thanks in advance, Akiko %%% to run freq analysis %%% cfg.output = 'pow'; cfg.method = 'mtmconvol'; cfg.taper = 'hanning'; cfg.foi = 4:2:50; cfg.t_ftimwin = ones(length(cfg.foi),1).*0.5; cfg.toi = -.5:0.05:2; cfg.channel = {'all','-1'}; % when the first channel is noisy TFRhann_Rvalid = freqanalysis(cfg, Rvalid); cfg = []; cfg.baseline = [-.1 0]; cfg.baselinetype = 'relative'; cfg.xlim = [-0.1 1.2]; cfg.showlabels = 'yes'; cfg.colorbar = 'yes'; figure(1);clf cfg.ylim = [5 50]; cfg.zlim = [0 2]; multiplotTFR(cfg, TFRhann_Rvalid); % after importing channel layout ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From christine.gruetzner at GOOGLEMAIL.COM Tue Dec 22 17:00:56 2009 From: christine.gruetzner at GOOGLEMAIL.COM (Christine Gruetzner) Date: Tue, 22 Dec 2009 17:00:56 +0100 Subject: Source analysis on timelockdata Message-ID: Hi everyone, I got a problem with performing source analysis (minimum norm estimate) on timelockdata, and I would be very glad if anyone could help me out! So far, I've done the following steps (using fieldtrip version 20091221): 1) Compute timelockanalysis with cfg.latency = [0.05 0.4] and baseline correction for condition 1 and 2 2) Source analysis with cfg. method = 'mne' on the timelock data, using inverse grids In the output from the source analysis I have avg.pow = 4560x211 for each subject (211 = number of time samples) The problem is that I can't compute sourcegrandaverage (see code below) on these data (error at sourcegrandaverage at 178, dat(:,i) = tmp(:)); I already tried to put the single datasets directly into sourcestatistics, but this doesn't work either (error: "the function requires source or volume data as input") I guess the problem is caused by the time dimension in the timelock data - does anyone have an idea how to handle this information in source analysis / source grandaverage / source statistics? Best Christine %------------------------------------------------- % Code for Source Statistics datapath = '/data/home1/ctillman/data/MooneyMEEGFieldtripAnalysis/ERF/Pilot/MNE/'; DataFaceFiles = { 'ERF_Task_BaseCorr_PreprocNew1secbase_ABA04_MooneyFacesMEEG_20070625_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_BBA06_MooneyFacesMEEG_20080318_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_CSA25_MooneyFacesMEEG_20070912_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_FSA04_MooneyFacesMEEG_20070529_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_GDE03_MooneyFacesMEEG_20071002_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_IFS20_MooneyFacesMEEG_20070809_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_IKE28_MooneyFacesMEEG_20070329_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_JHA07_MooneyFacesMEEG_20070327_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_JPA05_MooneyFacesMEEG_20080403_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_MKA21_MooneyFacesMEEG_20070711_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_MMA07_MooneyFacesMEEG_20070706_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_PSS16_MooneyFacesMEEG_20080312_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_SNI05_MooneyFacesMEEG_20080313_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_TWS22_MooneyFacesMEEG_20070831_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_UWA31_MooneyFacesMEEG_20070914_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; }; DataInvertedFiles = { 'ERF_Task_BaseCorr_PreprocNew1secbase_ABA04_MooneyFacesMEEG_20070625_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_BBA06_MooneyFacesMEEG_20080318_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_CSA25_MooneyFacesMEEG_20070912_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_FSA04_MooneyFacesMEEG_20070529_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_GDE03_MooneyFacesMEEG_20071002_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_IFS20_MooneyFacesMEEG_20070809_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_IKE28_MooneyFacesMEEG_20070329_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_JHA07_MooneyFacesMEEG_20070327_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_JPA05_MooneyFacesMEEG_20080403_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_MKA21_MooneyFacesMEEG_20070711_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_MMA07_MooneyFacesMEEG_20070706_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_PSS16_MooneyFacesMEEG_20080312_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_SNI05_MooneyFacesMEEG_20080313_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_TWS22_MooneyFacesMEEG_20070831_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_UWA31_MooneyFacesMEEG_20070914_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; }; template = load('/data/home1/ctillman/data/MooneyMEEGFieldtripAnalysis/Beamforming/MNIgrids/Grids0p5_170109/MNItemplate_170109_-0p5iws.mat'); Nx = length(template.template_grid.xgrid); Ny = length(template.template_grid.ygrid); Nz = length(template.template_grid.zgrid); %-------------------------------------------------------------------------- for i = 1:length(DataFaceFiles) fullname1 = strcat(datapath,DataFaceFiles{i,1}); DataFace{i} = load(fullname1); end for i = 1:length(DataInvertedFiles) fullname2 = strcat(datapath,DataInvertedFiles{i,1}); DataInverted{i} = load(fullname2); end %-------------------------------------------------------------------------- % Fixing the structure properties % Absolute power difference for l = 1:length(DataFaceFiles) DataFace{l}.DataERFOut.xgrid = template.template_grid.xgrid; DataFace{l}.DataERFOut.ygrid = template.template_grid.ygrid; DataFace{l}.DataERFOut.zgrid = template.template_grid.zgrid; DataFace{l}.DataERFOut.dim = [Nx Ny Nz]; DataFace{l}.DataERFOut.pos = template.template_grid.pos; DataFace{l}.DataERFOut.inside = template.template_grid.inside; DataFace{l}.DataERFOut.outside = template.template_grid.outside; DataFace{l} = DataFace{l}.DataERFOut; end for l = 1:length(DataInvertedFiles) DataInverted{l}.DataERFOut.xgrid = template.template_grid.xgrid; DataInverted{l}.DataERFOut.ygrid = template.template_grid.ygrid; DataInverted{l}.DataERFOut.zgrid = template.template_grid.zgrid; DataInverted{l}.DataERFOut.dim = [Nx Ny Nz]; DataInverted{l}.DataERFOut.pos = template.template_grid.pos; DataInverted{l}.DataERFOut.inside = template.template_grid.inside; DataInverted{l}.DataERFOut.outside = template.template_grid.outside; DataInverted{l} = DataInverted{l}.DataERFOut; end % Compute grand average for Condition 1 and 2 cfgGA = []; cfgGA.keepindividual = 'yes'; % cfg.parameter = 'pow'; % create command strings for the computation: commandstr1 = strcat ('DataGAFace', '= sourcegrandaverage(cfgGA'); commandstr2 = strcat ('DataGAInverted', '= sourcegrandaverage(cfgGA'); for l = 1 : length(DataFace) commandstr1 = strcat(commandstr1, ',DataFace{', num2str(l) , '}'); end % finalize command strings commandstr1 = strcat(commandstr1,');'); eval(commandstr1) % yields DataGADiff; for l = 1 : length(DataInverted) commandstr2 = strcat(commandstr2, ',DataInverted{', num2str(l) , '}'); end % finalize command strings commandstr2=strcat(commandstr2,');'); eval(commandstr2) % yields DataGADiff; cfg = []; cfg.dimord = 'voxel'; cfg.dim = [15 19 16]; nSubjects = length(DataFaceFiles); a = [1:nSubjects]; b = ones(1,nSubjects); cfg.design = [a a; b (2*b)]; cfg.uvar = 1; % "subject" is unit of observation cfg.ivar = 2; % row cfg.method = 'montecarlo'; cfg.correctm = 'fdr'; cfg.alpha = 0.05; cfg.numrandomization = 6000; cfg.parameter = 'pow'; cfg.statistic = 'depsamplesT'; sourceStat = sourcestatistics(cfg, DataGAFace, DataGAInverted); -- Christine Grützner, geb.Tillmann Max-Planck-Institut für Hirnforschung Abt. Neurophysiologie Deutschordenstr. 46 60528 Frankfurt am Main Germany Phone: +49 (0)69/6301-83225 E-Mail: tillmann at mpih-frankfurt.mpg.de http://www.mpih-frankfurt.mpg.de/global/Np/Staff/tillmann.htm ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From manish.saggar at GMAIL.COM Thu Dec 24 07:41:13 2009 From: manish.saggar at GMAIL.COM (Manish Saggar) Date: Thu, 24 Dec 2009 00:41:13 -0600 Subject: Frequency stats on Individual Alpha Frequency (IAF) based bands Message-ID: Dear All, I have a question about doing freqstatistics on a group of subjects, where each subject can have a different frequency range for a band of interest. For example, based on individual alpha frequency (IAF) I define alpha band to be [8-12Hz] in one subject and [7-11Hz] in another, then how can I do non-parametric alpha power analysis using freqstatistics function, since I can only give one range for all subjects in the cfg structure. Is there a way to directly give power values for a band rather than frequency of interest OR is there a separate function in such cases. Any help is appreciated. Happy Holidays!!! Regards, Manish ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From nhutche at GMAIL.COM Mon Dec 28 21:45:48 2009 From: nhutche at GMAIL.COM (Nathan Hutcheson) Date: Mon, 28 Dec 2009 21:45:48 +0100 Subject: topoplotTFR problem Message-ID: Hello, I am a graduate student at UAB and am having a problem getting Fieldtrip to plot my EEG preprocessed data using the topoplotTFR function. Below is what I entered into the Matlab command line: addpath(genpath('/usr/local/pkg/MATLAB/toolbox/eeglab7_1_3_14b/external/fie ldtrip-20090727/')) ' cfg = []; cfg.xlim = [-.5 -.25]; %cfg.zlim = [-1.5e-27 1.5e-27]; cfg.ylim = [8 12]; cfg.baseline = [-0.5 -0.1]; cfg.baselinetype = 'absolute'; cfg.showlabels = 'markers'; figure topoplotTFR(cfg,TFRhann) This is the error message I get: ??? Error using ==> topoplot at 1019 Odd number of input arguments?? Error in ==> topoplotER at 482 topoplot(cfg,chanX,chanY,datavector,chanLabels); Error in ==> topoplotTFR at 101 cfg=topoplotER(cfg, varargin{:}); Error in ==> tempFieldtriptest at 11 topoplotTFR(cfg,TFRhann) Any ideas/ suggestions? ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From bibi.raquel at GMAIL.COM Tue Dec 29 04:32:30 2009 From: bibi.raquel at GMAIL.COM (Raquel Bibi) Date: Mon, 28 Dec 2009 22:32:30 -0500 Subject: topoplotTFR problem In-Reply-To: Message-ID: I had a similar problem. It was due to having the same function in EEGLAB. If you are using EEGLAB make sure to set the path below fieldtrip. Best, Raquel On Mon, Dec 28, 2009 at 3:45 PM, Nathan Hutcheson wrote: > Hello, > > I am a graduate student at UAB and am having a problem getting Fieldtrip to > plot my EEG preprocessed data using the topoplotTFR function. Below is > what > I entered into the Matlab command line: > > addpath(genpath('/usr/local/pkg/MATLAB/toolbox/eeglab7_1_3_14b/external/fie > ldtrip-20090727/')) ' > > cfg = []; > cfg.xlim = [-.5 -.25]; > %cfg.zlim = [-1.5e-27 1.5e-27]; > cfg.ylim = [8 12]; > cfg.baseline = [-0.5 -0.1]; > cfg.baselinetype = 'absolute'; > cfg.showlabels = 'markers'; > figure > topoplotTFR(cfg,TFRhann) > > This is the error message I get: > > ??? Error using ==> topoplot at 1019 > Odd number of input arguments?? > > Error in ==> topoplotER at 482 > topoplot(cfg,chanX,chanY,datavector,chanLabels); > > Error in ==> topoplotTFR at 101 > cfg=topoplotER(cfg, varargin{:}); > > Error in ==> tempFieldtriptest at 11 > topoplotTFR(cfg,TFRhann) > > Any ideas/ suggestions? > > ---------------------------------- > The aim of this list is to facilitate the discussion between users of the > FieldTrip toolbox, to share experiences and to discuss new ideas for MEG > and EEG analysis. See also > http://listserv.surfnet.nl/archives/fieldtrip.html and > http://www.ru.nl/neuroimaging/fieldtrip. > ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From dsenkows at UKE.UNI-HAMBURG.DE Wed Dec 30 11:51:36 2009 From: dsenkows at UKE.UNI-HAMBURG.DE (Daniel Senkowski) Date: Wed, 30 Dec 2009 11:51:36 +0100 Subject: Open PhD Position Message-ID: Hi, I hope you don't mind announcing a job opening for a PhD position at our Department in Hamburg (see below). Regards, Daniel ---------------------------------------------------------------- PhD Position at the Dept. of Neurophysiology and Pathophysiology, Hamburg The Department of Neurophysiology and Pathophysiology (Head: Prof. Dr. Andreas K. Engel) at the University Medical Center Hamburg-Eppendorf (Germany) invites applications for a PhD student position, starting February/March 2010. The PhD student will conduct studies on unisensory and multisensory processing of auditory and audiovisual information in cochlear-implant users. The project incorporates advanced psychophysical measurements as well as EEG and MEG recordings. The project will be conducted in collaboration with Prof. Dr. Andrej Kral from the Medical University Hannover. Main research interests of the Department of Neurophysiology are the dynamics of distributed sensory processing, intermodal and sensorimotor integration, as well as theories of perception, action and consciousness. Current projects involve EEG/MEG/fMRI studies in humans or physiological studies in animals. Further information on research at the Department of Neurophysiology can be obtained at http://www.uke.de/institute/neurophysiologie or http://www.40hz.net. Applicants should have a background in psychology, medicine, biology or neuroscience. Experience in human EEG studies or biosignal analysis is desirable. For further details, please contact Dr. Daniel Senkowski (phone +49-40-42803-57047, email: dsenkows at uke.de, www.danielsenkowski.com) or Prof. Dr. Andreas K. Engel (phone +49-40-42803-56170, email: ak.engel at uke.de) or Prof. Dr. Andrej Kral (phone: +49-511-532-7272, email: kral.andrej at mh-hannover.de). Applicants are asked to submit their CV and documentation of relevant qualification to Dr. Daniel Senkowski (dsenkows at uke.de), Dept. of Neurophysiology and Pathophysiology, University Medical Center Hamburg-Eppendorf, Martinistr. 52, 20246 Hamburg, Germany. -- Pflichtangaben gem�� Gesetz �ber elektronische Handelsregister und Genossenschaftsregister sowie das Unternehmensregister (EHUG): Universit�tsklinikum Hamburg-Eppendorf K�rperschaft des �ffentlichen Rechts Gerichtsstand: Hamburg Vorstandsmitglieder: Prof. Dr. J�rg F. Debatin (Vorsitzender) Dr. Alexander Kirstein Prof. Dr. Dr. Uwe Koch-Gromus ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From r.vandermeij at DONDERS.RU.NL Wed Dec 30 13:33:19 2009 From: r.vandermeij at DONDERS.RU.NL (Roemer van der Meij) Date: Wed, 30 Dec 2009 13:33:19 +0100 Subject: topoplotTFR problem In-Reply-To: Message-ID: Hi Nathan, TopoplotER has been extensively modified the past few weeks and the latest version no longer uses the topoplot.m (which presumably overlaps with EEGLAB). If you update your FieldTrip version the problem should be solved I think. The cfg-options have been changed as well though, so it would be a good idea to read the documentation at the top of the function (e.g. cfg.showlabels has now been integrated into cfg.markers if I recall correctly). Kind regards, Roemer van der Meij Quoting Nathan Hutcheson : > Hello, > > I am a graduate student at UAB and am having a problem getting Fieldtrip to > plot my EEG preprocessed data using the topoplotTFR function. Below is what > I entered into the Matlab command line: > > addpath(genpath('/usr/local/pkg/MATLAB/toolbox/eeglab7_1_3_14b/external/fie > ldtrip-20090727/')) ' > > cfg = []; > cfg.xlim = [-.5 -.25]; > %cfg.zlim = [-1.5e-27 1.5e-27]; > cfg.ylim = [8 12]; > cfg.baseline = [-0.5 -0.1]; > cfg.baselinetype = 'absolute'; > cfg.showlabels = 'markers'; > figure > topoplotTFR(cfg,TFRhann) > > This is the error message I get: > > ??? Error using ==> topoplot at 1019 > Odd number of input arguments?? > > Error in ==> topoplotER at 482 > topoplot(cfg,chanX,chanY,datavector,chanLabels); > > Error in ==> topoplotTFR at 101 > cfg=topoplotER(cfg, varargin{:}); > > Error in ==> tempFieldtriptest at 11 > topoplotTFR(cfg,TFRhann) > > Any ideas/ suggestions? > > ---------------------------------- > The aim of this list is to facilitate the discussion between users > of the FieldTrip toolbox, to share experiences and to discuss new > ideas for MEG and EEG analysis. See also > http://listserv.surfnet.nl/archives/fieldtrip.html and > http://www.ru.nl/neuroimaging/fieldtrip. > > -- Roemer van der Meij MSc Scientific Programmer & Data-Analyst Donders Institute for Brain, Cognition and Behaviour Centre for Cognition P.O. Box 9104 6500 HE Nijmegen The Netherlands Tel: +31(0)24 3612631 E-mail: r.vandermeij at donders.ru.nl@donders.ru.nl ---------------------------------------------------------------- This message was sent using IMP, the Internet Messaging Program. ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From Jan.Hirschmann at MED.UNI-DUESSELDORF.DE Wed Dec 30 16:03:46 2009 From: Jan.Hirschmann at MED.UNI-DUESSELDORF.DE (Jan Hirschmann) Date: Wed, 30 Dec 2009 16:03:46 +0100 Subject: problems with segmentation Message-ID: Hi there, I am having trouble segmenting an MRI scan using volumesegment on a realigned scan (obtained by volumerealign). Actually, I think this not really a fieldtrip but a spm problem. It seems there are nans or infs in some covariance matrix calculated by spm_segment, but honestly, I don't really see through this. Strangely, it did work once but then found no gray nor white matter but only CSF. Maybe it depends on how I choose the fiducials... If someone has any experience with this I would be really glad for any clue, as I am completley stuck. Thanks in advance! Here's the code and the error message: addpath('/data/apps/spm/spm2') cd('/net/avidya/storage/home/jan/seidel_dicom/S00002/SER00002'); mrifilename = 'I00001'; mri = read_mri(mrifilename); cfg=[]; cfg.interactive='yes'; seg_mri=volumerealign(cfg,mri); cd('/net/avidya/storage/home/jan/seidel_dicom/mat_anatomy_files'); save mri_realigned mri cfg = []; cfg.template = '/data/apps/spm/spm2/templates/T1.mnc'; cfg.coordinates = 'ctf'; cfg.write = 'no'; cfg.name = 'temp'; [segmentedmri] = volumesegment(cfg, mri); ??? Error using ==> schur Input to SCHUR must not contain NaN or Inf. Error in ==> sqrtm at 33 [Q, T] = schur(A,'complex'); % T is complex Schur form. Error in ==> spm_segment>get_p at 552 dst = (cor-ones(size(cor,1),1)*CP.mn(:,i)')/sqrtm(CP.cv(:,:,i)); Error in ==> spm_segment>run_segment at 335 [P,ll0] = get_p(cor,msk,s,sums,CP,bf); Error in ==> spm_segment at 106 [CP,BP,SP] = run_segment(CP,BP,SP,VF,sums,x1,x2,x3); Error in ==> ft_volumesegment at 176 spm_segment(Va,cfg.template,flags); Error in ==> volumesegment at 17 [varargout{1:nargout}] = funhandle(varargin{:}); ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From dahliash at STANFORD.EDU Tue Dec 1 00:33:04 2009 From: dahliash at STANFORD.EDU (Dahlia Sharon) Date: Tue, 1 Dec 2009 00:33:04 +0100 Subject: t statistic of coherence difference between stimulus conditions Message-ID: Hi, Since the coherence spectrum is different from the power spectrum in not being a simple average over trials, I am wondering how the point-by-point statistic should be calculated. I.e. does it make sense to take the difference in coherence between the two conditions and divide by the standard error? A shorter version of this question is: how does one test for a statistically significant coherence difference between two stimulus conditions in fieldtrip? Thanks, Dahlia. ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From j.schoffelen at PSY.GLA.AC.UK Tue Dec 1 09:03:12 2009 From: j.schoffelen at PSY.GLA.AC.UK (Jan-Mathijs Schoffelen) Date: Tue, 1 Dec 2009 09:03:12 +0100 Subject: single trial source signal In-Reply-To: <58ccc8240911301202j7c6a55e1w3cc8227ed18605e9@mail.gmail.com> Message-ID: Vasan, I feel that FieldTrip has the capability of extracting the single trial source signals. I think that MNE and LORETA do not fully support it yet, but in order to get there, you may have to hack the code a bit. With LCMV it is certainly possible. The only thing you have to do is specify cfg.keepfilter = 'yes' prior to sourceanalysis. The output to sourceanalysis will contain a field source.avg.filter, which contain per voxel the beamformer weights. You can get the single trial source data per voxel by doing something like this on the command line: singletrialvoxeldataofvoxelXintrialY = source.avg.filter{X} * data.trial{Y}. Et voilà. MNE and LORETA provide the projection matrix in one big shot, and as far as I know do not yet output the filt-matrix directly, but it should be possible to extract these from the functions and apply the same logic. Good luck, Jan-Mathijs On 30 Nov 2009, at 21:02, Sreenivasan Rajamoni Nadar wrote: > Dear FieldTrip users, > > I personally feel that the FieldTrip (latest version) does not seems > to having the capability to extract single trial source signals > using any of the the time domain beamformers: LCMV, MNE, SAM, > LORETA, RV or using the frequency domain beamformer methods like > DICS and PCC !! > > Please let me know if any of you made plugin codes to Fieldtrip to > get single trial source data? Robert, Could you let me know if there > is any other version which does the above? > > Thank you, > Vasan > > > > > > > > > > > ---------------------------------- > > The aim of this list is to facilitate the discussion between users > of the FieldTrip toolbox, to share experiences and to discuss new > ideas for MEG and EEG analysis. > > http://listserv.surfnet.nl/archives/fieldtrip.html > > http://www.ru.nl/fcdonders/fieldtrip/ > ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From jan.schoffelen at DONDERS.RU.NL Tue Dec 1 08:57:53 2009 From: jan.schoffelen at DONDERS.RU.NL (jan-mathijs schoffelen) Date: Tue, 1 Dec 2009 08:57:53 +0100 Subject: t statistic of coherence difference between stimulus conditions In-Reply-To: Message-ID: Dear Dahlia, Your question has been asked before, so it may be worthwile to browse the archive of the mailing list a bit. In short, the way to go depends on what you want: 1) Do you want to test for significance within a subject? Then it may be worthwhile to have a look at Maris et al 2007 J.Neurosci.Methods. Here we describe a way to test for significant coherence differences using permutation tests. 2) If you want to test for significance across subjects (which I generally prefer), I would compute the coherence difference per subject and apply a Z-transformation to the difference. Subsequently I do a permutation test across subjects. By randomly swapping the sign of the Z-transformed difference you obtain a distribution under the null-hypothesis, i.e. no difference in coherence across subjects. (for a formulation of the z-statistic you can have a look at the Maris paper). Both options are possible in fieldtrip, but it may require some coding yourself. Best wishes, Jan-Mathijs On 1 Dec 2009, at 00:33, Dahlia Sharon wrote: > Hi, > > Since the coherence spectrum is different from the power spectrum in > not > being a simple average over trials, I am wondering how the point-by- > point > statistic should be calculated. I.e. does it make sense to take the > difference in coherence between the two conditions and divide by the > standard error? > > A shorter version of this question is: how does one test for a > statistically > significant coherence difference between two stimulus conditions in > fieldtrip? > > Thanks, > Dahlia. > > ---------------------------------- > The aim of this list is to facilitate the discussion between users > of the FieldTrip toolbox, to share experiences and to discuss new > ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html > and http://www.ru.nl/neuroimaging/fieldtrip. > Dr. J.M. (Jan-Mathijs) Schoffelen Donders Institute for Brain, Cognition and Behaviour, Centre for Cognitive Neuroimaging, Radboud University Nijmegen, The Netherlands J.Schoffelen at donders.ru.nl Telephone: 0031-24-3668063 ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From Hanneke.vanDijk at MED.UNI-DUESSELDORF.DE Tue Dec 1 11:59:38 2009 From: Hanneke.vanDijk at MED.UNI-DUESSELDORF.DE (Hanneke Van Dijk) Date: Tue, 1 Dec 2009 11:59:38 +0100 Subject: single trial source signal Message-ID: Dear Vasan, I also feel single-trial source-analysis does work, I have done it and published it J Neurosci (using pcc for just power data). The problem as you sent it in the mail below is that the cfg.grid.pos that you entered is not inside your headmodel: 0 dipoles inside, 1 dipoles outside brain There wil not be any data in there. You could try to plot the functional data interpolated on the mri with cfg.interactive = 'yes'; and then click on the location you want to do the single-trial analysis on. The coordinates will be printed in the workspace. These can be entered in cfg.grid.pos. If you have any more questions could you then send the cfg you used as well? This might give some hints as to what went wrong. It's just not the case that you can use some-one elses code and run your data through it. The choises you make for the data analysis depend a lot on the kind of data and what you want to do. But this mailing list is there to help you allong the way! Hope it helps, Best, Hanneke -----Oorspronkelijk bericht----- Van: van Dijk, Hanneke Verzonden: zo 29.11.2009 09:38 Aan: FieldTrip discussion list Onderwerp: RE: [FIELDTRIP] single trial source signal Dear Vasan, Since I don't know exactly how far you are in doing the analysis, I just send you the basic script that shows the most important parameters. Don't forget to do freqanalysis with cfg.output = 'fourier' and cfg.method = 'mtmfft' for the specific frequency (cfg.foilim) you want to focus on. cfg = []; cfg.grid.pos = location of source coordinate;% [x y z] to fill in cfg.frequency = frequency of interest; cfg.vol = headmodel; %to make yourself see http://fieldtrip.fcdonders.nl/example/make_leadfields_using_different_headmodels cfg.projectnoise = 'yes';%to compute the neural activity index using sourcedescriptives cfg.lambda = '10%';%the amount of noice to estimate estimated cfg.method = 'pcc'; cfg.keeptrials = 'yes'; Virtual_channeldata = sourceanalysis(cfg,freq); You can do sourcedescriptives after that. 'help freqanalysis', 'help sourceanalysis' and 'help sourcedescriptives' should also help you further. Or you could have a look at the fieldtrip website. There are a lot of options to taylor the analysis to your data. Hope this helps! Best, Hanneke van Dijk ------------------------------------------------------------ Institute for Clinical Neuroscience and Medical Psychology Heinrich Heine Universitaet, Duesseldorf, Germany ------------------------------------------------------------ -----Oorspronkelijk bericht----- Van: FieldTrip discussion list namens Rajamoni Nadar, Sreenivasan (NIH/NIMH) [E] Verzonden: do 26.11.2009 14:53 Aan: FIELDTRIP at NIC.SURFNET.NL Onderwerp: [FIELDTRIP] single trial source signal FieldTrip Users, Is it possible to get single trial source signal using FieldTrip? I would appreciate if anybody could provide code for the same. Thank you, Vasan ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From sreenivasan.r.nadar at GMAIL.COM Tue Dec 1 17:20:24 2009 From: sreenivasan.r.nadar at GMAIL.COM (Sreenivasan Rajamoni Nadar) Date: Tue, 1 Dec 2009 11:20:24 -0500 Subject: single trial source signal In-Reply-To: <72E993C35FB11743B79FF9286E5B6D8B0F353C@Mail2-UKD.VMED.UKD> Message-ID: Dear Hanneke and FieldTripers, Thank you Hanneke. I extracted the single trial source signal using a time domain beamformer Please find below the script: clear all ds = sprintf('/rajamoni/MEG_ds/AEDTPJOU_nback_20050422_01-f.ds') cfg = []; cfg.dataset = ds; cfg.trialdef.eventtype = '?'; definetrial(cfg); cfg.trialdef.eventtype = 'r0'; cfg.trialdef.prestim = 0.25; cfg.trialdef.poststim = 0.25; cfg = definetrial(cfg); data = preprocessing(cfg); %~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ cfg.channel = {'MEG','-MRF43', '-MRO13'}; cfg.latency = [-0.25 0.25]; cfg.covariance = 'yes'; cfg.covariancewindow = [-0.0 0.25]; cfg.keeptrials = 'yes'; cfg.blcwindow = [-0.25 0.25]; cfg.bpfreq = [1 60]; [timelock] = timelockanalysis(cfg,data); %~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ctf_ss = read_ctf_hdm('/rajamoni/AEDTPJOU_nback_20050422_01-f.ds/default.hdm'); cfg = []; cfg.method = 'lcmv'; %'rv'; %'mvl', % 'pcc'; 'loreta'; %'mne'; cfg.grid.pos = [7.3 -3.9 3.9; 7.7 1.8,4.0]; %arbitrary source location cfg.singletrial = 'yes'; cfg.rawtrial = 'no'; cfg.keepfilter = 'yes'; cfg.keepmom = 'yes'; %cfg.hdmfile = strcat(ds, '/default.hdm'); cfg.channel = {'MEG','-MRF43', '-MRO13'}; cfg.vol = ctf_ss; [source] = sourceanalysis(cfg, timelock); % extraction of single trial source signals % %for trial all trials for i=1:66 trial{i}=source.trial(i).mom{1}; % 1 for the 1st source location and |||ly you could do for other source coord trial{i}=sqrt((sum(trial{i}.*trial{i}))); end; %~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ It seems to be working. I will report the other methods using freqanalysis after play with the FieldTrip for a while!! Any comments? -Vasan On Tue, Dec 1, 2009 at 4:28 AM, wrote: > Dear Vasan, > > I also feel single-trial source-analysis does work, I have done it and > published it J Neurosci (using pcc for just power data). > > The problem as you sent it in the mail below is that the cfg.grid.pos that > you entered is not inside your headmodel: > > 0 dipoles inside, 1 dipoles outside brain > > There wil not be any data in there. You could try to plot the functional > data interpolated on the mri with cfg.interactive = 'yes'; and then click on > the location you want to do the single-trial analysis on. The coordinates > will be printed in the workspace. These can be entered in cfg.grid.pos. > > If you have any more questions could you then send the cfg you used as > well? This might give some hints as to what went wrong. > > It's just not the case that you can use some-one elses code and run your > data through it. The choises you make for the data analysis depend a lot on > the kind of data and what you want to do. > But this mailing list is there to help you allong the way! > > Hope it helps, > > Best, Hanneke > > > > -----Oorspronkelijk bericht----- > Van: Sreenivasan Rajamoni Nadar [mailto:sreenivasan.r.nadar at gmail.com > ] > Verzonden: ma 30.11.2009 16:21 > Aan: van Dijk, Hanneke > Onderwerp: Re: [FIELDTRIP] single trial source signal > > > Dear Hanneke, > > I did the freq analysis and source analysis as suggested by you. I get the > following error: > > the input is freq data with 273 channels, 30 frequencybins and no timebins > using headmodel specified in the configuration > using gradiometers specified in the configuration > creating dipole grid based on user specified dipole positions > 0 dipoles inside, 1 dipoles outside brain > ??? Error using ==> nearest>mbscalar at 47 > Argument to mbscalar must be scalar > > Error in ==> nearest at 15 > mbscalar(val); > > Error in ==> prepare_freq_matrices at 72 > fbin = nearest(freq.freq, cfg.frequency); > > Error in ==> sourceanalysis at 359 > [Cf, Cr, Pr, Ntrials, tmpcfg] = prepare_freq_matrices(tmpcfg, data); > > ~~~~~~~~~~~~~~~~~~~~~~~ > > Do you know the way to fix it? > > Thanks, Vasan > > > > > On Sun, Nov 29, 2009 at 3:38 AM, Hanneke Van Dijk < > Hanneke.vanDijk at med.uni-duesseldorf.de> wrote: > > > Dear Vasan, > > > > Since I don't know exactly how far you are in doing the analysis, I just > > send you the basic script that shows the most important parameters. Don't > > forget to do freqanalysis with cfg.output = 'fourier' and cfg.method = > > 'mtmfft' for the specific frequency (cfg.foilim) you want to focus on. > > > > cfg = []; > > cfg.grid.pos = location of source coordinate;% [x y z] to fill in > > cfg.frequency = frequency of interest; > > cfg.vol = headmodel; %to make yourself see > > > http://fieldtrip.fcdonders.nl/example/make_leadfields_using_different_headmodels > > cfg.projectnoise = 'yes';%to compute the neural activity index using > > sourcedescriptives > > cfg.lambda = '10%';%the amount of noice to estimate estimated > > cfg.method = 'pcc'; > > cfg.keeptrials = 'yes'; > > Virtual_channeldata = sourceanalysis(cfg,freq); > > > > You can do sourcedescriptives after that. > > > > 'help freqanalysis', 'help sourceanalysis' and 'help sourcedescriptives' > > should also help you further. Or you could have a look at the fieldtrip > > website. There are a lot of options to taylor the analysis to your data. > > > > Hope this helps! > > > > Best, > > > > Hanneke van Dijk > > > > ------------------------------------------------------------ > > Institute for Clinical Neuroscience and Medical Psychology > > Heinrich Heine Universitaet, Duesseldorf, Germany > > ------------------------------------------------------------ > > > > -----Oorspronkelijk bericht----- > > Van: FieldTrip discussion list namens Rajamoni Nadar, Sreenivasan > > (NIH/NIMH) [E] > > Verzonden: do 26.11.2009 14:53 > > Aan: FIELDTRIP at NIC.SURFNET.NL > > Onderwerp: [FIELDTRIP] single trial source signal > > > > FieldTrip Users, > > > > Is it possible to get single trial source signal using FieldTrip? I would > > appreciate if anybody could provide code for the same. > > > > Thank you, > > Vasan > > ---------------------------------- > > The aim of this list is to facilitate the discussion between users of the > > FieldTrip toolbox, to share experiences and to discuss new ideas for MEG > > and EEG analysis. See also > > http://listserv.surfnet.nl/archives/fieldtrip.html and > > http://www.ru.nl/neuroimaging/fieldtrip. > > > > > > ---------------------------------- > > The aim of this list is to facilitate the discussion between users of the > > FieldTrip toolbox, to share experiences and to discuss new ideas for MEG > > and EEG analysis. See also > > http://listserv.surfnet.nl/archives/fieldtrip.html and > > http://www.ru.nl/neuroimaging/fieldtrip. > > > > > ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From gsudre at POBOX.COM Tue Dec 1 17:24:48 2009 From: gsudre at POBOX.COM (Gustavo Sudre) Date: Tue, 1 Dec 2009 11:24:48 -0500 Subject: source localization of frequency bands Message-ID: Hello, I have a generic question about source localization. From what I've seen so far, when the goal is to localize the activity in certain frequency bands, it's common to use methods such as DICS or the variant of MCE for frequency bands. I was wondering if it is also correct to do source localization using a different method (e.g. MNE) with the whole signal (i.e. prior to band-pass filtering to specific bands) and then convert the signal in the localized sources to frequency domain. Another alternative would be to band-pass the signal to a certain frequency band in source space, and then run a different source localization method on it (e.g. MNE). Could anyone elaborate on the advantages / disadvantages ( / validity) of these two methods? Thank you, Gus ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From Jan.Hirschmann at MED.UNI-DUESSELDORF.DE Thu Dec 3 17:00:07 2009 From: Jan.Hirschmann at MED.UNI-DUESSELDORF.DE (Jan Hirschmann) Date: Thu, 3 Dec 2009 17:00:07 +0100 Subject: minor problem loading fiff file Message-ID: Hi, this is my very first day with fieldtrip so there is some chance that the error is due to the user rather than to the code... Anyways, I had the following problem. I loaded a fif file using preprocessing which did not start a time 0 but later. I got an a error from the mne function fiff_read_raw_segment saying that there is no data in this range. I tried to define the trial differently setting trl in different ways but it didn't help so I looked at the code. Preprocessing calls the function read_header which said that nSamplesPre were -6031500 in my case. So I guess this means that there are samples missing between a trigger (I don"t know which) and the start of the file. Later in preprocessing the function read_data calls fiff_read_raw_segment with the following arguments: read_data.m, line 691.m: dat = fiff_read_raw_segment(hdr.orig.raw,begsample+hdr.nSamplesPre-1,endsample+hdr.nSamplesPre-1,chanindx); Thus fiff_read_raw_segment is launched with negative to and from values which finally causes the error. nSamples should have been subtracted here and not added (it is a negative integer). I would suggest that in the future the call to the function should be only with arguments coming from the header file, i.e. from = hdr.orig.raw.last_samp and to = hdr.orig.raw.first_samp or that the pluses in the quoted line should be changed to minuses (which I did now in my version). However, I don't know if my file is strange (neg nSamplesPre) or if the code has a bug. Hope this helps anyone Best, Jan ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From fredericroux at HOTMAIL.DE Fri Dec 4 12:50:58 2009 From: fredericroux at HOTMAIL.DE (Frederic Roux) Date: Fri, 4 Dec 2009 12:50:58 +0100 Subject: interpolated source activity values = NaN Message-ID: Hi everyone, I would like to use the values that correspond to the interpolated statistics at source level. The problem is that most of these values are NaNs, even tough I can visualize them with sourceplot. Here are the steps I am doing to compute these values: [signal1] = sourcegrandaverage(cfg,data); [signal2] = sourcegrandaverage(cfg,data); [Stats] = sourcestatistics(cfg,signal1,signal2);%the statistics used here is depsamplesT using fdr and clusterstatistics = maxsum [SourceInterpolatedSats] = sourceinterpolate(cfg,Stats,template_mri); This yields: SourceInterpolatedSats = inside: [91x109x91 logical] stat: [91x109x91 double] dim: [91 109 91] transform: [4x4 double] anatomy: [91x109x91 double] cfg: [1x1 struct] But when I try : SourceInterpolatedStats.stat([20 45 68]) = NaN. And this holds true for almost any index. Does anyone know if it's possible to access these values? Frederic _________________________________________________________________ http://redirect.gimas.net/?n=M0912xIWHM2 Hotmail - Mein E-Mail Anbieter ohne Kosten ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From ingrid.nieuwenhuis at FCDONDERS.RU.NL Fri Dec 4 13:21:17 2009 From: ingrid.nieuwenhuis at FCDONDERS.RU.NL (Ingrid Nieuwenhuis) Date: Fri, 4 Dec 2009 13:21:17 +0100 Subject: interpolated source activity values = NaN In-Reply-To: Message-ID: Hi Frederic, Probably the NaN's are the voxels outside the brain. The source estimate is only performed for voxels inside the brain, the voxels outside are put to NaN. In the field "inside" it is coded which voxels lay inside the brain. Try: SourceInterpolatedStats.stat(SourceInterpolatedStats.inside) This should give you the non-NaN values. Hope this helps, Ingrid _____ From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of Frederic Roux Sent: Friday, December 04, 2009 12:51 PM To: FIELDTRIP at NIC.SURFNET.NL Subject: [FIELDTRIP] interpolated source activity values = NaN Hi everyone, I would like to use the values that correspond to the interpolated statistics at source level. The problem is that most of these values are NaNs, even tough I can visualize them with sourceplot. Here are the steps I am doing to compute these values: [signal1] = sourcegrandaverage(cfg,data); [signal2] = sourcegrandaverage(cfg,data); [Stats] = sourcestatistics(cfg,signal1,signal2);%the statistics used here is depsamplesT using fdr and clusterstatistics = maxsum [SourceInterpolatedSats] = sourceinterpolate(cfg,Stats,template_mri); This yields: SourceInterpolatedSats = inside: [91x109x91 logical] stat: [91x109x91 double] dim: [91 109 91] transform: [4x4 double] anatomy: [91x109x91 double] cfg: [1x1 struct] But when I try : SourceInterpolatedStats.stat([20 45 68]) = NaN. And this holds true for almost any index. Does anyone know if it's possible to access these values? Frederic _____ Alle E-Mail-Adressen online auf einen Blick Ich will Hotmail! ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From fredericroux at HOTMAIL.DE Fri Dec 4 14:50:39 2009 From: fredericroux at HOTMAIL.DE (Frederic Roux) Date: Fri, 4 Dec 2009 14:50:39 +0100 Subject: interpolated source activity values = NaN In-Reply-To: <20091204122107.4BEE5EC09D@smtp.ru.nl> Message-ID: Hi Ingrid, thanks for the quick reply. I will try your suggestion but I am pretty much sure that the values I want to look at are inside the brain. My approach is the following: I want to indentify the voxels that show significant activation. So first I visualized my data with sourceplot and cfg.interactive = 'yes' and then I write down the indices of the voxels onto which I click. When I feed these indices into SourceInterpolatedStats.stat([x y z]) this returns me NaNs, even tough the voxel was clearly located inside the brain. Do you have any idea of why this happens? Frederic Date: Fri, 4 Dec 2009 13:21:17 +0100 From: ingrid.nieuwenhuis at FCDONDERS.RU.NL Subject: Re: [FIELDTRIP] interpolated source activity values = NaN To: FIELDTRIP at NIC.SURFNET.NL Hi Frederic, Probably the NaN’s are the voxels outside the brain. The source estimate is only performed for voxels inside the brain, the voxels outside are put to NaN. In the field “inside” it is coded which voxels lay inside the brain. Try: SourceInterpolatedStats.stat(SourceInterpolatedStats.inside) This should give you the non-NaN values. Hope this helps, Ingrid From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of Frederic Roux Sent: Friday, December 04, 2009 12:51 PM To: FIELDTRIP at NIC.SURFNET.NL Subject: [FIELDTRIP] interpolated source activity values = NaN Hi everyone, I would like to use the values that correspond to the interpolated statistics at source level. The problem is that most of these values are NaNs, even tough I can visualize them with sourceplot. Here are the steps I am doing to compute these values: [signal1] = sourcegrandaverage(cfg,data); [signal2] = sourcegrandaverage(cfg,data); [Stats] = sourcestatistics(cfg,signal1,signal2);%the statistics used here is depsamplesT using fdr and clusterstatistics = maxsum [SourceInterpolatedSats] = sourceinterpolate(cfg,Stats,template_mri); This yields: SourceInterpolatedSats = inside: [91x109x91 logical] stat: [91x109x91 double] dim: [91 109 91] transform: [4x4 double] anatomy: [91x109x91 double] cfg: [1x1 struct] But when I try : SourceInterpolatedStats.stat([20 45 68]) = NaN. And this holds true for almost any index. Does anyone know if it's possible to access these values? Frederic Alle E-Mail-Adressen online auf einen Blick Ich will Hotmail! ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ _________________________________________________________________ http://redirect.gimas.net/?n=M0912xXMasGreetings2 Nie mehr um Weihnachtsgrüße verlegen: mit tollen Weihnachts-E-Mails ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From ingrid.nieuwenhuis at FCDONDERS.RU.NL Fri Dec 4 14:58:23 2009 From: ingrid.nieuwenhuis at FCDONDERS.RU.NL (Ingrid Nieuwenhuis) Date: Fri, 4 Dec 2009 14:58:23 +0100 Subject: interpolated source activity values = NaN In-Reply-To: Message-ID: Dear Frederic, Could it be that you wrote down the indices of the voxels before interpolating? Since the voxels before interpolating do not match anymore after interpolating onto the template_mri. Best, Ingrid _____ From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of Frederic Roux Sent: Friday, December 04, 2009 2:51 PM To: FIELDTRIP at NIC.SURFNET.NL Subject: Re: [FIELDTRIP] interpolated source activity values = NaN Hi Ingrid, thanks for the quick reply. I will try your suggestion but I am pretty much sure that the values I want to look at are inside the brain. My approach is the following: I want to indentify the voxels that show significant activation. So first I visualized my data with sourceplot and cfg.interactive = 'yes' and then I write down the indices of the voxels onto which I click. When I feed these indices into SourceInterpolatedStats.stat([x y z]) this returns me NaNs, even tough the voxel was clearly located inside the brain. Do you have any idea of why this happens? Frederic _____ Date: Fri, 4 Dec 2009 13:21:17 +0100 From: ingrid.nieuwenhuis at FCDONDERS.RU.NL Subject: Re: [FIELDTRIP] interpolated source activity values = NaN To: FIELDTRIP at NIC.SURFNET.NL Hi Frederic, Probably the NaN’s are the voxels outside the brain. The source estimate is only performed for voxels inside the brain, the voxels outside are put to NaN. In the field “inside” it is coded which voxels lay inside the brain. Try: SourceInterpolatedStats.stat(SourceInterpolatedStats.inside) This should give you the non-NaN values. Hope this helps, Ingrid _____ From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of Frederic Roux Sent: Friday, December 04, 2009 12:51 PM To: FIELDTRIP at NIC.SURFNET.NL Subject: [FIELDTRIP] interpolated source activity values = NaN Hi everyone, I would like to use the values that correspond to the interpolated statistics at source level. The problem is that most of these values are NaNs, even tough I can visualize them with sourceplot. Here are the steps I am doing to compute these values: [signal1] = sourcegrandaverage(cfg,data); [signal2] = sourcegrandaverage(cfg,data); [Stats] = sourcestatistics(cfg,signal1,signal2);%the statistics used here is depsamplesT using fdr and clusterstatistics = maxsum [SourceInterpolatedSats] = sourceinterpolate(cfg,Stats,template_mri); This yields: SourceInterpolatedSats = inside: [91x109x91 logical] stat: [91x109x91 double] dim: [91 109 91] transform: [4x4 double] anatomy: [91x109x91 double] cfg: [1x1 struct] But when I try : SourceInterpolatedStats.stat([20 45 68]) = NaN. And this holds true for almost any index. Does anyone know if it's possible to access these values? Frederic _____ Alle E-Mail-Adressen online auf einen Blick Ich will Hotmail! ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ _____ Nie mehr um Weihnachtsgrüße verlegen: mit tollen Weihnachts-E-Mails ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From fredericroux at HOTMAIL.DE Fri Dec 4 15:06:10 2009 From: fredericroux at HOTMAIL.DE (Frederic Roux) Date: Fri, 4 Dec 2009 15:06:10 +0100 Subject: interpolated source activity values = NaN In-Reply-To: <20091204135813.EF177EC2BD@smtp.ru.nl> Message-ID: Actually I don't think so. I first computed the sourcestatistics. Then I interpolated the Stats and visualized them with sourceplot and cfg.interactive = yes. Frederic Date: Fri, 4 Dec 2009 14:58:23 +0100 From: ingrid.nieuwenhuis at FCDONDERS.RU.NL Subject: Re: [FIELDTRIP] interpolated source activity values = NaN To: FIELDTRIP at NIC.SURFNET.NL Dear Frederic, Could it be that you wrote down the indices of the voxels before interpolating? Since the voxels before interpolating do not match anymore after interpolating onto the template_mri. Best, Ingrid From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of Frederic Roux Sent: Friday, December 04, 2009 2:51 PM To: FIELDTRIP at NIC.SURFNET.NL Subject: Re: [FIELDTRIP] interpolated source activity values = NaN Hi Ingrid, thanks for the quick reply. I will try your suggestion but I am pretty much sure that the values I want to look at are inside the brain. My approach is the following: I want to indentify the voxels that show significant activation. So first I visualized my data with sourceplot and cfg.interactive = 'yes' and then I write down the indices of the voxels onto which I click. When I feed these indices into SourceInterpolatedStats.stat([x y z]) this returns me NaNs, even tough the voxel was clearly located inside the brain. Do you have any idea of why this happens? Frederic Date: Fri, 4 Dec 2009 13:21:17 +0100 From: ingrid.nieuwenhuis at FCDONDERS.RU.NL Subject: Re: [FIELDTRIP] interpolated source activity values = NaN To: FIELDTRIP at NIC.SURFNET.NL Hi Frederic, Probably the NaN’s are the voxels outside the brain. The source estimate is only performed for voxels inside the brain, the voxels outside are put to NaN. In the field “inside” it is coded which voxels lay inside the brain. Try: SourceInterpolatedStats.stat(SourceInterpolatedStats.inside) This should give you the non-NaN values. Hope this helps, Ingrid From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of Frederic Roux Sent: Friday, December 04, 2009 12:51 PM To: FIELDTRIP at NIC.SURFNET.NL Subject: [FIELDTRIP] interpolated source activity values = NaN Hi everyone, I would like to use the values that correspond to the interpolated statistics at source level. The problem is that most of these values are NaNs, even tough I can visualize them with sourceplot. Here are the steps I am doing to compute these values: [signal1] = sourcegrandaverage(cfg,data); [signal2] = sourcegrandaverage(cfg,data); [Stats] = sourcestatistics(cfg,signal1,signal2);%the statistics used here is depsamplesT using fdr and clusterstatistics = maxsum [SourceInterpolatedSats] = sourceinterpolate(cfg,Stats,template_mri); This yields: SourceInterpolatedSats = inside: [91x109x91 logical] stat: [91x109x91 double] dim: [91 109 91] transform: [4x4 double] anatomy: [91x109x91 double] cfg: [1x1 struct] But when I try : SourceInterpolatedStats.stat([20 45 68]) = NaN. And this holds true for almost any index. Does anyone know if it's possible to access these values? Frederic Alle E-Mail-Adressen online auf einen Blick Ich will Hotmail! ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ Nie mehr um Weihnachtsgrüße verlegen: mit tollen Weihnachts-E-Mails ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ _________________________________________________________________ http://redirect.gimas.net/?n=M0912xXMasGreetings2 Nie mehr um Weihnachtsgrüße verlegen: mit tollen Weihnachts-E-Mails ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From fredericroux at HOTMAIL.DE Fri Dec 4 15:17:06 2009 From: fredericroux at HOTMAIL.DE (Frederic Roux) Date: Fri, 4 Dec 2009 15:17:06 +0100 Subject: problem solved Message-ID: The solution to my problem is: SourceInterpolatedSats(Voxel) and not SourceInterpolatedStats([x y z]). Thanks for helping. Frederic _________________________________________________________________ http://redirect.gimas.net/?n=M0912xIE2 Internet Explorer aktualisieren – sicher im Internet! ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From lhunt at FMRIB.OX.AC.UK Sun Dec 6 23:47:58 2009 From: lhunt at FMRIB.OX.AC.UK (Laurence Hunt) Date: Sun, 6 Dec 2009 22:47:58 +0000 Subject: minor problem loading fiff file In-Reply-To: <72E993C35FB11743B79FF9286E5B6D8BA2E4F4@Mail2-UKD.VMED.UKD> Message-ID: Hi Jan, Thanks for the example file. It looks like a change was made to read_header after I initally wrote it, which was to take the first_samp field from fiff_setup_read_raw (called in read_header), and make this negative rather than positive (line 817 of read_header). This is causing read_data to crash. @Robert, could we either change read_header back, or change read_data with the amendment suggested by Jan? Basically first_samp (returned by fiff_setup_read_raw) can be positive or negative, I think depending upon how the recording is made - but more positive numbers mean further forward in time, and more negative numbers further backward. If fieldtrip typically makes nSamplesPre always increase positively as we go backwards in time, then we would need to make the change Jan suggested in line 691 of read_data (and anywhere else that depends on nSamplesPre in the neuromag_mne code). Cheers, Laurence =========================================== Laurence Hunt, DPhil Student Centre for Functional MRI of the Brain (FMRIB), University of Oxford lhunt at fmrib.ox.ac.uk Phone: (+44)1865-(2)22738 =========================================== On 4 Dec 2009, at 12:24, wrote: > Hi Laurence, > > I did not upload my data to the server but I am sending you the > first few seconds of my file with this mail. For me the error occurs > with this file, too. With the changes I have suggested everything > seems fine. > > Best, > > Jan > > ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From e.glerean at GMAIL.COM Tue Dec 8 13:10:54 2009 From: e.glerean at GMAIL.COM (Enrico Glerean) Date: Tue, 8 Dec 2009 14:10:54 +0200 Subject: private/senslabel.m missing on latest builds? Message-ID: Hello developers of FT, hopefully this is the best place for these kind of notifications. In the latest builds of FT the function private/senslabel.m is not there anymore. This throws errors such: ??? Undefined function or method 'senslabel' for input arguments of type 'char'. Error in ==> channelselection at 96 label1020 = senslabel('eeg1020'); % use external helper function Error in ==> preprocessing at 306 cfg.channel = channelselection(cfg.channel, hdr.label); Error in ==> ft_test1 at 9 dataPrepro = preprocessing(cfg1); (This error was obtained by running a basic preprocessing script as in http://fieldtrip.fcdonders.nl/tutorial/introduction using Subject01.ds from your tutorial data). Please let me know when the function is back. thanks -- Enrico Glerean, MSc Researcher Department of Biomedical Engineering and Computational Science Helsinki University of Technology ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From r.oostenveld at FCDONDERS.RU.NL Tue Dec 8 21:49:34 2009 From: r.oostenveld at FCDONDERS.RU.NL (Robert Oostenveld) Date: Tue, 8 Dec 2009 21:49:34 +0100 Subject: private/senslabel.m missing on latest builds? In-Reply-To: Message-ID: Dear Enrico, The senslabel function is now located elsewhere, in >> which senslabel.m /Users/robert/matlab/fieldtrip/forwinv/senslabel.m We try to avoid replicating functions, and this function (which used to be private) is now part of the public API of the forwinv module. That means that it does not have to be replicated any more in fieldtrip/private. If channelselection does not find it, then it seems that fieldtripdefs (which is called at the begin of channelselection) did not add the fieldtrip/forwinv directory correctly to your path. Could you try "clear all" and then "fieldtripdefs" and then "which senslabel"? Best regards, Robert ----------------------------------------------------------- Robert Oostenveld, PhD Senior Researcher Donders Institute for Brain, Cognition and Behaviour Centre for Cognitive Neuroimaging Radboud University Nijmegen tel.: +31 (0)24 3619695 e-mail: r.oostenveld at donders.ru.nl web: http://www.ru.nl/neuroimaging skype: r.oostenveld ----------------------------------------------------------- On 8 Dec 2009, at 13:10, Enrico Glerean wrote: > Hello developers of FT, > > hopefully this is the best place for these kind of notifications. In > the latest builds of FT the function private/senslabel.m > is not there anymore. This throws errors such: > > ??? Undefined function or method 'senslabel' for input arguments of type 'char'. > > Error in ==> channelselection at 96 > label1020 = senslabel('eeg1020'); % use external helper function > > Error in ==> preprocessing at 306 > cfg.channel = channelselection(cfg.channel, hdr.label); > > Error in ==> ft_test1 at 9 > dataPrepro = preprocessing(cfg1); > > > (This error was obtained by running a basic preprocessing script as in > http://fieldtrip.fcdonders.nl/tutorial/introduction using Subject01.ds > from your tutorial data). > > > Please let me know when the function is back. > thanks > > -- > Enrico Glerean, MSc > Researcher > Department of Biomedical Engineering and Computational Science > Helsinki University of Technology > > ---------------------------------- > The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. > ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From e.glerean at GMAIL.COM Wed Dec 9 08:40:55 2009 From: e.glerean at GMAIL.COM (Enrico Glerean) Date: Wed, 9 Dec 2009 09:40:55 +0200 Subject: private/senslabel.m missing on latest builds? In-Reply-To: Message-ID: Hello Robert thanks for this. There was a path conflict with EEGLAB (which also had an entry for the forwinv toolbox in its external/fieldtrip folder), hence the hastoolbox('forwinv', 1, 1); command on fieldtripdefs did not add the correct forwinv. Now everything seems fine again. Best -- Enrico Glerean, MSc Researcher Department of Biomedical Engineering and Computational Science Helsinki University of Technology 2009/12/8 Robert Oostenveld : > Dear Enrico, > The senslabel function is now located elsewhere, in >>> which senslabel.m > /Users/robert/matlab/fieldtrip/forwinv/senslabel.m > We try to avoid replicating functions, and this function (which used to be > private) is now part of the public API of the forwinv module. That means > that it does not have to be replicated any more in fieldtrip/private. > If channelselection does not find it, then it seems that fieldtripdefs > (which is called at the begin of channelselection) did not add the > fieldtrip/forwinv directory correctly to your path. Could you try "clear > all" and then "fieldtripdefs" and then "which senslabel"? > Best regards, > Robert > ----------------------------------------------------------- > Robert Oostenveld, PhD > Senior Researcher > Donders Institute for Brain, Cognition and Behaviour > Centre for Cognitive Neuroimaging > Radboud University Nijmegen > tel.: +31 (0)24 3619695 > e-mail: r.oostenveld at donders.ru.nl > web: http://www.ru.nl/neuroimaging > skype: r.oostenveld > ----------------------------------------------------------- > > On 8 Dec 2009, at 13:10, Enrico Glerean wrote: > > Hello developers of FT, > > hopefully this is the best place for these kind of notifications. In > the latest builds of FT the function private/senslabel.m > is not there anymore. This throws errors such: > > ??? Undefined function or method 'senslabel' for input arguments of type > 'char'. > > Error in ==> channelselection at 96 > label1020 = senslabel('eeg1020'); % use external helper function > > Error in ==> preprocessing at 306 >  cfg.channel = channelselection(cfg.channel, hdr.label); > > Error in ==> ft_test1 at 9 > dataPrepro   = preprocessing(cfg1); > > > (This error was obtained by running a basic preprocessing script as in > http://fieldtrip.fcdonders.nl/tutorial/introduction using Subject01.ds > from your tutorial data). > > > Please let me know when the function is back. > thanks > > -- > Enrico Glerean, MSc > Researcher > Department of Biomedical Engineering and Computational Science > Helsinki University of Technology > > ---------------------------------- > The aim of this list is to facilitate the discussion between users of the > FieldTrip  toolbox, to share experiences and to discuss new ideas for MEG > and EEG analysis. See also > http://listserv.surfnet.nl/archives/fieldtrip.html and > http://www.ru.nl/neuroimaging/fieldtrip. > > > ---------------------------------- > > The aim of this list is to facilitate the discussion between users of the > FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and > EEG analysis. > > http://listserv.surfnet.nl/archives/fieldtrip.html > > http://www.ru.nl/fcdonders/fieldtrip/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From d.gupta at DONDERS.RU.NL Wed Dec 9 12:09:23 2009 From: d.gupta at DONDERS.RU.NL (Disha Gupta) Date: Wed, 9 Dec 2009 12:09:23 +0100 Subject: Common spatial patterns Message-ID: I was looking for documentation/tutorial for CSP in fieldtrip. I can see some documentation in the code at Files\MATLAB\R2008b\work\fieldtrip-20091114\classification\toolboxes\herman\csp\ If there is a fieldtrip tutorial I am missing out on, it will be very useful to know. Disha ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From Erin.Oakman at NYUMC.ORG Thu Dec 10 22:48:29 2009 From: Erin.Oakman at NYUMC.ORG (Oakman, Erin) Date: Thu, 10 Dec 2009 16:48:29 -0500 Subject: problem with freqstatistics Message-ID: Hi, I am following the cluster-based statistics tutorial called cluster_permutation_freq, "within trial experiments." When defining "baseline" and "activation" times with 1 subject, I have an error using redefinetrial to choose the nonoverlapping and equal length trials. For example, % redefine cfg = []; cfg.toilim = [-0.5 0]; data_baseline = redefinetrial(cfg, data); ??? Error using ==> redefinetrial at 66 the trial definition is inconsistent with the data Specifically, there is no trl field in my data. Somehow the trl field was lost after channelrepair and appenddata. However, it is possible to redefine the activation and baseline time manually. Then I make the time-frequency files on baseline and activation, and test with freqstatistics: %freqstatistics with cluster cfg=[]; cfg.method='montecarlo'; cfg.statistic= 'actvsblT'; cfg.parameter='powspctrm'; cfg.channel='all'; cfg.avgoverchan='no'; cfg.latency='all'; %[0.05 0.45]; cfg.avgovertime='no'; cfg.frequency=[39 41]; %'all'; cfg.avgoverfreq='yes'; cfg.correctm='cluster'; cfg.clusteralpha=0.05; cfg.clusterstatistic='maxsum'; cfg.elecfile='/home/eo/science/layout/biosemi.sfp'; cfg.neighbourdist=2.5; % cfg.minnbchan=2; %default=0 cfg.tail=0; %default=0 cfg.alpha=0.05; cfg.numrandomization=500; stat = freqstatistics(cfg, data_baseline, data_activation); ??? Undefined variable "data" or class "data.biol". Error in ==> prepare_design at 85 nrepl=size(data.biol,1); Error in ==> statistics_wrapper at 233 [cfg] = prepare_design(cfg); Error in ==> freqstatistics at 89 [stat, cfg] = statistics_wrapper(cfg, varargin{:}); The powspctrm field in data_baseline.powspctrm and data_activation.powspctrm is 4D (rptxchanxfreqxtime), and the rpt,freq,time, and label fields have the same dimensions. Do I have to use redefinetrial before freqanalysis? Any advice is appreciated. Erin ------------------------------------------------------------ This email message, including any attachments, is for the sole use of the intended recipient(s) and may contain information that is proprietary, confidential, and exempt from disclosure under applicable law. Any unauthorized review, use, disclosure, or distribution is prohibited. If you have received this email in error please notify the sender by return email and delete the original message. Please note, the recipient should check this email and any attachments for the presence of viruses. The organization accepts no liability for any damage caused by any virus transmitted by this email. ================================= ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From a.maye at UKE.DE Fri Dec 11 14:58:11 2009 From: a.maye at UKE.DE (Alexander Maye) Date: Fri, 11 Dec 2009 14:58:11 +0100 Subject: Warning: nanmean Message-ID: Dear List! If you install fieldtrip by adding the directory with subfolders, then read on. I just noticed that my scripts were using fieldtrip's nanmean function from the classification/utilities directory, which is not doing what it promises: Instead of ignoring NaNs it considers them as zeros. While this might make sense for the classification utilities, for most of the time it does not. If Matlab searches the fieldtrip folder only (no subfolders thereof), then the correct nanmean from the statistics toolbox is used. I couldn't find any instructions if the installation directory should be added to the Matlab path with or without the subfolders, so everyone might want to check which nanmean you use. Good luck, ALEX. -- Pflichtangaben gem�� Gesetz �ber elektronische Handelsregister und Genossenschaftsregister sowie das Unternehmensregister (EHUG): Universit�tsklinikum Hamburg-Eppendorf K�rperschaft des �ffentlichen Rechts Gerichtsstand: Hamburg Vorstandsmitglieder: Prof. Dr. J�rg F. Debatin (Vorsitzender) Dr. Alexander Kirstein Prof. Dr. Dr. Uwe Koch-Gromus ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From r.oostenveld at FCDONDERS.RU.NL Mon Dec 14 15:52:50 2009 From: r.oostenveld at FCDONDERS.RU.NL (Robert Oostenveld) Date: Mon, 14 Dec 2009 15:52:50 +0100 Subject: Warning: nanmean In-Reply-To: <200912111458.12036.a.maye@uke.de> Message-ID: Dear Alex, I also detected the buggy nanmean in the classification/utilities directory. They were fixed last week by Marcel and now contain the correct functions with a slightly different name. Please update your fieldtrip version to the most recent one. About the directory adding: please see http://fieldtrip.fcdonders.nl/faq/should_i_add_fieldtrip_with_all_subdirectories_to_my_matlab_path (which I just created). best regards, Robert On 11 Dec 2009, at 14:58, Alexander Maye wrote: > Dear List! > > If you install fieldtrip by adding the directory with subfolders, > then read > on. I just noticed that my scripts were using fieldtrip's nanmean > function > from the classification/utilities directory, which is not doing what > it > promises: Instead of ignoring NaNs it considers them as zeros. While > this > might make sense for the classification utilities, for most of the > time it > does not. > > If Matlab searches the fieldtrip folder only (no subfolders > thereof), then the > correct nanmean from the statistics toolbox is used. I couldn't find > any > instructions if the installation directory should be added to the > Matlab path > with or without the subfolders, so everyone might want to check which > nanmean you use. > > Good luck, > > ALEX. > > > > > > -- > Pflichtangaben gemäß Gesetz über elektronische Handelsregister und > Genossenschaftsregister sowie das Unternehmensregister (EHUG): > > Universitätsklinikum Hamburg-Eppendorf > Körperschaft des öffentlichen Rechts > Gerichtsstand: Hamburg > > Vorstandsmitglieder: > Prof. Dr. Jörg F. Debatin (Vorsitzender) > Dr. Alexander Kirstein > Prof. Dr. Dr. Uwe Koch-Gromus > > ---------------------------------- > The aim of this list is to facilitate the discussion between users > of the FieldTrip toolbox, to share experiences and to discuss new > ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html > and http://www.ru.nl/neuroimaging/fieldtrip. > ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From r.oostenveld at FCDONDERS.RU.NL Wed Dec 16 11:06:40 2009 From: r.oostenveld at FCDONDERS.RU.NL (Robert Oostenveld) Date: Wed, 16 Dec 2009 11:06:40 +0100 Subject: important: all fieldtrip functions will be renamed to ft_xxx Message-ID: Dear FieldTrip users As some of you may know, Matlab (and specifically the older versions that we still support) does not have a good way of separating functions in different toolboxes from each other. The fieldtrip version of preprocessing (or read_data) might be completely different from a function with the same name in another toolbox. That is not a problem for some of the unusual function names, but some function names like "preprocessing" are very generic and therefore likely to be used in completely different contexts. After repeated discussion with the developers of the SPM Matlab toolbox, we have decided to start adopting the same naming scheme that SPM is using. That naming scheme consists of prefixing the function name with the name of the toolbox, e.g. spm_contrasts. The prefix that FieldTrip will use is "ft_". So that means that the FieldTrip preprocessing function will be renamed into ft_preprocessing, sourceanalysis will become ft_sourceanalysis, freqanalysis will become ft_freqanalysis, etc. This will affect all publicly available FieldTrip functions, i.e. the main functions that you are using. The advantage of this change in function names is that it further facilitates the already very good collaboration of the FieldTrip project with other EEG/MEG method development groups, such as SPM, EEGLAB, BrainStorm and others. Note that this is not an easy choice to make and we have carefully considered the consequences. Of course all users have existing scripts that use the old function names. We will do our utmost best to ensure that your old scripts will remain functional, also with new versions of the fieldtrip toolbox. To make this possible, we will provide backward compatibility wrappers, e.g. there will be a preprocessing.m function that calls ft_preprocessing.m and the likes. Not only the existing analysis scripts are affected, but also the documentation on the fieldtrip wiki will have to be updated. Furthermore, fieldtrip functions often call each other, which means that inside the fieldtrip functions the function names also have to be changed. On the short time scale, we will provide backward compatibility wrapper functions. On the medium time scale, we will ensure that the fieldtrip code and documentation is internally consistent. On the long run everyone (which includes you!) should adopt the new function names. Please start using these new function names in your scripts and in your derived functions as soon as possible. At a certain point in the future, the backward compatibility to the old/current function names will be removed from the fieldtrip release, so by that time all of your scripts should only be using the new function names, otherwise they won't work any more. The backward compatibility will be ensured throughout 2010, i.e. for a full year. Usually we are able to maintain backward compatibility for a much longer time, so probably you should not have to worry about this too much. best regards, Robert ----------------------------------------------------------- Robert Oostenveld, PhD Senior Researcher Donders Institute for Brain, Cognition and Behaviour Centre for Cognitive Neuroimaging Radboud University Nijmegen tel.: +31 (0)24 3619695 e-mail: r.oostenveld at donders.ru.nl web: http://www.ru.nl/neuroimaging skype: r.oostenveld ----------------------------------------------------------- ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From r.oostenveld at FCDONDERS.RU.NL Wed Dec 16 12:11:21 2009 From: r.oostenveld at FCDONDERS.RU.NL (Robert Oostenveld) Date: Wed, 16 Dec 2009 12:11:21 +0100 Subject: important: all fieldtrip functions will be renamed to ft_xxx In-Reply-To: <057247EE-D280-45B9-8DD9-D93865220423@fcdonders.ru.nl> Message-ID: Dear fieldtrip users One more note: for the backward compatibility to work, you should add the fieldtrip/compat directory to your path. Alternatively (and preferably) you should execute the fieldtrip/fieldtripdefs.m function. The fieldtripdefs function sets the default cfg options and also ensures that all path settings are correct. best regards, Robert On 16 Dec 2009, at 11:06, Robert Oostenveld wrote: > Dear FieldTrip users > > As some of you may know, Matlab (and specifically the older versions > that we still support) does not have a good way of separating > functions in different toolboxes from each other. The fieldtrip > version of preprocessing (or read_data) might be completely > different from a function with the same name in another toolbox. > That is not a problem for some of the unusual function names, but > some function names like "preprocessing" are very generic and > therefore likely to be used in completely different contexts. > > After repeated discussion with the developers of the SPM Matlab > toolbox, we have decided to start adopting the same naming scheme > that SPM is using. That naming scheme consists of prefixing the > function name with the name of the toolbox, e.g. spm_contrasts. The > prefix that FieldTrip will use is "ft_". So that means that the > FieldTrip preprocessing function will be renamed into > ft_preprocessing, sourceanalysis will become ft_sourceanalysis, > freqanalysis will become ft_freqanalysis, etc. This will affect all > publicly available FieldTrip functions, i.e. the main functions that > you are using. The advantage of this change in function names is > that it further facilitates the already very good collaboration of > the FieldTrip project with other EEG/MEG method development groups, > such as SPM, EEGLAB, BrainStorm and others. > > Note that this is not an easy choice to make and we have carefully > considered the consequences. Of course all users have existing > scripts that use the old function names. We will do our utmost best > to ensure that your old scripts will remain functional, also with > new versions of the fieldtrip toolbox. To make this possible, we > will provide backward compatibility wrappers, e.g. there will be a > preprocessing.m function that calls ft_preprocessing.m and the > likes. Not only the existing analysis scripts are affected, but also > the documentation on the fieldtrip wiki will have to be updated. > Furthermore, fieldtrip functions often call each other, which means > that inside the fieldtrip functions the function names also have to > be changed. > > On the short time scale, we will provide backward compatibility > wrapper functions. On the medium time scale, we will ensure that the > fieldtrip code and documentation is internally consistent. On the > long run everyone (which includes you!) should adopt the new > function names. Please start using these new function names in your > scripts and in your derived functions as soon as possible. At a > certain point in the future, the backward compatibility to the old/ > current function names will be removed from the fieldtrip release, > so by that time all of your scripts should only be using the new > function names, otherwise they won't work any more. The backward > compatibility will be ensured throughout 2010, i.e. for a full year. > Usually we are able to maintain backward compatibility for a much > longer time, so probably you should not have to worry about this too > much. > > best regards, > Robert > > > > ----------------------------------------------------------- > Robert Oostenveld, PhD > Senior Researcher > Donders Institute for Brain, Cognition and Behaviour > Centre for Cognitive Neuroimaging > Radboud University Nijmegen > tel.: +31 (0)24 3619695 > e-mail: r.oostenveld at donders.ru.nl > web: http://www.ru.nl/neuroimaging > skype: r.oostenveld > ----------------------------------------------------------- > > ---------------------------------- > The aim of this list is to facilitate the discussion between users > of the FieldTrip toolbox, to share experiences and to discuss new > ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html > and http://www.ru.nl/neuroimaging/fieldtrip. > ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From anette.giani at TUEBINGEN.MPG.DE Thu Dec 17 09:47:33 2009 From: anette.giani at TUEBINGEN.MPG.DE (Anette Giani) Date: Thu, 17 Dec 2009 09:47:33 +0100 Subject: A newbie's question on Fourier using freqanalysis_mtmfft Message-ID: Dear all, I am a beginner on MEG and I have some basic questions on Fourier transformation using the function freqanalysis_mtmfft. It would be great if you could help me! We are interested in Steady State Responses. Therefore we recorded data 60 seconds trials. To transform the time domain into a frequency spectrum we used the function freqanalysis_mtmfft. However, I am not sure which value cfg.tapsmofrq. Since we would like to have the highest frequency resolution possible I set cfg.tapsmofrq to 0.25; the lowest value possible. Do you think that was a good choice? Further, does this value mean that our lowest possible frequency resolution would be 0.25? If that was the case, how could I avoid all smoothing? Second, do you think that it would be useful to pad the signal with zeros to artificially increase the frequency resolution? I guess this could be done using cfg.pad? Lastly, an even more general question: What do you think would be handier: (1) Compute the frequency spectrum over 60 seconds, to get a high frequency resolution or (2) to cut the signal into e.g. 4 second pieces and to average all spectra to increase the signal to noise ratio? Thanks a lot in advance for your help, Anette ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From lulswinnik at GMAIL.COM Thu Dec 17 16:00:32 2009 From: lulswinnik at GMAIL.COM (Katya Vinnik) Date: Thu, 17 Dec 2009 16:00:32 +0100 Subject: A newbie's question on Fourier using freqanalysis_mtmfft In-Reply-To: <-1763973191626696207@unknownmsgid> Message-ID: Dear Anette, If you are looking at the steady state response and are interested in its power only, you should not try to achieve the highest frequency resolution, but rather adjust the parameters (sampling rate and NFFT) to place your SSR frequency exactly in the center of the frequency bin, which may be rather large (around 1 hz). In this way you'd be sure you're capturing all the power coming from from the SSR and will be able to compare this frequency bin between conditions or to the nearby frequency bins. Katya 2009/12/17 Anette Giani > Dear all, > > I am a beginner on MEG and I have some basic questions on Fourier > transformation using the function freqanalysis_mtmfft. It would be great > if you could help me! > > > > We are interested in Steady State Responses. Therefore we recorded data 60 > seconds trials. > > To transform the time domain into a frequency spectrum we used the function > freqanalysis_mtmfft. However, I am not sure which value cfg.tapsmofrq. > Since we would like to have the highest frequency resolution possible I set > cfg.tapsmofrq to 0.25; the lowest value possible. Do you think that was a > good choice? Further, does this value mean that our lowest possible > frequency resolution would be 0.25? If that was the case, how could I avoid > all smoothing? > > > > Second, do you think that it would be useful to pad the signal with zeros > to artificially increase the frequency resolution? I guess this could be > done using cfg.pad? > > > > Lastly, an even more general question: What do you think would be handier: > (1) Compute the frequency spectrum over 60 seconds, to get a high frequency > resolution or (2) to cut the signal into e.g. 4 second pieces and to average > all spectra to increase the signal to noise ratio? > > > > Thanks a lot in advance for your help, > > Anette > > > > ---------------------------------- > > The aim of this list is to facilitate the discussion between users of the > FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and > EEG analysis. > > http://listserv.surfnet.nl/archives/fieldtrip.html > > http://www.ru.nl/fcdonders/fieldtrip/ > -- Ekaterina Vinnik, MD, PhD Tactile Perception and Learning Lab Cognitive neuroscience sector, SISSA, Trieste, Italy +393347032225 lulswinnik at gmail.com ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From ingrid.nieuwenhuis at FCDONDERS.RU.NL Thu Dec 17 16:12:37 2009 From: ingrid.nieuwenhuis at FCDONDERS.RU.NL (Ingrid Nieuwenhuis) Date: Thu, 17 Dec 2009 16:12:37 +0100 Subject: A newbie's question on Fourier using freqanalysis_mtmfft In-Reply-To: <000001ca7ef5$92ef6410$b8ce2c30$%giani@tuebingen.mpg.de> Message-ID: Dear Anette, Cfg.tapsmofrq is an option for multitaper analysis (cfg.taper = 'dpss'), which might not be what you want if you want high frequency resolution. I would recommend looking at the tutorial "Time-frequency analysis using Hanning window, multitapers and wavelets" http://fieldtrip.fcdonders.nl/tutorial/timefrequencyanalysis there you can read about the differences between hanning taper and multitapers. Hope this helps a bit Best Ingrid _____ From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of Anette Giani Sent: Thursday, December 17, 2009 9:48 AM To: FIELDTRIP at NIC.SURFNET.NL Subject: [FIELDTRIP] A newbie's question on Fourier using freqanalysis_mtmfft Dear all, I am a beginner on MEG and I have some basic questions on Fourier transformation using the function freqanalysis_mtmfft. It would be great if you could help me! We are interested in Steady State Responses. Therefore we recorded data 60 seconds trials. To transform the time domain into a frequency spectrum we used the function freqanalysis_mtmfft. However, I am not sure which value cfg.tapsmofrq. Since we would like to have the highest frequency resolution possible I set cfg.tapsmofrq to 0.25; the lowest value possible. Do you think that was a good choice? Further, does this value mean that our lowest possible frequency resolution would be 0.25? If that was the case, how could I avoid all smoothing? Second, do you think that it would be useful to pad the signal with zeros to artificially increase the frequency resolution? I guess this could be done using cfg.pad? Lastly, an even more general question: What do you think would be handier: (1) Compute the frequency spectrum over 60 seconds, to get a high frequency resolution or (2) to cut the signal into e.g. 4 second pieces and to average all spectra to increase the signal to noise ratio? Thanks a lot in advance for your help, Anette ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From justin.ales at GMAIL.COM Thu Dec 17 17:15:49 2009 From: justin.ales at GMAIL.COM (Justin Ales) Date: Thu, 17 Dec 2009 08:15:49 -0800 Subject: A newbie's question on Fourier using freqanalysis_mtmfft In-Reply-To: <-1763973191626696207@unknownmsgid> Message-ID: In my experience with steady-state visual evoked potentials using time-frequency analysis with just power works poorly. This is because it doesn't average out phase incoherent noise sources, and the steady-state response is a driven coherent signal. We usually cut our data into 2 second long "trials", to get .5 Hz resolution, and then coherently average(phase locked) fourier components over these epochs. Bach & Meigen have written a good primer on analysis choices, such as windowing and zeropadding, for steady-state potentials: http://www.uniklinik-freiburg.de/augenklinik/live/homede/mit/bach/ops/fourier_en.html Justin Ales Smith-Kettlewell Eye Research Institute On Thu, Dec 17, 2009 at 12:47 AM, Anette Giani wrote: > Dear all, > > I am a beginner on MEG and I have some basic questions on Fourier > transformation using the function freqanalysis_mtmfft. It would be great if > you could help me! > > > > We are interested in Steady State Responses. Therefore we recorded data 60 > seconds trials. > > To transform the time domain into a frequency spectrum we used the function > freqanalysis_mtmfft. However, I am not sure which value cfg.tapsmofrq. Since > we would like to have the highest frequency resolution possible I set > cfg.tapsmofrq to 0.25; the lowest value possible. Do you think that was a > good choice? Further, does this value mean that our lowest possible > frequency resolution would be 0.25? If that was the case, how could I avoid > all smoothing? > > > > Second, do you think that it would be useful to pad the signal with zeros to > artificially increase the frequency resolution? I guess this could be done > using cfg.pad? > > > > Lastly, an even more general question: What do you think would be handier: > (1) Compute the frequency spectrum over 60 seconds, to get a high frequency > resolution or (2) to cut the signal into e.g. 4 second pieces and to average > all spectra to increase the signal to noise ratio? > > > > Thanks a lot in advance for your help, > >  Anette > > > > ---------------------------------- > > The aim of this list is to facilitate the discussion between users of the > FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and > EEG analysis. > > http://listserv.surfnet.nl/archives/fieldtrip.html > > http://www.ru.nl/fcdonders/fieldtrip/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From michael.wibral at WEB.DE Fri Dec 18 11:12:50 2009 From: michael.wibral at WEB.DE (Michael Wibral) Date: Fri, 18 Dec 2009 11:12:50 +0100 Subject: DICS power localization with real valued coefficients Message-ID: Dear Listusers, this post relates back to an older one where the use of DICS to localize power maxima (without the use of a reference time course) was discussed. For this case it was agreed upon - if I remember correctly - to constrain the filters to be real-valued as only this correctly reflects linear, INSTANTAEUOUS mixing from sources to sensors as it should be given for normal volume conduction, frequencies below 1 kHz and sampling in the same range. Real valued filters also allow to reconstruct real-valued source time-courses. Here's my question now: Real valued filters (i.e. only +/- values) should result in DICS also showing the well known problems for correlated sources (that are circumvented for everything but exactly correlated/anticorrelated sources when using complex coefficients and a reference signal) as in this case the whole equation is not very different from a simple fourier transform of the corresponding LCMV solution. Is this correct? Does DICS have problems localizing source power for correlated/coherent sources when constraining it to real valued coefficients? And if not, could someone give a hint where the differences would come from? Many thanks, Michael ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- A non-text attachment was scrubbed... Name: Michael Wibral.vcf Type: text/x-vcard Size: 336 bytes Desc: not available URL: From awalthermail at GOOGLEMAIL.COM Sun Dec 20 21:59:46 2009 From: awalthermail at GOOGLEMAIL.COM (Walther, Alexander) Date: Sun, 20 Dec 2009 21:59:46 +0100 Subject: clustering after sensor picking? Message-ID: Dear list, I am facing a question regarding the MCP in time-frequency-analysis. In order to boost the effect size, I picked several ROIs on the MEG scalp by running a Task-versus-Basline Comparison (values averaged over all subjects, all conditions, timepoints and frequencies) and selecting the highest raw effect patches. Since FDR-correction seems to be too conservative and yields no results in following analyses, I tried the cluster-method which works pretty well. Is it (statistically) correct to apply clustering after sensor picking? Since its test statistic refers to the clustering of /adjacent/ sensor-pairs of the whole spatiotemporal grid (which does not exist any more after the selection of ROIs), I wonder whether it is still appropriate. Any advice would be helpful. Merry xmas in advance! Best Alex ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From ole.jensen at DONDERS.RU.NL Sun Dec 20 22:42:57 2009 From: ole.jensen at DONDERS.RU.NL (Ole Jensen) Date: Sun, 20 Dec 2009 22:42:57 +0100 Subject: Biomag2010/data analysis competition Message-ID: Dear all, We would like to point you all to the data analysis competition at Biomag2010: http://megcommunity.org/index.php?option=com_content&view=article&id=2&Itemid=24 We would like as many as possible to participate so please consider this and/or spread the word! Best wishes for the holidays, Ole Jensen and Jan Mathijs Schoeffelen -- Ole Jensen Principal Investigator Neuronal Oscillations Group Donders Institute for Brain, Cognition and Behaviour Centre for Cognitive Neuroimaging P.O. Box 9101 NL-6500 HB Nijmegen The Netherlands Office : +31 24 36 10884 MEG lab : +31 24 36 10988 Fax : +31 24 36 10989 e-mail : ole.jensen at donders.ru.nl URL : http://ojensen.ruhosting.nl/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From e.maris at DONDERS.RU.NL Mon Dec 21 18:16:39 2009 From: e.maris at DONDERS.RU.NL (Eric Maris) Date: Mon, 21 Dec 2009 18:16:39 +0100 Subject: clustering after sensor picking? In-Reply-To: <4B2E9042.7020407@googlemail.com> Message-ID: Hi Walther, > I am facing a question regarding the MCP in time-frequency-analysis. In > order to boost the effect size, I picked several ROIs on the MEG scalp > by running a Task-versus-Basline Comparison (values averaged over all > subjects, all conditions, timepoints and frequencies) and selecting the > highest raw effect patches. Since FDR-correction seems to be too > conservative and yields no results in following analyses, I tried the > cluster-method which works pretty well. Is it (statistically) correct to > apply clustering after sensor picking? Since its test statistic refers > to the clustering of /adjacent/ sensor-pairs of the whole spatiotemporal > grid (which does not exist any more after the selection of ROIs), I > wonder whether it is still appropriate. Any advice would be helpful. If you have an independent localizer that you can thrust, then you should use it, and you should use it for as many dimensions as possible. Task-versus-baseline (with "task" being the average over all experimental conditions) is an independent localizer the result of which you can subsequently use for comparing the different experimental conditions. If you want to use the localizer for all three dimensions (space, frequency, and time), then you are done, because your three-dimensional array has been reduced to a scalar. If you want to use the localizer for only a subset of the dimensions, then you could use a cluster-based permutation test with clustering over the remaining dimensions. If you don't thrust your localizer, then you can do cluster-based permutation test with clustering over all three dimensions. Best, Eric Maris dr. Eric Maris Donders Institute for Brain, Cognition and Behavior Center for Cognition and F.C. Donders Center for Cognitive Neuroimaging Radboud University P.O. Box 9104 6500 HE Nijmegen The Netherlands T:+31 24 3612651 Mobile: 06 39584581 F:+31 24 3616066 E: e.maris at donders.ru.nl MSc Cognitive Neuroscience: www.ru.nl/master/cns/ > > Merry xmas in advance! > > > Best > > Alex > > ---------------------------------- > The aim of this list is to facilitate the discussion between users of the FieldTrip > toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. > See also http://listserv.surfnet.nl/archives/fieldtrip.html and > http://www.ru.nl/neuroimaging/fieldtrip. ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From tonychunwei at GMAIL.COM Tue Dec 22 05:19:34 2009 From: tonychunwei at GMAIL.COM (Chun-Wei Lee) Date: Tue, 22 Dec 2009 05:19:34 +0100 Subject: eeg_leadfield4_prepare Message-ID: Hi, I am using the prepare_leadfield() following the toturial "Use your own forward leadfield model in an inverse beamformer computation" but i have faced the problem that when i execute grid = prepare_leadfield(cfg); and I can't find eeg_leadfield4_prepare(), I check the file I download and I can't find this function I guess I ignore some step... can anyone tell me what is going on? ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From nathanweisz at MAC.COM Tue Dec 22 12:21:25 2009 From: nathanweisz at MAC.COM (Nathan Weisz) Date: Tue, 22 Dec 2009 12:21:25 +0100 Subject: A newbie's question on Fourier using freqanalysis_mtmfft In-Reply-To: <000001ca7ef5$92ef6410$b8ce2c30$%giani@tuebingen.mpg.de> Message-ID: > Lastly, an even more general question: What do you think would be handier: (1) Compute the frequency spectrum over 60 seconds, to get a high frequency resolution or (2) to cut the signal into e.g. 4 second pieces and to average all spectra to increase the signal to noise ratio? as suggested before do not average the spectra, but the time series. after that you do your fourier stuff (with cfg.taper='hanning' as ingrid suggested). beware to move the window in steps which are exact multiples of your steady-state frequency cycle (e.g. 100 ms for 10 Hz). when you calculate the amount of sampling points you need to move your window, then first "think" in latencies (for 10 Hz e.g: 0, 100, 200 etc ms, if you move 1 cycle), after that convert to sampling points (e.g. using nearest.m). this is very important, because when you first "think" in sampling points then you might be missing your desired time point each time just a little bit, however the inaccuracy accumulates with each moving of your window. in the end you see no steady-state at all. this mistake did cost me and a phd student a couple of days to figure out while doing auditory steady-state ... good luck, nathan ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From nathanweisz at MAC.COM Tue Dec 22 15:59:21 2009 From: nathanweisz at MAC.COM (Nathan Weisz) Date: Tue, 22 Dec 2009 15:59:21 +0100 Subject: "Changing People, Changing Brain" - Travel Awards for Young Scientists Message-ID: hi everyone, i would like to abuse this list to raise awareness for the upcoming conference "Changing People, Changing Brains" that will take place in Konstanz next year, April 8-10 2010. Diverse experts from various disciplines (e.g. neuroscientists, clinicians) will present their results and views on "adaptation". Keynote speakers are S. Hillyard, M. Merzenich and U. Schnyder. Please take a look at the conference web-page: http://www.psychologie.uni-konstanz.de/abteilungen/clinicalpsychology/changing/ as well as the attached flyer. For the conference we have 16 travel awards for Young scientists (i.e. PhD and Postdoc level) that will cover costs up to 1000€. The deadline for application will be 15. Jan. 2010. Any young scientist who can fit their research topic under the umbrella-terms: "Trauma and Adaptation" and "Markers of Neural Plasticity" is encouraged to send an application to the conference committee (see flyer for details). Feel free to pass this on to any young scientist you know who fits the profile of the conference. Merry christmas and a happy new year, nathan -------------------------------------------- Dr. Nathan Weisz OBOB-Lab University of Konstanz Department of Psychology P.O. Box D23 78457 Konstanz Germany Tel: ++49 - (0)7531 - 88 45 84 Email: nathan.weisz at uni-konstanz.de Homepage: http://www.uni-konstanz.de/obob "Nothing shocks me. I'm a scientist." (Indiana Jones) ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: flyer_conference_thomas_brigitte.pdf Type: application/pdf Size: 710542 bytes Desc: not available URL: -------------- next part -------------- An HTML attachment was scrubbed... URL: From akiko at NYU.EDU Tue Dec 22 16:14:25 2009 From: akiko at NYU.EDU (Akiko Ikkai) Date: Tue, 22 Dec 2009 10:14:25 -0500 Subject: freqanalysis & cfg.channel Message-ID: Hi, I'm trying to run TFR on MEG data and plot the results, and getting puzzling figures. Both freqanalysis and multiplotTFR run fine, and figures are produced, but the first channel (first channel in ft_data.label) is always extremely noisy (barely changing from the baseline, but showing random patches of activations across time and freq). When I take out that channel with cfg.channel = {'all','-1'}; % when the first channel is noisy the second channel (now the first in label) shows the same trend, if I take out the second, the third one is bad, etc... Other channels don't seem to be affected. I'm pasting my code during this process below. Can anyone tell me what might be going wrong, and when the best point to delete bad channels? Thanks in advance, Akiko %%% to run freq analysis %%% cfg.output = 'pow'; cfg.method = 'mtmconvol'; cfg.taper = 'hanning'; cfg.foi = 4:2:50; cfg.t_ftimwin = ones(length(cfg.foi),1).*0.5; cfg.toi = -.5:0.05:2; cfg.channel = {'all','-1'}; % when the first channel is noisy TFRhann_Rvalid = freqanalysis(cfg, Rvalid); cfg = []; cfg.baseline = [-.1 0]; cfg.baselinetype = 'relative'; cfg.xlim = [-0.1 1.2]; cfg.showlabels = 'yes'; cfg.colorbar = 'yes'; figure(1);clf cfg.ylim = [5 50]; cfg.zlim = [0 2]; multiplotTFR(cfg, TFRhann_Rvalid); % after importing channel layout ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From christine.gruetzner at GOOGLEMAIL.COM Tue Dec 22 17:00:56 2009 From: christine.gruetzner at GOOGLEMAIL.COM (Christine Gruetzner) Date: Tue, 22 Dec 2009 17:00:56 +0100 Subject: Source analysis on timelockdata Message-ID: Hi everyone, I got a problem with performing source analysis (minimum norm estimate) on timelockdata, and I would be very glad if anyone could help me out! So far, I've done the following steps (using fieldtrip version 20091221): 1) Compute timelockanalysis with cfg.latency = [0.05 0.4] and baseline correction for condition 1 and 2 2) Source analysis with cfg. method = 'mne' on the timelock data, using inverse grids In the output from the source analysis I have avg.pow = 4560x211 for each subject (211 = number of time samples) The problem is that I can't compute sourcegrandaverage (see code below) on these data (error at sourcegrandaverage at 178, dat(:,i) = tmp(:)); I already tried to put the single datasets directly into sourcestatistics, but this doesn't work either (error: "the function requires source or volume data as input") I guess the problem is caused by the time dimension in the timelock data - does anyone have an idea how to handle this information in source analysis / source grandaverage / source statistics? Best Christine %------------------------------------------------- % Code for Source Statistics datapath = '/data/home1/ctillman/data/MooneyMEEGFieldtripAnalysis/ERF/Pilot/MNE/'; DataFaceFiles = { 'ERF_Task_BaseCorr_PreprocNew1secbase_ABA04_MooneyFacesMEEG_20070625_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_BBA06_MooneyFacesMEEG_20080318_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_CSA25_MooneyFacesMEEG_20070912_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_FSA04_MooneyFacesMEEG_20070529_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_GDE03_MooneyFacesMEEG_20071002_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_IFS20_MooneyFacesMEEG_20070809_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_IKE28_MooneyFacesMEEG_20070329_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_JHA07_MooneyFacesMEEG_20070327_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_JPA05_MooneyFacesMEEG_20080403_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_MKA21_MooneyFacesMEEG_20070711_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_MMA07_MooneyFacesMEEG_20070706_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_PSS16_MooneyFacesMEEG_20080312_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_SNI05_MooneyFacesMEEG_20080313_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_TWS22_MooneyFacesMEEG_20070831_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_UWA31_MooneyFacesMEEG_20070914_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; }; DataInvertedFiles = { 'ERF_Task_BaseCorr_PreprocNew1secbase_ABA04_MooneyFacesMEEG_20070625_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_BBA06_MooneyFacesMEEG_20080318_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_CSA25_MooneyFacesMEEG_20070912_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_FSA04_MooneyFacesMEEG_20070529_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_GDE03_MooneyFacesMEEG_20071002_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_IFS20_MooneyFacesMEEG_20070809_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_IKE28_MooneyFacesMEEG_20070329_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_JHA07_MooneyFacesMEEG_20070327_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_JPA05_MooneyFacesMEEG_20080403_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_MKA21_MooneyFacesMEEG_20070711_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_MMA07_MooneyFacesMEEG_20070706_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_PSS16_MooneyFacesMEEG_20080312_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_SNI05_MooneyFacesMEEG_20080313_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_TWS22_MooneyFacesMEEG_20070831_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_UWA31_MooneyFacesMEEG_20070914_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; }; template = load('/data/home1/ctillman/data/MooneyMEEGFieldtripAnalysis/Beamforming/MNIgrids/Grids0p5_170109/MNItemplate_170109_-0p5iws.mat'); Nx = length(template.template_grid.xgrid); Ny = length(template.template_grid.ygrid); Nz = length(template.template_grid.zgrid); %-------------------------------------------------------------------------- for i = 1:length(DataFaceFiles) fullname1 = strcat(datapath,DataFaceFiles{i,1}); DataFace{i} = load(fullname1); end for i = 1:length(DataInvertedFiles) fullname2 = strcat(datapath,DataInvertedFiles{i,1}); DataInverted{i} = load(fullname2); end %-------------------------------------------------------------------------- % Fixing the structure properties % Absolute power difference for l = 1:length(DataFaceFiles) DataFace{l}.DataERFOut.xgrid = template.template_grid.xgrid; DataFace{l}.DataERFOut.ygrid = template.template_grid.ygrid; DataFace{l}.DataERFOut.zgrid = template.template_grid.zgrid; DataFace{l}.DataERFOut.dim = [Nx Ny Nz]; DataFace{l}.DataERFOut.pos = template.template_grid.pos; DataFace{l}.DataERFOut.inside = template.template_grid.inside; DataFace{l}.DataERFOut.outside = template.template_grid.outside; DataFace{l} = DataFace{l}.DataERFOut; end for l = 1:length(DataInvertedFiles) DataInverted{l}.DataERFOut.xgrid = template.template_grid.xgrid; DataInverted{l}.DataERFOut.ygrid = template.template_grid.ygrid; DataInverted{l}.DataERFOut.zgrid = template.template_grid.zgrid; DataInverted{l}.DataERFOut.dim = [Nx Ny Nz]; DataInverted{l}.DataERFOut.pos = template.template_grid.pos; DataInverted{l}.DataERFOut.inside = template.template_grid.inside; DataInverted{l}.DataERFOut.outside = template.template_grid.outside; DataInverted{l} = DataInverted{l}.DataERFOut; end % Compute grand average for Condition 1 and 2 cfgGA = []; cfgGA.keepindividual = 'yes'; % cfg.parameter = 'pow'; % create command strings for the computation: commandstr1 = strcat ('DataGAFace', '= sourcegrandaverage(cfgGA'); commandstr2 = strcat ('DataGAInverted', '= sourcegrandaverage(cfgGA'); for l = 1 : length(DataFace) commandstr1 = strcat(commandstr1, ',DataFace{', num2str(l) , '}'); end % finalize command strings commandstr1 = strcat(commandstr1,');'); eval(commandstr1) % yields DataGADiff; for l = 1 : length(DataInverted) commandstr2 = strcat(commandstr2, ',DataInverted{', num2str(l) , '}'); end % finalize command strings commandstr2=strcat(commandstr2,');'); eval(commandstr2) % yields DataGADiff; cfg = []; cfg.dimord = 'voxel'; cfg.dim = [15 19 16]; nSubjects = length(DataFaceFiles); a = [1:nSubjects]; b = ones(1,nSubjects); cfg.design = [a a; b (2*b)]; cfg.uvar = 1; % "subject" is unit of observation cfg.ivar = 2; % row cfg.method = 'montecarlo'; cfg.correctm = 'fdr'; cfg.alpha = 0.05; cfg.numrandomization = 6000; cfg.parameter = 'pow'; cfg.statistic = 'depsamplesT'; sourceStat = sourcestatistics(cfg, DataGAFace, DataGAInverted); -- Christine Grützner, geb.Tillmann Max-Planck-Institut für Hirnforschung Abt. Neurophysiologie Deutschordenstr. 46 60528 Frankfurt am Main Germany Phone: +49 (0)69/6301-83225 E-Mail: tillmann at mpih-frankfurt.mpg.de http://www.mpih-frankfurt.mpg.de/global/Np/Staff/tillmann.htm ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From manish.saggar at GMAIL.COM Thu Dec 24 07:41:13 2009 From: manish.saggar at GMAIL.COM (Manish Saggar) Date: Thu, 24 Dec 2009 00:41:13 -0600 Subject: Frequency stats on Individual Alpha Frequency (IAF) based bands Message-ID: Dear All, I have a question about doing freqstatistics on a group of subjects, where each subject can have a different frequency range for a band of interest. For example, based on individual alpha frequency (IAF) I define alpha band to be [8-12Hz] in one subject and [7-11Hz] in another, then how can I do non-parametric alpha power analysis using freqstatistics function, since I can only give one range for all subjects in the cfg structure. Is there a way to directly give power values for a band rather than frequency of interest OR is there a separate function in such cases. Any help is appreciated. Happy Holidays!!! Regards, Manish ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From nhutche at GMAIL.COM Mon Dec 28 21:45:48 2009 From: nhutche at GMAIL.COM (Nathan Hutcheson) Date: Mon, 28 Dec 2009 21:45:48 +0100 Subject: topoplotTFR problem Message-ID: Hello, I am a graduate student at UAB and am having a problem getting Fieldtrip to plot my EEG preprocessed data using the topoplotTFR function. Below is what I entered into the Matlab command line: addpath(genpath('/usr/local/pkg/MATLAB/toolbox/eeglab7_1_3_14b/external/fie ldtrip-20090727/')) ' cfg = []; cfg.xlim = [-.5 -.25]; %cfg.zlim = [-1.5e-27 1.5e-27]; cfg.ylim = [8 12]; cfg.baseline = [-0.5 -0.1]; cfg.baselinetype = 'absolute'; cfg.showlabels = 'markers'; figure topoplotTFR(cfg,TFRhann) This is the error message I get: ??? Error using ==> topoplot at 1019 Odd number of input arguments?? Error in ==> topoplotER at 482 topoplot(cfg,chanX,chanY,datavector,chanLabels); Error in ==> topoplotTFR at 101 cfg=topoplotER(cfg, varargin{:}); Error in ==> tempFieldtriptest at 11 topoplotTFR(cfg,TFRhann) Any ideas/ suggestions? ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From bibi.raquel at GMAIL.COM Tue Dec 29 04:32:30 2009 From: bibi.raquel at GMAIL.COM (Raquel Bibi) Date: Mon, 28 Dec 2009 22:32:30 -0500 Subject: topoplotTFR problem In-Reply-To: Message-ID: I had a similar problem. It was due to having the same function in EEGLAB. If you are using EEGLAB make sure to set the path below fieldtrip. Best, Raquel On Mon, Dec 28, 2009 at 3:45 PM, Nathan Hutcheson wrote: > Hello, > > I am a graduate student at UAB and am having a problem getting Fieldtrip to > plot my EEG preprocessed data using the topoplotTFR function. Below is > what > I entered into the Matlab command line: > > addpath(genpath('/usr/local/pkg/MATLAB/toolbox/eeglab7_1_3_14b/external/fie > ldtrip-20090727/')) ' > > cfg = []; > cfg.xlim = [-.5 -.25]; > %cfg.zlim = [-1.5e-27 1.5e-27]; > cfg.ylim = [8 12]; > cfg.baseline = [-0.5 -0.1]; > cfg.baselinetype = 'absolute'; > cfg.showlabels = 'markers'; > figure > topoplotTFR(cfg,TFRhann) > > This is the error message I get: > > ??? Error using ==> topoplot at 1019 > Odd number of input arguments?? > > Error in ==> topoplotER at 482 > topoplot(cfg,chanX,chanY,datavector,chanLabels); > > Error in ==> topoplotTFR at 101 > cfg=topoplotER(cfg, varargin{:}); > > Error in ==> tempFieldtriptest at 11 > topoplotTFR(cfg,TFRhann) > > Any ideas/ suggestions? > > ---------------------------------- > The aim of this list is to facilitate the discussion between users of the > FieldTrip toolbox, to share experiences and to discuss new ideas for MEG > and EEG analysis. See also > http://listserv.surfnet.nl/archives/fieldtrip.html and > http://www.ru.nl/neuroimaging/fieldtrip. > ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From dsenkows at UKE.UNI-HAMBURG.DE Wed Dec 30 11:51:36 2009 From: dsenkows at UKE.UNI-HAMBURG.DE (Daniel Senkowski) Date: Wed, 30 Dec 2009 11:51:36 +0100 Subject: Open PhD Position Message-ID: Hi, I hope you don't mind announcing a job opening for a PhD position at our Department in Hamburg (see below). Regards, Daniel ---------------------------------------------------------------- PhD Position at the Dept. of Neurophysiology and Pathophysiology, Hamburg The Department of Neurophysiology and Pathophysiology (Head: Prof. Dr. Andreas K. Engel) at the University Medical Center Hamburg-Eppendorf (Germany) invites applications for a PhD student position, starting February/March 2010. The PhD student will conduct studies on unisensory and multisensory processing of auditory and audiovisual information in cochlear-implant users. The project incorporates advanced psychophysical measurements as well as EEG and MEG recordings. The project will be conducted in collaboration with Prof. Dr. Andrej Kral from the Medical University Hannover. Main research interests of the Department of Neurophysiology are the dynamics of distributed sensory processing, intermodal and sensorimotor integration, as well as theories of perception, action and consciousness. Current projects involve EEG/MEG/fMRI studies in humans or physiological studies in animals. Further information on research at the Department of Neurophysiology can be obtained at http://www.uke.de/institute/neurophysiologie or http://www.40hz.net. Applicants should have a background in psychology, medicine, biology or neuroscience. Experience in human EEG studies or biosignal analysis is desirable. For further details, please contact Dr. Daniel Senkowski (phone +49-40-42803-57047, email: dsenkows at uke.de, www.danielsenkowski.com) or Prof. Dr. Andreas K. Engel (phone +49-40-42803-56170, email: ak.engel at uke.de) or Prof. Dr. Andrej Kral (phone: +49-511-532-7272, email: kral.andrej at mh-hannover.de). Applicants are asked to submit their CV and documentation of relevant qualification to Dr. Daniel Senkowski (dsenkows at uke.de), Dept. of Neurophysiology and Pathophysiology, University Medical Center Hamburg-Eppendorf, Martinistr. 52, 20246 Hamburg, Germany. -- Pflichtangaben gem�� Gesetz �ber elektronische Handelsregister und Genossenschaftsregister sowie das Unternehmensregister (EHUG): Universit�tsklinikum Hamburg-Eppendorf K�rperschaft des �ffentlichen Rechts Gerichtsstand: Hamburg Vorstandsmitglieder: Prof. Dr. J�rg F. Debatin (Vorsitzender) Dr. Alexander Kirstein Prof. Dr. Dr. Uwe Koch-Gromus ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From r.vandermeij at DONDERS.RU.NL Wed Dec 30 13:33:19 2009 From: r.vandermeij at DONDERS.RU.NL (Roemer van der Meij) Date: Wed, 30 Dec 2009 13:33:19 +0100 Subject: topoplotTFR problem In-Reply-To: Message-ID: Hi Nathan, TopoplotER has been extensively modified the past few weeks and the latest version no longer uses the topoplot.m (which presumably overlaps with EEGLAB). If you update your FieldTrip version the problem should be solved I think. The cfg-options have been changed as well though, so it would be a good idea to read the documentation at the top of the function (e.g. cfg.showlabels has now been integrated into cfg.markers if I recall correctly). Kind regards, Roemer van der Meij Quoting Nathan Hutcheson : > Hello, > > I am a graduate student at UAB and am having a problem getting Fieldtrip to > plot my EEG preprocessed data using the topoplotTFR function. Below is what > I entered into the Matlab command line: > > addpath(genpath('/usr/local/pkg/MATLAB/toolbox/eeglab7_1_3_14b/external/fie > ldtrip-20090727/')) ' > > cfg = []; > cfg.xlim = [-.5 -.25]; > %cfg.zlim = [-1.5e-27 1.5e-27]; > cfg.ylim = [8 12]; > cfg.baseline = [-0.5 -0.1]; > cfg.baselinetype = 'absolute'; > cfg.showlabels = 'markers'; > figure > topoplotTFR(cfg,TFRhann) > > This is the error message I get: > > ??? Error using ==> topoplot at 1019 > Odd number of input arguments?? > > Error in ==> topoplotER at 482 > topoplot(cfg,chanX,chanY,datavector,chanLabels); > > Error in ==> topoplotTFR at 101 > cfg=topoplotER(cfg, varargin{:}); > > Error in ==> tempFieldtriptest at 11 > topoplotTFR(cfg,TFRhann) > > Any ideas/ suggestions? > > ---------------------------------- > The aim of this list is to facilitate the discussion between users > of the FieldTrip toolbox, to share experiences and to discuss new > ideas for MEG and EEG analysis. See also > http://listserv.surfnet.nl/archives/fieldtrip.html and > http://www.ru.nl/neuroimaging/fieldtrip. > > -- Roemer van der Meij MSc Scientific Programmer & Data-Analyst Donders Institute for Brain, Cognition and Behaviour Centre for Cognition P.O. Box 9104 6500 HE Nijmegen The Netherlands Tel: +31(0)24 3612631 E-mail: r.vandermeij at donders.ru.nl@donders.ru.nl ---------------------------------------------------------------- This message was sent using IMP, the Internet Messaging Program. ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From Jan.Hirschmann at MED.UNI-DUESSELDORF.DE Wed Dec 30 16:03:46 2009 From: Jan.Hirschmann at MED.UNI-DUESSELDORF.DE (Jan Hirschmann) Date: Wed, 30 Dec 2009 16:03:46 +0100 Subject: problems with segmentation Message-ID: Hi there, I am having trouble segmenting an MRI scan using volumesegment on a realigned scan (obtained by volumerealign). Actually, I think this not really a fieldtrip but a spm problem. It seems there are nans or infs in some covariance matrix calculated by spm_segment, but honestly, I don't really see through this. Strangely, it did work once but then found no gray nor white matter but only CSF. Maybe it depends on how I choose the fiducials... If someone has any experience with this I would be really glad for any clue, as I am completley stuck. Thanks in advance! Here's the code and the error message: addpath('/data/apps/spm/spm2') cd('/net/avidya/storage/home/jan/seidel_dicom/S00002/SER00002'); mrifilename = 'I00001'; mri = read_mri(mrifilename); cfg=[]; cfg.interactive='yes'; seg_mri=volumerealign(cfg,mri); cd('/net/avidya/storage/home/jan/seidel_dicom/mat_anatomy_files'); save mri_realigned mri cfg = []; cfg.template = '/data/apps/spm/spm2/templates/T1.mnc'; cfg.coordinates = 'ctf'; cfg.write = 'no'; cfg.name = 'temp'; [segmentedmri] = volumesegment(cfg, mri); ??? Error using ==> schur Input to SCHUR must not contain NaN or Inf. Error in ==> sqrtm at 33 [Q, T] = schur(A,'complex'); % T is complex Schur form. Error in ==> spm_segment>get_p at 552 dst = (cor-ones(size(cor,1),1)*CP.mn(:,i)')/sqrtm(CP.cv(:,:,i)); Error in ==> spm_segment>run_segment at 335 [P,ll0] = get_p(cor,msk,s,sums,CP,bf); Error in ==> spm_segment at 106 [CP,BP,SP] = run_segment(CP,BP,SP,VF,sums,x1,x2,x3); Error in ==> ft_volumesegment at 176 spm_segment(Va,cfg.template,flags); Error in ==> volumesegment at 17 [varargout{1:nargout}] = funhandle(varargin{:}); ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From dahliash at STANFORD.EDU Tue Dec 1 00:33:04 2009 From: dahliash at STANFORD.EDU (Dahlia Sharon) Date: Tue, 1 Dec 2009 00:33:04 +0100 Subject: t statistic of coherence difference between stimulus conditions Message-ID: Hi, Since the coherence spectrum is different from the power spectrum in not being a simple average over trials, I am wondering how the point-by-point statistic should be calculated. I.e. does it make sense to take the difference in coherence between the two conditions and divide by the standard error? A shorter version of this question is: how does one test for a statistically significant coherence difference between two stimulus conditions in fieldtrip? Thanks, Dahlia. ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From j.schoffelen at PSY.GLA.AC.UK Tue Dec 1 09:03:12 2009 From: j.schoffelen at PSY.GLA.AC.UK (Jan-Mathijs Schoffelen) Date: Tue, 1 Dec 2009 09:03:12 +0100 Subject: single trial source signal In-Reply-To: <58ccc8240911301202j7c6a55e1w3cc8227ed18605e9@mail.gmail.com> Message-ID: Vasan, I feel that FieldTrip has the capability of extracting the single trial source signals. I think that MNE and LORETA do not fully support it yet, but in order to get there, you may have to hack the code a bit. With LCMV it is certainly possible. The only thing you have to do is specify cfg.keepfilter = 'yes' prior to sourceanalysis. The output to sourceanalysis will contain a field source.avg.filter, which contain per voxel the beamformer weights. You can get the single trial source data per voxel by doing something like this on the command line: singletrialvoxeldataofvoxelXintrialY = source.avg.filter{X} * data.trial{Y}. Et voilà. MNE and LORETA provide the projection matrix in one big shot, and as far as I know do not yet output the filt-matrix directly, but it should be possible to extract these from the functions and apply the same logic. Good luck, Jan-Mathijs On 30 Nov 2009, at 21:02, Sreenivasan Rajamoni Nadar wrote: > Dear FieldTrip users, > > I personally feel that the FieldTrip (latest version) does not seems > to having the capability to extract single trial source signals > using any of the the time domain beamformers: LCMV, MNE, SAM, > LORETA, RV or using the frequency domain beamformer methods like > DICS and PCC !! > > Please let me know if any of you made plugin codes to Fieldtrip to > get single trial source data? Robert, Could you let me know if there > is any other version which does the above? > > Thank you, > Vasan > > > > > > > > > > > ---------------------------------- > > The aim of this list is to facilitate the discussion between users > of the FieldTrip toolbox, to share experiences and to discuss new > ideas for MEG and EEG analysis. > > http://listserv.surfnet.nl/archives/fieldtrip.html > > http://www.ru.nl/fcdonders/fieldtrip/ > ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From jan.schoffelen at DONDERS.RU.NL Tue Dec 1 08:57:53 2009 From: jan.schoffelen at DONDERS.RU.NL (jan-mathijs schoffelen) Date: Tue, 1 Dec 2009 08:57:53 +0100 Subject: t statistic of coherence difference between stimulus conditions In-Reply-To: Message-ID: Dear Dahlia, Your question has been asked before, so it may be worthwile to browse the archive of the mailing list a bit. In short, the way to go depends on what you want: 1) Do you want to test for significance within a subject? Then it may be worthwhile to have a look at Maris et al 2007 J.Neurosci.Methods. Here we describe a way to test for significant coherence differences using permutation tests. 2) If you want to test for significance across subjects (which I generally prefer), I would compute the coherence difference per subject and apply a Z-transformation to the difference. Subsequently I do a permutation test across subjects. By randomly swapping the sign of the Z-transformed difference you obtain a distribution under the null-hypothesis, i.e. no difference in coherence across subjects. (for a formulation of the z-statistic you can have a look at the Maris paper). Both options are possible in fieldtrip, but it may require some coding yourself. Best wishes, Jan-Mathijs On 1 Dec 2009, at 00:33, Dahlia Sharon wrote: > Hi, > > Since the coherence spectrum is different from the power spectrum in > not > being a simple average over trials, I am wondering how the point-by- > point > statistic should be calculated. I.e. does it make sense to take the > difference in coherence between the two conditions and divide by the > standard error? > > A shorter version of this question is: how does one test for a > statistically > significant coherence difference between two stimulus conditions in > fieldtrip? > > Thanks, > Dahlia. > > ---------------------------------- > The aim of this list is to facilitate the discussion between users > of the FieldTrip toolbox, to share experiences and to discuss new > ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html > and http://www.ru.nl/neuroimaging/fieldtrip. > Dr. J.M. (Jan-Mathijs) Schoffelen Donders Institute for Brain, Cognition and Behaviour, Centre for Cognitive Neuroimaging, Radboud University Nijmegen, The Netherlands J.Schoffelen at donders.ru.nl Telephone: 0031-24-3668063 ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From Hanneke.vanDijk at MED.UNI-DUESSELDORF.DE Tue Dec 1 11:59:38 2009 From: Hanneke.vanDijk at MED.UNI-DUESSELDORF.DE (Hanneke Van Dijk) Date: Tue, 1 Dec 2009 11:59:38 +0100 Subject: single trial source signal Message-ID: Dear Vasan, I also feel single-trial source-analysis does work, I have done it and published it J Neurosci (using pcc for just power data). The problem as you sent it in the mail below is that the cfg.grid.pos that you entered is not inside your headmodel: 0 dipoles inside, 1 dipoles outside brain There wil not be any data in there. You could try to plot the functional data interpolated on the mri with cfg.interactive = 'yes'; and then click on the location you want to do the single-trial analysis on. The coordinates will be printed in the workspace. These can be entered in cfg.grid.pos. If you have any more questions could you then send the cfg you used as well? This might give some hints as to what went wrong. It's just not the case that you can use some-one elses code and run your data through it. The choises you make for the data analysis depend a lot on the kind of data and what you want to do. But this mailing list is there to help you allong the way! Hope it helps, Best, Hanneke -----Oorspronkelijk bericht----- Van: van Dijk, Hanneke Verzonden: zo 29.11.2009 09:38 Aan: FieldTrip discussion list Onderwerp: RE: [FIELDTRIP] single trial source signal Dear Vasan, Since I don't know exactly how far you are in doing the analysis, I just send you the basic script that shows the most important parameters. Don't forget to do freqanalysis with cfg.output = 'fourier' and cfg.method = 'mtmfft' for the specific frequency (cfg.foilim) you want to focus on. cfg = []; cfg.grid.pos = location of source coordinate;% [x y z] to fill in cfg.frequency = frequency of interest; cfg.vol = headmodel; %to make yourself see http://fieldtrip.fcdonders.nl/example/make_leadfields_using_different_headmodels cfg.projectnoise = 'yes';%to compute the neural activity index using sourcedescriptives cfg.lambda = '10%';%the amount of noice to estimate estimated cfg.method = 'pcc'; cfg.keeptrials = 'yes'; Virtual_channeldata = sourceanalysis(cfg,freq); You can do sourcedescriptives after that. 'help freqanalysis', 'help sourceanalysis' and 'help sourcedescriptives' should also help you further. Or you could have a look at the fieldtrip website. There are a lot of options to taylor the analysis to your data. Hope this helps! Best, Hanneke van Dijk ------------------------------------------------------------ Institute for Clinical Neuroscience and Medical Psychology Heinrich Heine Universitaet, Duesseldorf, Germany ------------------------------------------------------------ -----Oorspronkelijk bericht----- Van: FieldTrip discussion list namens Rajamoni Nadar, Sreenivasan (NIH/NIMH) [E] Verzonden: do 26.11.2009 14:53 Aan: FIELDTRIP at NIC.SURFNET.NL Onderwerp: [FIELDTRIP] single trial source signal FieldTrip Users, Is it possible to get single trial source signal using FieldTrip? I would appreciate if anybody could provide code for the same. Thank you, Vasan ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From sreenivasan.r.nadar at GMAIL.COM Tue Dec 1 17:20:24 2009 From: sreenivasan.r.nadar at GMAIL.COM (Sreenivasan Rajamoni Nadar) Date: Tue, 1 Dec 2009 11:20:24 -0500 Subject: single trial source signal In-Reply-To: <72E993C35FB11743B79FF9286E5B6D8B0F353C@Mail2-UKD.VMED.UKD> Message-ID: Dear Hanneke and FieldTripers, Thank you Hanneke. I extracted the single trial source signal using a time domain beamformer Please find below the script: clear all ds = sprintf('/rajamoni/MEG_ds/AEDTPJOU_nback_20050422_01-f.ds') cfg = []; cfg.dataset = ds; cfg.trialdef.eventtype = '?'; definetrial(cfg); cfg.trialdef.eventtype = 'r0'; cfg.trialdef.prestim = 0.25; cfg.trialdef.poststim = 0.25; cfg = definetrial(cfg); data = preprocessing(cfg); %~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ cfg.channel = {'MEG','-MRF43', '-MRO13'}; cfg.latency = [-0.25 0.25]; cfg.covariance = 'yes'; cfg.covariancewindow = [-0.0 0.25]; cfg.keeptrials = 'yes'; cfg.blcwindow = [-0.25 0.25]; cfg.bpfreq = [1 60]; [timelock] = timelockanalysis(cfg,data); %~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ctf_ss = read_ctf_hdm('/rajamoni/AEDTPJOU_nback_20050422_01-f.ds/default.hdm'); cfg = []; cfg.method = 'lcmv'; %'rv'; %'mvl', % 'pcc'; 'loreta'; %'mne'; cfg.grid.pos = [7.3 -3.9 3.9; 7.7 1.8,4.0]; %arbitrary source location cfg.singletrial = 'yes'; cfg.rawtrial = 'no'; cfg.keepfilter = 'yes'; cfg.keepmom = 'yes'; %cfg.hdmfile = strcat(ds, '/default.hdm'); cfg.channel = {'MEG','-MRF43', '-MRO13'}; cfg.vol = ctf_ss; [source] = sourceanalysis(cfg, timelock); % extraction of single trial source signals % %for trial all trials for i=1:66 trial{i}=source.trial(i).mom{1}; % 1 for the 1st source location and |||ly you could do for other source coord trial{i}=sqrt((sum(trial{i}.*trial{i}))); end; %~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ It seems to be working. I will report the other methods using freqanalysis after play with the FieldTrip for a while!! Any comments? -Vasan On Tue, Dec 1, 2009 at 4:28 AM, wrote: > Dear Vasan, > > I also feel single-trial source-analysis does work, I have done it and > published it J Neurosci (using pcc for just power data). > > The problem as you sent it in the mail below is that the cfg.grid.pos that > you entered is not inside your headmodel: > > 0 dipoles inside, 1 dipoles outside brain > > There wil not be any data in there. You could try to plot the functional > data interpolated on the mri with cfg.interactive = 'yes'; and then click on > the location you want to do the single-trial analysis on. The coordinates > will be printed in the workspace. These can be entered in cfg.grid.pos. > > If you have any more questions could you then send the cfg you used as > well? This might give some hints as to what went wrong. > > It's just not the case that you can use some-one elses code and run your > data through it. The choises you make for the data analysis depend a lot on > the kind of data and what you want to do. > But this mailing list is there to help you allong the way! > > Hope it helps, > > Best, Hanneke > > > > -----Oorspronkelijk bericht----- > Van: Sreenivasan Rajamoni Nadar [mailto:sreenivasan.r.nadar at gmail.com > ] > Verzonden: ma 30.11.2009 16:21 > Aan: van Dijk, Hanneke > Onderwerp: Re: [FIELDTRIP] single trial source signal > > > Dear Hanneke, > > I did the freq analysis and source analysis as suggested by you. I get the > following error: > > the input is freq data with 273 channels, 30 frequencybins and no timebins > using headmodel specified in the configuration > using gradiometers specified in the configuration > creating dipole grid based on user specified dipole positions > 0 dipoles inside, 1 dipoles outside brain > ??? Error using ==> nearest>mbscalar at 47 > Argument to mbscalar must be scalar > > Error in ==> nearest at 15 > mbscalar(val); > > Error in ==> prepare_freq_matrices at 72 > fbin = nearest(freq.freq, cfg.frequency); > > Error in ==> sourceanalysis at 359 > [Cf, Cr, Pr, Ntrials, tmpcfg] = prepare_freq_matrices(tmpcfg, data); > > ~~~~~~~~~~~~~~~~~~~~~~~ > > Do you know the way to fix it? > > Thanks, Vasan > > > > > On Sun, Nov 29, 2009 at 3:38 AM, Hanneke Van Dijk < > Hanneke.vanDijk at med.uni-duesseldorf.de> wrote: > > > Dear Vasan, > > > > Since I don't know exactly how far you are in doing the analysis, I just > > send you the basic script that shows the most important parameters. Don't > > forget to do freqanalysis with cfg.output = 'fourier' and cfg.method = > > 'mtmfft' for the specific frequency (cfg.foilim) you want to focus on. > > > > cfg = []; > > cfg.grid.pos = location of source coordinate;% [x y z] to fill in > > cfg.frequency = frequency of interest; > > cfg.vol = headmodel; %to make yourself see > > > http://fieldtrip.fcdonders.nl/example/make_leadfields_using_different_headmodels > > cfg.projectnoise = 'yes';%to compute the neural activity index using > > sourcedescriptives > > cfg.lambda = '10%';%the amount of noice to estimate estimated > > cfg.method = 'pcc'; > > cfg.keeptrials = 'yes'; > > Virtual_channeldata = sourceanalysis(cfg,freq); > > > > You can do sourcedescriptives after that. > > > > 'help freqanalysis', 'help sourceanalysis' and 'help sourcedescriptives' > > should also help you further. Or you could have a look at the fieldtrip > > website. There are a lot of options to taylor the analysis to your data. > > > > Hope this helps! > > > > Best, > > > > Hanneke van Dijk > > > > ------------------------------------------------------------ > > Institute for Clinical Neuroscience and Medical Psychology > > Heinrich Heine Universitaet, Duesseldorf, Germany > > ------------------------------------------------------------ > > > > -----Oorspronkelijk bericht----- > > Van: FieldTrip discussion list namens Rajamoni Nadar, Sreenivasan > > (NIH/NIMH) [E] > > Verzonden: do 26.11.2009 14:53 > > Aan: FIELDTRIP at NIC.SURFNET.NL > > Onderwerp: [FIELDTRIP] single trial source signal > > > > FieldTrip Users, > > > > Is it possible to get single trial source signal using FieldTrip? I would > > appreciate if anybody could provide code for the same. > > > > Thank you, > > Vasan > > ---------------------------------- > > The aim of this list is to facilitate the discussion between users of the > > FieldTrip toolbox, to share experiences and to discuss new ideas for MEG > > and EEG analysis. See also > > http://listserv.surfnet.nl/archives/fieldtrip.html and > > http://www.ru.nl/neuroimaging/fieldtrip. > > > > > > ---------------------------------- > > The aim of this list is to facilitate the discussion between users of the > > FieldTrip toolbox, to share experiences and to discuss new ideas for MEG > > and EEG analysis. See also > > http://listserv.surfnet.nl/archives/fieldtrip.html and > > http://www.ru.nl/neuroimaging/fieldtrip. > > > > > ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From gsudre at POBOX.COM Tue Dec 1 17:24:48 2009 From: gsudre at POBOX.COM (Gustavo Sudre) Date: Tue, 1 Dec 2009 11:24:48 -0500 Subject: source localization of frequency bands Message-ID: Hello, I have a generic question about source localization. From what I've seen so far, when the goal is to localize the activity in certain frequency bands, it's common to use methods such as DICS or the variant of MCE for frequency bands. I was wondering if it is also correct to do source localization using a different method (e.g. MNE) with the whole signal (i.e. prior to band-pass filtering to specific bands) and then convert the signal in the localized sources to frequency domain. Another alternative would be to band-pass the signal to a certain frequency band in source space, and then run a different source localization method on it (e.g. MNE). Could anyone elaborate on the advantages / disadvantages ( / validity) of these two methods? Thank you, Gus ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From Jan.Hirschmann at MED.UNI-DUESSELDORF.DE Thu Dec 3 17:00:07 2009 From: Jan.Hirschmann at MED.UNI-DUESSELDORF.DE (Jan Hirschmann) Date: Thu, 3 Dec 2009 17:00:07 +0100 Subject: minor problem loading fiff file Message-ID: Hi, this is my very first day with fieldtrip so there is some chance that the error is due to the user rather than to the code... Anyways, I had the following problem. I loaded a fif file using preprocessing which did not start a time 0 but later. I got an a error from the mne function fiff_read_raw_segment saying that there is no data in this range. I tried to define the trial differently setting trl in different ways but it didn't help so I looked at the code. Preprocessing calls the function read_header which said that nSamplesPre were -6031500 in my case. So I guess this means that there are samples missing between a trigger (I don"t know which) and the start of the file. Later in preprocessing the function read_data calls fiff_read_raw_segment with the following arguments: read_data.m, line 691.m: dat = fiff_read_raw_segment(hdr.orig.raw,begsample+hdr.nSamplesPre-1,endsample+hdr.nSamplesPre-1,chanindx); Thus fiff_read_raw_segment is launched with negative to and from values which finally causes the error. nSamples should have been subtracted here and not added (it is a negative integer). I would suggest that in the future the call to the function should be only with arguments coming from the header file, i.e. from = hdr.orig.raw.last_samp and to = hdr.orig.raw.first_samp or that the pluses in the quoted line should be changed to minuses (which I did now in my version). However, I don't know if my file is strange (neg nSamplesPre) or if the code has a bug. Hope this helps anyone Best, Jan ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From fredericroux at HOTMAIL.DE Fri Dec 4 12:50:58 2009 From: fredericroux at HOTMAIL.DE (Frederic Roux) Date: Fri, 4 Dec 2009 12:50:58 +0100 Subject: interpolated source activity values = NaN Message-ID: Hi everyone, I would like to use the values that correspond to the interpolated statistics at source level. The problem is that most of these values are NaNs, even tough I can visualize them with sourceplot. Here are the steps I am doing to compute these values: [signal1] = sourcegrandaverage(cfg,data); [signal2] = sourcegrandaverage(cfg,data); [Stats] = sourcestatistics(cfg,signal1,signal2);%the statistics used here is depsamplesT using fdr and clusterstatistics = maxsum [SourceInterpolatedSats] = sourceinterpolate(cfg,Stats,template_mri); This yields: SourceInterpolatedSats = inside: [91x109x91 logical] stat: [91x109x91 double] dim: [91 109 91] transform: [4x4 double] anatomy: [91x109x91 double] cfg: [1x1 struct] But when I try : SourceInterpolatedStats.stat([20 45 68]) = NaN. And this holds true for almost any index. Does anyone know if it's possible to access these values? Frederic _________________________________________________________________ http://redirect.gimas.net/?n=M0912xIWHM2 Hotmail - Mein E-Mail Anbieter ohne Kosten ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From ingrid.nieuwenhuis at FCDONDERS.RU.NL Fri Dec 4 13:21:17 2009 From: ingrid.nieuwenhuis at FCDONDERS.RU.NL (Ingrid Nieuwenhuis) Date: Fri, 4 Dec 2009 13:21:17 +0100 Subject: interpolated source activity values = NaN In-Reply-To: Message-ID: Hi Frederic, Probably the NaN's are the voxels outside the brain. The source estimate is only performed for voxels inside the brain, the voxels outside are put to NaN. In the field "inside" it is coded which voxels lay inside the brain. Try: SourceInterpolatedStats.stat(SourceInterpolatedStats.inside) This should give you the non-NaN values. Hope this helps, Ingrid _____ From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of Frederic Roux Sent: Friday, December 04, 2009 12:51 PM To: FIELDTRIP at NIC.SURFNET.NL Subject: [FIELDTRIP] interpolated source activity values = NaN Hi everyone, I would like to use the values that correspond to the interpolated statistics at source level. The problem is that most of these values are NaNs, even tough I can visualize them with sourceplot. Here are the steps I am doing to compute these values: [signal1] = sourcegrandaverage(cfg,data); [signal2] = sourcegrandaverage(cfg,data); [Stats] = sourcestatistics(cfg,signal1,signal2);%the statistics used here is depsamplesT using fdr and clusterstatistics = maxsum [SourceInterpolatedSats] = sourceinterpolate(cfg,Stats,template_mri); This yields: SourceInterpolatedSats = inside: [91x109x91 logical] stat: [91x109x91 double] dim: [91 109 91] transform: [4x4 double] anatomy: [91x109x91 double] cfg: [1x1 struct] But when I try : SourceInterpolatedStats.stat([20 45 68]) = NaN. And this holds true for almost any index. Does anyone know if it's possible to access these values? Frederic _____ Alle E-Mail-Adressen online auf einen Blick Ich will Hotmail! ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From fredericroux at HOTMAIL.DE Fri Dec 4 14:50:39 2009 From: fredericroux at HOTMAIL.DE (Frederic Roux) Date: Fri, 4 Dec 2009 14:50:39 +0100 Subject: interpolated source activity values = NaN In-Reply-To: <20091204122107.4BEE5EC09D@smtp.ru.nl> Message-ID: Hi Ingrid, thanks for the quick reply. I will try your suggestion but I am pretty much sure that the values I want to look at are inside the brain. My approach is the following: I want to indentify the voxels that show significant activation. So first I visualized my data with sourceplot and cfg.interactive = 'yes' and then I write down the indices of the voxels onto which I click. When I feed these indices into SourceInterpolatedStats.stat([x y z]) this returns me NaNs, even tough the voxel was clearly located inside the brain. Do you have any idea of why this happens? Frederic Date: Fri, 4 Dec 2009 13:21:17 +0100 From: ingrid.nieuwenhuis at FCDONDERS.RU.NL Subject: Re: [FIELDTRIP] interpolated source activity values = NaN To: FIELDTRIP at NIC.SURFNET.NL Hi Frederic, Probably the NaN’s are the voxels outside the brain. The source estimate is only performed for voxels inside the brain, the voxels outside are put to NaN. In the field “inside” it is coded which voxels lay inside the brain. Try: SourceInterpolatedStats.stat(SourceInterpolatedStats.inside) This should give you the non-NaN values. Hope this helps, Ingrid From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of Frederic Roux Sent: Friday, December 04, 2009 12:51 PM To: FIELDTRIP at NIC.SURFNET.NL Subject: [FIELDTRIP] interpolated source activity values = NaN Hi everyone, I would like to use the values that correspond to the interpolated statistics at source level. The problem is that most of these values are NaNs, even tough I can visualize them with sourceplot. Here are the steps I am doing to compute these values: [signal1] = sourcegrandaverage(cfg,data); [signal2] = sourcegrandaverage(cfg,data); [Stats] = sourcestatistics(cfg,signal1,signal2);%the statistics used here is depsamplesT using fdr and clusterstatistics = maxsum [SourceInterpolatedSats] = sourceinterpolate(cfg,Stats,template_mri); This yields: SourceInterpolatedSats = inside: [91x109x91 logical] stat: [91x109x91 double] dim: [91 109 91] transform: [4x4 double] anatomy: [91x109x91 double] cfg: [1x1 struct] But when I try : SourceInterpolatedStats.stat([20 45 68]) = NaN. And this holds true for almost any index. Does anyone know if it's possible to access these values? Frederic Alle E-Mail-Adressen online auf einen Blick Ich will Hotmail! ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ _________________________________________________________________ http://redirect.gimas.net/?n=M0912xXMasGreetings2 Nie mehr um Weihnachtsgrüße verlegen: mit tollen Weihnachts-E-Mails ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From ingrid.nieuwenhuis at FCDONDERS.RU.NL Fri Dec 4 14:58:23 2009 From: ingrid.nieuwenhuis at FCDONDERS.RU.NL (Ingrid Nieuwenhuis) Date: Fri, 4 Dec 2009 14:58:23 +0100 Subject: interpolated source activity values = NaN In-Reply-To: Message-ID: Dear Frederic, Could it be that you wrote down the indices of the voxels before interpolating? Since the voxels before interpolating do not match anymore after interpolating onto the template_mri. Best, Ingrid _____ From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of Frederic Roux Sent: Friday, December 04, 2009 2:51 PM To: FIELDTRIP at NIC.SURFNET.NL Subject: Re: [FIELDTRIP] interpolated source activity values = NaN Hi Ingrid, thanks for the quick reply. I will try your suggestion but I am pretty much sure that the values I want to look at are inside the brain. My approach is the following: I want to indentify the voxels that show significant activation. So first I visualized my data with sourceplot and cfg.interactive = 'yes' and then I write down the indices of the voxels onto which I click. When I feed these indices into SourceInterpolatedStats.stat([x y z]) this returns me NaNs, even tough the voxel was clearly located inside the brain. Do you have any idea of why this happens? Frederic _____ Date: Fri, 4 Dec 2009 13:21:17 +0100 From: ingrid.nieuwenhuis at FCDONDERS.RU.NL Subject: Re: [FIELDTRIP] interpolated source activity values = NaN To: FIELDTRIP at NIC.SURFNET.NL Hi Frederic, Probably the NaN’s are the voxels outside the brain. The source estimate is only performed for voxels inside the brain, the voxels outside are put to NaN. In the field “inside” it is coded which voxels lay inside the brain. Try: SourceInterpolatedStats.stat(SourceInterpolatedStats.inside) This should give you the non-NaN values. Hope this helps, Ingrid _____ From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of Frederic Roux Sent: Friday, December 04, 2009 12:51 PM To: FIELDTRIP at NIC.SURFNET.NL Subject: [FIELDTRIP] interpolated source activity values = NaN Hi everyone, I would like to use the values that correspond to the interpolated statistics at source level. The problem is that most of these values are NaNs, even tough I can visualize them with sourceplot. Here are the steps I am doing to compute these values: [signal1] = sourcegrandaverage(cfg,data); [signal2] = sourcegrandaverage(cfg,data); [Stats] = sourcestatistics(cfg,signal1,signal2);%the statistics used here is depsamplesT using fdr and clusterstatistics = maxsum [SourceInterpolatedSats] = sourceinterpolate(cfg,Stats,template_mri); This yields: SourceInterpolatedSats = inside: [91x109x91 logical] stat: [91x109x91 double] dim: [91 109 91] transform: [4x4 double] anatomy: [91x109x91 double] cfg: [1x1 struct] But when I try : SourceInterpolatedStats.stat([20 45 68]) = NaN. And this holds true for almost any index. Does anyone know if it's possible to access these values? Frederic _____ Alle E-Mail-Adressen online auf einen Blick Ich will Hotmail! ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ _____ Nie mehr um Weihnachtsgrüße verlegen: mit tollen Weihnachts-E-Mails ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From fredericroux at HOTMAIL.DE Fri Dec 4 15:06:10 2009 From: fredericroux at HOTMAIL.DE (Frederic Roux) Date: Fri, 4 Dec 2009 15:06:10 +0100 Subject: interpolated source activity values = NaN In-Reply-To: <20091204135813.EF177EC2BD@smtp.ru.nl> Message-ID: Actually I don't think so. I first computed the sourcestatistics. Then I interpolated the Stats and visualized them with sourceplot and cfg.interactive = yes. Frederic Date: Fri, 4 Dec 2009 14:58:23 +0100 From: ingrid.nieuwenhuis at FCDONDERS.RU.NL Subject: Re: [FIELDTRIP] interpolated source activity values = NaN To: FIELDTRIP at NIC.SURFNET.NL Dear Frederic, Could it be that you wrote down the indices of the voxels before interpolating? Since the voxels before interpolating do not match anymore after interpolating onto the template_mri. Best, Ingrid From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of Frederic Roux Sent: Friday, December 04, 2009 2:51 PM To: FIELDTRIP at NIC.SURFNET.NL Subject: Re: [FIELDTRIP] interpolated source activity values = NaN Hi Ingrid, thanks for the quick reply. I will try your suggestion but I am pretty much sure that the values I want to look at are inside the brain. My approach is the following: I want to indentify the voxels that show significant activation. So first I visualized my data with sourceplot and cfg.interactive = 'yes' and then I write down the indices of the voxels onto which I click. When I feed these indices into SourceInterpolatedStats.stat([x y z]) this returns me NaNs, even tough the voxel was clearly located inside the brain. Do you have any idea of why this happens? Frederic Date: Fri, 4 Dec 2009 13:21:17 +0100 From: ingrid.nieuwenhuis at FCDONDERS.RU.NL Subject: Re: [FIELDTRIP] interpolated source activity values = NaN To: FIELDTRIP at NIC.SURFNET.NL Hi Frederic, Probably the NaN’s are the voxels outside the brain. The source estimate is only performed for voxels inside the brain, the voxels outside are put to NaN. In the field “inside” it is coded which voxels lay inside the brain. Try: SourceInterpolatedStats.stat(SourceInterpolatedStats.inside) This should give you the non-NaN values. Hope this helps, Ingrid From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of Frederic Roux Sent: Friday, December 04, 2009 12:51 PM To: FIELDTRIP at NIC.SURFNET.NL Subject: [FIELDTRIP] interpolated source activity values = NaN Hi everyone, I would like to use the values that correspond to the interpolated statistics at source level. The problem is that most of these values are NaNs, even tough I can visualize them with sourceplot. Here are the steps I am doing to compute these values: [signal1] = sourcegrandaverage(cfg,data); [signal2] = sourcegrandaverage(cfg,data); [Stats] = sourcestatistics(cfg,signal1,signal2);%the statistics used here is depsamplesT using fdr and clusterstatistics = maxsum [SourceInterpolatedSats] = sourceinterpolate(cfg,Stats,template_mri); This yields: SourceInterpolatedSats = inside: [91x109x91 logical] stat: [91x109x91 double] dim: [91 109 91] transform: [4x4 double] anatomy: [91x109x91 double] cfg: [1x1 struct] But when I try : SourceInterpolatedStats.stat([20 45 68]) = NaN. And this holds true for almost any index. Does anyone know if it's possible to access these values? Frederic Alle E-Mail-Adressen online auf einen Blick Ich will Hotmail! ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ Nie mehr um Weihnachtsgrüße verlegen: mit tollen Weihnachts-E-Mails ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ _________________________________________________________________ http://redirect.gimas.net/?n=M0912xXMasGreetings2 Nie mehr um Weihnachtsgrüße verlegen: mit tollen Weihnachts-E-Mails ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From fredericroux at HOTMAIL.DE Fri Dec 4 15:17:06 2009 From: fredericroux at HOTMAIL.DE (Frederic Roux) Date: Fri, 4 Dec 2009 15:17:06 +0100 Subject: problem solved Message-ID: The solution to my problem is: SourceInterpolatedSats(Voxel) and not SourceInterpolatedStats([x y z]). Thanks for helping. Frederic _________________________________________________________________ http://redirect.gimas.net/?n=M0912xIE2 Internet Explorer aktualisieren – sicher im Internet! ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From lhunt at FMRIB.OX.AC.UK Sun Dec 6 23:47:58 2009 From: lhunt at FMRIB.OX.AC.UK (Laurence Hunt) Date: Sun, 6 Dec 2009 22:47:58 +0000 Subject: minor problem loading fiff file In-Reply-To: <72E993C35FB11743B79FF9286E5B6D8BA2E4F4@Mail2-UKD.VMED.UKD> Message-ID: Hi Jan, Thanks for the example file. It looks like a change was made to read_header after I initally wrote it, which was to take the first_samp field from fiff_setup_read_raw (called in read_header), and make this negative rather than positive (line 817 of read_header). This is causing read_data to crash. @Robert, could we either change read_header back, or change read_data with the amendment suggested by Jan? Basically first_samp (returned by fiff_setup_read_raw) can be positive or negative, I think depending upon how the recording is made - but more positive numbers mean further forward in time, and more negative numbers further backward. If fieldtrip typically makes nSamplesPre always increase positively as we go backwards in time, then we would need to make the change Jan suggested in line 691 of read_data (and anywhere else that depends on nSamplesPre in the neuromag_mne code). Cheers, Laurence =========================================== Laurence Hunt, DPhil Student Centre for Functional MRI of the Brain (FMRIB), University of Oxford lhunt at fmrib.ox.ac.uk Phone: (+44)1865-(2)22738 =========================================== On 4 Dec 2009, at 12:24, wrote: > Hi Laurence, > > I did not upload my data to the server but I am sending you the > first few seconds of my file with this mail. For me the error occurs > with this file, too. With the changes I have suggested everything > seems fine. > > Best, > > Jan > > ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From e.glerean at GMAIL.COM Tue Dec 8 13:10:54 2009 From: e.glerean at GMAIL.COM (Enrico Glerean) Date: Tue, 8 Dec 2009 14:10:54 +0200 Subject: private/senslabel.m missing on latest builds? Message-ID: Hello developers of FT, hopefully this is the best place for these kind of notifications. In the latest builds of FT the function private/senslabel.m is not there anymore. This throws errors such: ??? Undefined function or method 'senslabel' for input arguments of type 'char'. Error in ==> channelselection at 96 label1020 = senslabel('eeg1020'); % use external helper function Error in ==> preprocessing at 306 cfg.channel = channelselection(cfg.channel, hdr.label); Error in ==> ft_test1 at 9 dataPrepro = preprocessing(cfg1); (This error was obtained by running a basic preprocessing script as in http://fieldtrip.fcdonders.nl/tutorial/introduction using Subject01.ds from your tutorial data). Please let me know when the function is back. thanks -- Enrico Glerean, MSc Researcher Department of Biomedical Engineering and Computational Science Helsinki University of Technology ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From r.oostenveld at FCDONDERS.RU.NL Tue Dec 8 21:49:34 2009 From: r.oostenveld at FCDONDERS.RU.NL (Robert Oostenveld) Date: Tue, 8 Dec 2009 21:49:34 +0100 Subject: private/senslabel.m missing on latest builds? In-Reply-To: Message-ID: Dear Enrico, The senslabel function is now located elsewhere, in >> which senslabel.m /Users/robert/matlab/fieldtrip/forwinv/senslabel.m We try to avoid replicating functions, and this function (which used to be private) is now part of the public API of the forwinv module. That means that it does not have to be replicated any more in fieldtrip/private. If channelselection does not find it, then it seems that fieldtripdefs (which is called at the begin of channelselection) did not add the fieldtrip/forwinv directory correctly to your path. Could you try "clear all" and then "fieldtripdefs" and then "which senslabel"? Best regards, Robert ----------------------------------------------------------- Robert Oostenveld, PhD Senior Researcher Donders Institute for Brain, Cognition and Behaviour Centre for Cognitive Neuroimaging Radboud University Nijmegen tel.: +31 (0)24 3619695 e-mail: r.oostenveld at donders.ru.nl web: http://www.ru.nl/neuroimaging skype: r.oostenveld ----------------------------------------------------------- On 8 Dec 2009, at 13:10, Enrico Glerean wrote: > Hello developers of FT, > > hopefully this is the best place for these kind of notifications. In > the latest builds of FT the function private/senslabel.m > is not there anymore. This throws errors such: > > ??? Undefined function or method 'senslabel' for input arguments of type 'char'. > > Error in ==> channelselection at 96 > label1020 = senslabel('eeg1020'); % use external helper function > > Error in ==> preprocessing at 306 > cfg.channel = channelselection(cfg.channel, hdr.label); > > Error in ==> ft_test1 at 9 > dataPrepro = preprocessing(cfg1); > > > (This error was obtained by running a basic preprocessing script as in > http://fieldtrip.fcdonders.nl/tutorial/introduction using Subject01.ds > from your tutorial data). > > > Please let me know when the function is back. > thanks > > -- > Enrico Glerean, MSc > Researcher > Department of Biomedical Engineering and Computational Science > Helsinki University of Technology > > ---------------------------------- > The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. > ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From e.glerean at GMAIL.COM Wed Dec 9 08:40:55 2009 From: e.glerean at GMAIL.COM (Enrico Glerean) Date: Wed, 9 Dec 2009 09:40:55 +0200 Subject: private/senslabel.m missing on latest builds? In-Reply-To: Message-ID: Hello Robert thanks for this. There was a path conflict with EEGLAB (which also had an entry for the forwinv toolbox in its external/fieldtrip folder), hence the hastoolbox('forwinv', 1, 1); command on fieldtripdefs did not add the correct forwinv. Now everything seems fine again. Best -- Enrico Glerean, MSc Researcher Department of Biomedical Engineering and Computational Science Helsinki University of Technology 2009/12/8 Robert Oostenveld : > Dear Enrico, > The senslabel function is now located elsewhere, in >>> which senslabel.m > /Users/robert/matlab/fieldtrip/forwinv/senslabel.m > We try to avoid replicating functions, and this function (which used to be > private) is now part of the public API of the forwinv module. That means > that it does not have to be replicated any more in fieldtrip/private. > If channelselection does not find it, then it seems that fieldtripdefs > (which is called at the begin of channelselection) did not add the > fieldtrip/forwinv directory correctly to your path. Could you try "clear > all" and then "fieldtripdefs" and then "which senslabel"? > Best regards, > Robert > ----------------------------------------------------------- > Robert Oostenveld, PhD > Senior Researcher > Donders Institute for Brain, Cognition and Behaviour > Centre for Cognitive Neuroimaging > Radboud University Nijmegen > tel.: +31 (0)24 3619695 > e-mail: r.oostenveld at donders.ru.nl > web: http://www.ru.nl/neuroimaging > skype: r.oostenveld > ----------------------------------------------------------- > > On 8 Dec 2009, at 13:10, Enrico Glerean wrote: > > Hello developers of FT, > > hopefully this is the best place for these kind of notifications. In > the latest builds of FT the function private/senslabel.m > is not there anymore. This throws errors such: > > ??? Undefined function or method 'senslabel' for input arguments of type > 'char'. > > Error in ==> channelselection at 96 > label1020 = senslabel('eeg1020'); % use external helper function > > Error in ==> preprocessing at 306 >  cfg.channel = channelselection(cfg.channel, hdr.label); > > Error in ==> ft_test1 at 9 > dataPrepro   = preprocessing(cfg1); > > > (This error was obtained by running a basic preprocessing script as in > http://fieldtrip.fcdonders.nl/tutorial/introduction using Subject01.ds > from your tutorial data). > > > Please let me know when the function is back. > thanks > > -- > Enrico Glerean, MSc > Researcher > Department of Biomedical Engineering and Computational Science > Helsinki University of Technology > > ---------------------------------- > The aim of this list is to facilitate the discussion between users of the > FieldTrip  toolbox, to share experiences and to discuss new ideas for MEG > and EEG analysis. See also > http://listserv.surfnet.nl/archives/fieldtrip.html and > http://www.ru.nl/neuroimaging/fieldtrip. > > > ---------------------------------- > > The aim of this list is to facilitate the discussion between users of the > FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and > EEG analysis. > > http://listserv.surfnet.nl/archives/fieldtrip.html > > http://www.ru.nl/fcdonders/fieldtrip/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From d.gupta at DONDERS.RU.NL Wed Dec 9 12:09:23 2009 From: d.gupta at DONDERS.RU.NL (Disha Gupta) Date: Wed, 9 Dec 2009 12:09:23 +0100 Subject: Common spatial patterns Message-ID: I was looking for documentation/tutorial for CSP in fieldtrip. I can see some documentation in the code at Files\MATLAB\R2008b\work\fieldtrip-20091114\classification\toolboxes\herman\csp\ If there is a fieldtrip tutorial I am missing out on, it will be very useful to know. Disha ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From Erin.Oakman at NYUMC.ORG Thu Dec 10 22:48:29 2009 From: Erin.Oakman at NYUMC.ORG (Oakman, Erin) Date: Thu, 10 Dec 2009 16:48:29 -0500 Subject: problem with freqstatistics Message-ID: Hi, I am following the cluster-based statistics tutorial called cluster_permutation_freq, "within trial experiments." When defining "baseline" and "activation" times with 1 subject, I have an error using redefinetrial to choose the nonoverlapping and equal length trials. For example, % redefine cfg = []; cfg.toilim = [-0.5 0]; data_baseline = redefinetrial(cfg, data); ??? Error using ==> redefinetrial at 66 the trial definition is inconsistent with the data Specifically, there is no trl field in my data. Somehow the trl field was lost after channelrepair and appenddata. However, it is possible to redefine the activation and baseline time manually. Then I make the time-frequency files on baseline and activation, and test with freqstatistics: %freqstatistics with cluster cfg=[]; cfg.method='montecarlo'; cfg.statistic= 'actvsblT'; cfg.parameter='powspctrm'; cfg.channel='all'; cfg.avgoverchan='no'; cfg.latency='all'; %[0.05 0.45]; cfg.avgovertime='no'; cfg.frequency=[39 41]; %'all'; cfg.avgoverfreq='yes'; cfg.correctm='cluster'; cfg.clusteralpha=0.05; cfg.clusterstatistic='maxsum'; cfg.elecfile='/home/eo/science/layout/biosemi.sfp'; cfg.neighbourdist=2.5; % cfg.minnbchan=2; %default=0 cfg.tail=0; %default=0 cfg.alpha=0.05; cfg.numrandomization=500; stat = freqstatistics(cfg, data_baseline, data_activation); ??? Undefined variable "data" or class "data.biol". Error in ==> prepare_design at 85 nrepl=size(data.biol,1); Error in ==> statistics_wrapper at 233 [cfg] = prepare_design(cfg); Error in ==> freqstatistics at 89 [stat, cfg] = statistics_wrapper(cfg, varargin{:}); The powspctrm field in data_baseline.powspctrm and data_activation.powspctrm is 4D (rptxchanxfreqxtime), and the rpt,freq,time, and label fields have the same dimensions. Do I have to use redefinetrial before freqanalysis? Any advice is appreciated. Erin ------------------------------------------------------------ This email message, including any attachments, is for the sole use of the intended recipient(s) and may contain information that is proprietary, confidential, and exempt from disclosure under applicable law. Any unauthorized review, use, disclosure, or distribution is prohibited. If you have received this email in error please notify the sender by return email and delete the original message. Please note, the recipient should check this email and any attachments for the presence of viruses. The organization accepts no liability for any damage caused by any virus transmitted by this email. ================================= ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From a.maye at UKE.DE Fri Dec 11 14:58:11 2009 From: a.maye at UKE.DE (Alexander Maye) Date: Fri, 11 Dec 2009 14:58:11 +0100 Subject: Warning: nanmean Message-ID: Dear List! If you install fieldtrip by adding the directory with subfolders, then read on. I just noticed that my scripts were using fieldtrip's nanmean function from the classification/utilities directory, which is not doing what it promises: Instead of ignoring NaNs it considers them as zeros. While this might make sense for the classification utilities, for most of the time it does not. If Matlab searches the fieldtrip folder only (no subfolders thereof), then the correct nanmean from the statistics toolbox is used. I couldn't find any instructions if the installation directory should be added to the Matlab path with or without the subfolders, so everyone might want to check which nanmean you use. Good luck, ALEX. -- Pflichtangaben gem�� Gesetz �ber elektronische Handelsregister und Genossenschaftsregister sowie das Unternehmensregister (EHUG): Universit�tsklinikum Hamburg-Eppendorf K�rperschaft des �ffentlichen Rechts Gerichtsstand: Hamburg Vorstandsmitglieder: Prof. Dr. J�rg F. Debatin (Vorsitzender) Dr. Alexander Kirstein Prof. Dr. Dr. Uwe Koch-Gromus ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From r.oostenveld at FCDONDERS.RU.NL Mon Dec 14 15:52:50 2009 From: r.oostenveld at FCDONDERS.RU.NL (Robert Oostenveld) Date: Mon, 14 Dec 2009 15:52:50 +0100 Subject: Warning: nanmean In-Reply-To: <200912111458.12036.a.maye@uke.de> Message-ID: Dear Alex, I also detected the buggy nanmean in the classification/utilities directory. They were fixed last week by Marcel and now contain the correct functions with a slightly different name. Please update your fieldtrip version to the most recent one. About the directory adding: please see http://fieldtrip.fcdonders.nl/faq/should_i_add_fieldtrip_with_all_subdirectories_to_my_matlab_path (which I just created). best regards, Robert On 11 Dec 2009, at 14:58, Alexander Maye wrote: > Dear List! > > If you install fieldtrip by adding the directory with subfolders, > then read > on. I just noticed that my scripts were using fieldtrip's nanmean > function > from the classification/utilities directory, which is not doing what > it > promises: Instead of ignoring NaNs it considers them as zeros. While > this > might make sense for the classification utilities, for most of the > time it > does not. > > If Matlab searches the fieldtrip folder only (no subfolders > thereof), then the > correct nanmean from the statistics toolbox is used. I couldn't find > any > instructions if the installation directory should be added to the > Matlab path > with or without the subfolders, so everyone might want to check which > nanmean you use. > > Good luck, > > ALEX. > > > > > > -- > Pflichtangaben gemäß Gesetz über elektronische Handelsregister und > Genossenschaftsregister sowie das Unternehmensregister (EHUG): > > Universitätsklinikum Hamburg-Eppendorf > Körperschaft des öffentlichen Rechts > Gerichtsstand: Hamburg > > Vorstandsmitglieder: > Prof. Dr. Jörg F. Debatin (Vorsitzender) > Dr. Alexander Kirstein > Prof. Dr. Dr. Uwe Koch-Gromus > > ---------------------------------- > The aim of this list is to facilitate the discussion between users > of the FieldTrip toolbox, to share experiences and to discuss new > ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html > and http://www.ru.nl/neuroimaging/fieldtrip. > ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From r.oostenveld at FCDONDERS.RU.NL Wed Dec 16 11:06:40 2009 From: r.oostenveld at FCDONDERS.RU.NL (Robert Oostenveld) Date: Wed, 16 Dec 2009 11:06:40 +0100 Subject: important: all fieldtrip functions will be renamed to ft_xxx Message-ID: Dear FieldTrip users As some of you may know, Matlab (and specifically the older versions that we still support) does not have a good way of separating functions in different toolboxes from each other. The fieldtrip version of preprocessing (or read_data) might be completely different from a function with the same name in another toolbox. That is not a problem for some of the unusual function names, but some function names like "preprocessing" are very generic and therefore likely to be used in completely different contexts. After repeated discussion with the developers of the SPM Matlab toolbox, we have decided to start adopting the same naming scheme that SPM is using. That naming scheme consists of prefixing the function name with the name of the toolbox, e.g. spm_contrasts. The prefix that FieldTrip will use is "ft_". So that means that the FieldTrip preprocessing function will be renamed into ft_preprocessing, sourceanalysis will become ft_sourceanalysis, freqanalysis will become ft_freqanalysis, etc. This will affect all publicly available FieldTrip functions, i.e. the main functions that you are using. The advantage of this change in function names is that it further facilitates the already very good collaboration of the FieldTrip project with other EEG/MEG method development groups, such as SPM, EEGLAB, BrainStorm and others. Note that this is not an easy choice to make and we have carefully considered the consequences. Of course all users have existing scripts that use the old function names. We will do our utmost best to ensure that your old scripts will remain functional, also with new versions of the fieldtrip toolbox. To make this possible, we will provide backward compatibility wrappers, e.g. there will be a preprocessing.m function that calls ft_preprocessing.m and the likes. Not only the existing analysis scripts are affected, but also the documentation on the fieldtrip wiki will have to be updated. Furthermore, fieldtrip functions often call each other, which means that inside the fieldtrip functions the function names also have to be changed. On the short time scale, we will provide backward compatibility wrapper functions. On the medium time scale, we will ensure that the fieldtrip code and documentation is internally consistent. On the long run everyone (which includes you!) should adopt the new function names. Please start using these new function names in your scripts and in your derived functions as soon as possible. At a certain point in the future, the backward compatibility to the old/current function names will be removed from the fieldtrip release, so by that time all of your scripts should only be using the new function names, otherwise they won't work any more. The backward compatibility will be ensured throughout 2010, i.e. for a full year. Usually we are able to maintain backward compatibility for a much longer time, so probably you should not have to worry about this too much. best regards, Robert ----------------------------------------------------------- Robert Oostenveld, PhD Senior Researcher Donders Institute for Brain, Cognition and Behaviour Centre for Cognitive Neuroimaging Radboud University Nijmegen tel.: +31 (0)24 3619695 e-mail: r.oostenveld at donders.ru.nl web: http://www.ru.nl/neuroimaging skype: r.oostenveld ----------------------------------------------------------- ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From r.oostenveld at FCDONDERS.RU.NL Wed Dec 16 12:11:21 2009 From: r.oostenveld at FCDONDERS.RU.NL (Robert Oostenveld) Date: Wed, 16 Dec 2009 12:11:21 +0100 Subject: important: all fieldtrip functions will be renamed to ft_xxx In-Reply-To: <057247EE-D280-45B9-8DD9-D93865220423@fcdonders.ru.nl> Message-ID: Dear fieldtrip users One more note: for the backward compatibility to work, you should add the fieldtrip/compat directory to your path. Alternatively (and preferably) you should execute the fieldtrip/fieldtripdefs.m function. The fieldtripdefs function sets the default cfg options and also ensures that all path settings are correct. best regards, Robert On 16 Dec 2009, at 11:06, Robert Oostenveld wrote: > Dear FieldTrip users > > As some of you may know, Matlab (and specifically the older versions > that we still support) does not have a good way of separating > functions in different toolboxes from each other. The fieldtrip > version of preprocessing (or read_data) might be completely > different from a function with the same name in another toolbox. > That is not a problem for some of the unusual function names, but > some function names like "preprocessing" are very generic and > therefore likely to be used in completely different contexts. > > After repeated discussion with the developers of the SPM Matlab > toolbox, we have decided to start adopting the same naming scheme > that SPM is using. That naming scheme consists of prefixing the > function name with the name of the toolbox, e.g. spm_contrasts. The > prefix that FieldTrip will use is "ft_". So that means that the > FieldTrip preprocessing function will be renamed into > ft_preprocessing, sourceanalysis will become ft_sourceanalysis, > freqanalysis will become ft_freqanalysis, etc. This will affect all > publicly available FieldTrip functions, i.e. the main functions that > you are using. The advantage of this change in function names is > that it further facilitates the already very good collaboration of > the FieldTrip project with other EEG/MEG method development groups, > such as SPM, EEGLAB, BrainStorm and others. > > Note that this is not an easy choice to make and we have carefully > considered the consequences. Of course all users have existing > scripts that use the old function names. We will do our utmost best > to ensure that your old scripts will remain functional, also with > new versions of the fieldtrip toolbox. To make this possible, we > will provide backward compatibility wrappers, e.g. there will be a > preprocessing.m function that calls ft_preprocessing.m and the > likes. Not only the existing analysis scripts are affected, but also > the documentation on the fieldtrip wiki will have to be updated. > Furthermore, fieldtrip functions often call each other, which means > that inside the fieldtrip functions the function names also have to > be changed. > > On the short time scale, we will provide backward compatibility > wrapper functions. On the medium time scale, we will ensure that the > fieldtrip code and documentation is internally consistent. On the > long run everyone (which includes you!) should adopt the new > function names. Please start using these new function names in your > scripts and in your derived functions as soon as possible. At a > certain point in the future, the backward compatibility to the old/ > current function names will be removed from the fieldtrip release, > so by that time all of your scripts should only be using the new > function names, otherwise they won't work any more. The backward > compatibility will be ensured throughout 2010, i.e. for a full year. > Usually we are able to maintain backward compatibility for a much > longer time, so probably you should not have to worry about this too > much. > > best regards, > Robert > > > > ----------------------------------------------------------- > Robert Oostenveld, PhD > Senior Researcher > Donders Institute for Brain, Cognition and Behaviour > Centre for Cognitive Neuroimaging > Radboud University Nijmegen > tel.: +31 (0)24 3619695 > e-mail: r.oostenveld at donders.ru.nl > web: http://www.ru.nl/neuroimaging > skype: r.oostenveld > ----------------------------------------------------------- > > ---------------------------------- > The aim of this list is to facilitate the discussion between users > of the FieldTrip toolbox, to share experiences and to discuss new > ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html > and http://www.ru.nl/neuroimaging/fieldtrip. > ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From anette.giani at TUEBINGEN.MPG.DE Thu Dec 17 09:47:33 2009 From: anette.giani at TUEBINGEN.MPG.DE (Anette Giani) Date: Thu, 17 Dec 2009 09:47:33 +0100 Subject: A newbie's question on Fourier using freqanalysis_mtmfft Message-ID: Dear all, I am a beginner on MEG and I have some basic questions on Fourier transformation using the function freqanalysis_mtmfft. It would be great if you could help me! We are interested in Steady State Responses. Therefore we recorded data 60 seconds trials. To transform the time domain into a frequency spectrum we used the function freqanalysis_mtmfft. However, I am not sure which value cfg.tapsmofrq. Since we would like to have the highest frequency resolution possible I set cfg.tapsmofrq to 0.25; the lowest value possible. Do you think that was a good choice? Further, does this value mean that our lowest possible frequency resolution would be 0.25? If that was the case, how could I avoid all smoothing? Second, do you think that it would be useful to pad the signal with zeros to artificially increase the frequency resolution? I guess this could be done using cfg.pad? Lastly, an even more general question: What do you think would be handier: (1) Compute the frequency spectrum over 60 seconds, to get a high frequency resolution or (2) to cut the signal into e.g. 4 second pieces and to average all spectra to increase the signal to noise ratio? Thanks a lot in advance for your help, Anette ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From lulswinnik at GMAIL.COM Thu Dec 17 16:00:32 2009 From: lulswinnik at GMAIL.COM (Katya Vinnik) Date: Thu, 17 Dec 2009 16:00:32 +0100 Subject: A newbie's question on Fourier using freqanalysis_mtmfft In-Reply-To: <-1763973191626696207@unknownmsgid> Message-ID: Dear Anette, If you are looking at the steady state response and are interested in its power only, you should not try to achieve the highest frequency resolution, but rather adjust the parameters (sampling rate and NFFT) to place your SSR frequency exactly in the center of the frequency bin, which may be rather large (around 1 hz). In this way you'd be sure you're capturing all the power coming from from the SSR and will be able to compare this frequency bin between conditions or to the nearby frequency bins. Katya 2009/12/17 Anette Giani > Dear all, > > I am a beginner on MEG and I have some basic questions on Fourier > transformation using the function freqanalysis_mtmfft. It would be great > if you could help me! > > > > We are interested in Steady State Responses. Therefore we recorded data 60 > seconds trials. > > To transform the time domain into a frequency spectrum we used the function > freqanalysis_mtmfft. However, I am not sure which value cfg.tapsmofrq. > Since we would like to have the highest frequency resolution possible I set > cfg.tapsmofrq to 0.25; the lowest value possible. Do you think that was a > good choice? Further, does this value mean that our lowest possible > frequency resolution would be 0.25? If that was the case, how could I avoid > all smoothing? > > > > Second, do you think that it would be useful to pad the signal with zeros > to artificially increase the frequency resolution? I guess this could be > done using cfg.pad? > > > > Lastly, an even more general question: What do you think would be handier: > (1) Compute the frequency spectrum over 60 seconds, to get a high frequency > resolution or (2) to cut the signal into e.g. 4 second pieces and to average > all spectra to increase the signal to noise ratio? > > > > Thanks a lot in advance for your help, > > Anette > > > > ---------------------------------- > > The aim of this list is to facilitate the discussion between users of the > FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and > EEG analysis. > > http://listserv.surfnet.nl/archives/fieldtrip.html > > http://www.ru.nl/fcdonders/fieldtrip/ > -- Ekaterina Vinnik, MD, PhD Tactile Perception and Learning Lab Cognitive neuroscience sector, SISSA, Trieste, Italy +393347032225 lulswinnik at gmail.com ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From ingrid.nieuwenhuis at FCDONDERS.RU.NL Thu Dec 17 16:12:37 2009 From: ingrid.nieuwenhuis at FCDONDERS.RU.NL (Ingrid Nieuwenhuis) Date: Thu, 17 Dec 2009 16:12:37 +0100 Subject: A newbie's question on Fourier using freqanalysis_mtmfft In-Reply-To: <000001ca7ef5$92ef6410$b8ce2c30$%giani@tuebingen.mpg.de> Message-ID: Dear Anette, Cfg.tapsmofrq is an option for multitaper analysis (cfg.taper = 'dpss'), which might not be what you want if you want high frequency resolution. I would recommend looking at the tutorial "Time-frequency analysis using Hanning window, multitapers and wavelets" http://fieldtrip.fcdonders.nl/tutorial/timefrequencyanalysis there you can read about the differences between hanning taper and multitapers. Hope this helps a bit Best Ingrid _____ From: FieldTrip discussion list [mailto:FIELDTRIP at NIC.SURFNET.NL] On Behalf Of Anette Giani Sent: Thursday, December 17, 2009 9:48 AM To: FIELDTRIP at NIC.SURFNET.NL Subject: [FIELDTRIP] A newbie's question on Fourier using freqanalysis_mtmfft Dear all, I am a beginner on MEG and I have some basic questions on Fourier transformation using the function freqanalysis_mtmfft. It would be great if you could help me! We are interested in Steady State Responses. Therefore we recorded data 60 seconds trials. To transform the time domain into a frequency spectrum we used the function freqanalysis_mtmfft. However, I am not sure which value cfg.tapsmofrq. Since we would like to have the highest frequency resolution possible I set cfg.tapsmofrq to 0.25; the lowest value possible. Do you think that was a good choice? Further, does this value mean that our lowest possible frequency resolution would be 0.25? If that was the case, how could I avoid all smoothing? Second, do you think that it would be useful to pad the signal with zeros to artificially increase the frequency resolution? I guess this could be done using cfg.pad? Lastly, an even more general question: What do you think would be handier: (1) Compute the frequency spectrum over 60 seconds, to get a high frequency resolution or (2) to cut the signal into e.g. 4 second pieces and to average all spectra to increase the signal to noise ratio? Thanks a lot in advance for your help, Anette ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. http://listserv.surfnet.nl/archives/fieldtrip.html http://www.ru.nl/fcdonders/fieldtrip/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From justin.ales at GMAIL.COM Thu Dec 17 17:15:49 2009 From: justin.ales at GMAIL.COM (Justin Ales) Date: Thu, 17 Dec 2009 08:15:49 -0800 Subject: A newbie's question on Fourier using freqanalysis_mtmfft In-Reply-To: <-1763973191626696207@unknownmsgid> Message-ID: In my experience with steady-state visual evoked potentials using time-frequency analysis with just power works poorly. This is because it doesn't average out phase incoherent noise sources, and the steady-state response is a driven coherent signal. We usually cut our data into 2 second long "trials", to get .5 Hz resolution, and then coherently average(phase locked) fourier components over these epochs. Bach & Meigen have written a good primer on analysis choices, such as windowing and zeropadding, for steady-state potentials: http://www.uniklinik-freiburg.de/augenklinik/live/homede/mit/bach/ops/fourier_en.html Justin Ales Smith-Kettlewell Eye Research Institute On Thu, Dec 17, 2009 at 12:47 AM, Anette Giani wrote: > Dear all, > > I am a beginner on MEG and I have some basic questions on Fourier > transformation using the function freqanalysis_mtmfft. It would be great if > you could help me! > > > > We are interested in Steady State Responses. Therefore we recorded data 60 > seconds trials. > > To transform the time domain into a frequency spectrum we used the function > freqanalysis_mtmfft. However, I am not sure which value cfg.tapsmofrq. Since > we would like to have the highest frequency resolution possible I set > cfg.tapsmofrq to 0.25; the lowest value possible. Do you think that was a > good choice? Further, does this value mean that our lowest possible > frequency resolution would be 0.25? If that was the case, how could I avoid > all smoothing? > > > > Second, do you think that it would be useful to pad the signal with zeros to > artificially increase the frequency resolution? I guess this could be done > using cfg.pad? > > > > Lastly, an even more general question: What do you think would be handier: > (1) Compute the frequency spectrum over 60 seconds, to get a high frequency > resolution or (2) to cut the signal into e.g. 4 second pieces and to average > all spectra to increase the signal to noise ratio? > > > > Thanks a lot in advance for your help, > >  Anette > > > > ---------------------------------- > > The aim of this list is to facilitate the discussion between users of the > FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and > EEG analysis. > > http://listserv.surfnet.nl/archives/fieldtrip.html > > http://www.ru.nl/fcdonders/fieldtrip/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From michael.wibral at WEB.DE Fri Dec 18 11:12:50 2009 From: michael.wibral at WEB.DE (Michael Wibral) Date: Fri, 18 Dec 2009 11:12:50 +0100 Subject: DICS power localization with real valued coefficients Message-ID: Dear Listusers, this post relates back to an older one where the use of DICS to localize power maxima (without the use of a reference time course) was discussed. For this case it was agreed upon - if I remember correctly - to constrain the filters to be real-valued as only this correctly reflects linear, INSTANTAEUOUS mixing from sources to sensors as it should be given for normal volume conduction, frequencies below 1 kHz and sampling in the same range. Real valued filters also allow to reconstruct real-valued source time-courses. Here's my question now: Real valued filters (i.e. only +/- values) should result in DICS also showing the well known problems for correlated sources (that are circumvented for everything but exactly correlated/anticorrelated sources when using complex coefficients and a reference signal) as in this case the whole equation is not very different from a simple fourier transform of the corresponding LCMV solution. Is this correct? Does DICS have problems localizing source power for correlated/coherent sources when constraining it to real valued coefficients? And if not, could someone give a hint where the differences would come from? Many thanks, Michael ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- A non-text attachment was scrubbed... Name: Michael Wibral.vcf Type: text/x-vcard Size: 336 bytes Desc: not available URL: From awalthermail at GOOGLEMAIL.COM Sun Dec 20 21:59:46 2009 From: awalthermail at GOOGLEMAIL.COM (Walther, Alexander) Date: Sun, 20 Dec 2009 21:59:46 +0100 Subject: clustering after sensor picking? Message-ID: Dear list, I am facing a question regarding the MCP in time-frequency-analysis. In order to boost the effect size, I picked several ROIs on the MEG scalp by running a Task-versus-Basline Comparison (values averaged over all subjects, all conditions, timepoints and frequencies) and selecting the highest raw effect patches. Since FDR-correction seems to be too conservative and yields no results in following analyses, I tried the cluster-method which works pretty well. Is it (statistically) correct to apply clustering after sensor picking? Since its test statistic refers to the clustering of /adjacent/ sensor-pairs of the whole spatiotemporal grid (which does not exist any more after the selection of ROIs), I wonder whether it is still appropriate. Any advice would be helpful. Merry xmas in advance! Best Alex ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From ole.jensen at DONDERS.RU.NL Sun Dec 20 22:42:57 2009 From: ole.jensen at DONDERS.RU.NL (Ole Jensen) Date: Sun, 20 Dec 2009 22:42:57 +0100 Subject: Biomag2010/data analysis competition Message-ID: Dear all, We would like to point you all to the data analysis competition at Biomag2010: http://megcommunity.org/index.php?option=com_content&view=article&id=2&Itemid=24 We would like as many as possible to participate so please consider this and/or spread the word! Best wishes for the holidays, Ole Jensen and Jan Mathijs Schoeffelen -- Ole Jensen Principal Investigator Neuronal Oscillations Group Donders Institute for Brain, Cognition and Behaviour Centre for Cognitive Neuroimaging P.O. Box 9101 NL-6500 HB Nijmegen The Netherlands Office : +31 24 36 10884 MEG lab : +31 24 36 10988 Fax : +31 24 36 10989 e-mail : ole.jensen at donders.ru.nl URL : http://ojensen.ruhosting.nl/ ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From e.maris at DONDERS.RU.NL Mon Dec 21 18:16:39 2009 From: e.maris at DONDERS.RU.NL (Eric Maris) Date: Mon, 21 Dec 2009 18:16:39 +0100 Subject: clustering after sensor picking? In-Reply-To: <4B2E9042.7020407@googlemail.com> Message-ID: Hi Walther, > I am facing a question regarding the MCP in time-frequency-analysis. In > order to boost the effect size, I picked several ROIs on the MEG scalp > by running a Task-versus-Basline Comparison (values averaged over all > subjects, all conditions, timepoints and frequencies) and selecting the > highest raw effect patches. Since FDR-correction seems to be too > conservative and yields no results in following analyses, I tried the > cluster-method which works pretty well. Is it (statistically) correct to > apply clustering after sensor picking? Since its test statistic refers > to the clustering of /adjacent/ sensor-pairs of the whole spatiotemporal > grid (which does not exist any more after the selection of ROIs), I > wonder whether it is still appropriate. Any advice would be helpful. If you have an independent localizer that you can thrust, then you should use it, and you should use it for as many dimensions as possible. Task-versus-baseline (with "task" being the average over all experimental conditions) is an independent localizer the result of which you can subsequently use for comparing the different experimental conditions. If you want to use the localizer for all three dimensions (space, frequency, and time), then you are done, because your three-dimensional array has been reduced to a scalar. If you want to use the localizer for only a subset of the dimensions, then you could use a cluster-based permutation test with clustering over the remaining dimensions. If you don't thrust your localizer, then you can do cluster-based permutation test with clustering over all three dimensions. Best, Eric Maris dr. Eric Maris Donders Institute for Brain, Cognition and Behavior Center for Cognition and F.C. Donders Center for Cognitive Neuroimaging Radboud University P.O. Box 9104 6500 HE Nijmegen The Netherlands T:+31 24 3612651 Mobile: 06 39584581 F:+31 24 3616066 E: e.maris at donders.ru.nl MSc Cognitive Neuroscience: www.ru.nl/master/cns/ > > Merry xmas in advance! > > > Best > > Alex > > ---------------------------------- > The aim of this list is to facilitate the discussion between users of the FieldTrip > toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. > See also http://listserv.surfnet.nl/archives/fieldtrip.html and > http://www.ru.nl/neuroimaging/fieldtrip. ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From tonychunwei at GMAIL.COM Tue Dec 22 05:19:34 2009 From: tonychunwei at GMAIL.COM (Chun-Wei Lee) Date: Tue, 22 Dec 2009 05:19:34 +0100 Subject: eeg_leadfield4_prepare Message-ID: Hi, I am using the prepare_leadfield() following the toturial "Use your own forward leadfield model in an inverse beamformer computation" but i have faced the problem that when i execute grid = prepare_leadfield(cfg); and I can't find eeg_leadfield4_prepare(), I check the file I download and I can't find this function I guess I ignore some step... can anyone tell me what is going on? ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From nathanweisz at MAC.COM Tue Dec 22 12:21:25 2009 From: nathanweisz at MAC.COM (Nathan Weisz) Date: Tue, 22 Dec 2009 12:21:25 +0100 Subject: A newbie's question on Fourier using freqanalysis_mtmfft In-Reply-To: <000001ca7ef5$92ef6410$b8ce2c30$%giani@tuebingen.mpg.de> Message-ID: > Lastly, an even more general question: What do you think would be handier: (1) Compute the frequency spectrum over 60 seconds, to get a high frequency resolution or (2) to cut the signal into e.g. 4 second pieces and to average all spectra to increase the signal to noise ratio? as suggested before do not average the spectra, but the time series. after that you do your fourier stuff (with cfg.taper='hanning' as ingrid suggested). beware to move the window in steps which are exact multiples of your steady-state frequency cycle (e.g. 100 ms for 10 Hz). when you calculate the amount of sampling points you need to move your window, then first "think" in latencies (for 10 Hz e.g: 0, 100, 200 etc ms, if you move 1 cycle), after that convert to sampling points (e.g. using nearest.m). this is very important, because when you first "think" in sampling points then you might be missing your desired time point each time just a little bit, however the inaccuracy accumulates with each moving of your window. in the end you see no steady-state at all. this mistake did cost me and a phd student a couple of days to figure out while doing auditory steady-state ... good luck, nathan ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From nathanweisz at MAC.COM Tue Dec 22 15:59:21 2009 From: nathanweisz at MAC.COM (Nathan Weisz) Date: Tue, 22 Dec 2009 15:59:21 +0100 Subject: "Changing People, Changing Brain" - Travel Awards for Young Scientists Message-ID: hi everyone, i would like to abuse this list to raise awareness for the upcoming conference "Changing People, Changing Brains" that will take place in Konstanz next year, April 8-10 2010. Diverse experts from various disciplines (e.g. neuroscientists, clinicians) will present their results and views on "adaptation". Keynote speakers are S. Hillyard, M. Merzenich and U. Schnyder. Please take a look at the conference web-page: http://www.psychologie.uni-konstanz.de/abteilungen/clinicalpsychology/changing/ as well as the attached flyer. For the conference we have 16 travel awards for Young scientists (i.e. PhD and Postdoc level) that will cover costs up to 1000€. The deadline for application will be 15. Jan. 2010. Any young scientist who can fit their research topic under the umbrella-terms: "Trauma and Adaptation" and "Markers of Neural Plasticity" is encouraged to send an application to the conference committee (see flyer for details). Feel free to pass this on to any young scientist you know who fits the profile of the conference. Merry christmas and a happy new year, nathan -------------------------------------------- Dr. Nathan Weisz OBOB-Lab University of Konstanz Department of Psychology P.O. Box D23 78457 Konstanz Germany Tel: ++49 - (0)7531 - 88 45 84 Email: nathan.weisz at uni-konstanz.de Homepage: http://www.uni-konstanz.de/obob "Nothing shocks me. I'm a scientist." (Indiana Jones) ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: flyer_conference_thomas_brigitte.pdf Type: application/pdf Size: 710542 bytes Desc: not available URL: -------------- next part -------------- An HTML attachment was scrubbed... URL: From akiko at NYU.EDU Tue Dec 22 16:14:25 2009 From: akiko at NYU.EDU (Akiko Ikkai) Date: Tue, 22 Dec 2009 10:14:25 -0500 Subject: freqanalysis & cfg.channel Message-ID: Hi, I'm trying to run TFR on MEG data and plot the results, and getting puzzling figures. Both freqanalysis and multiplotTFR run fine, and figures are produced, but the first channel (first channel in ft_data.label) is always extremely noisy (barely changing from the baseline, but showing random patches of activations across time and freq). When I take out that channel with cfg.channel = {'all','-1'}; % when the first channel is noisy the second channel (now the first in label) shows the same trend, if I take out the second, the third one is bad, etc... Other channels don't seem to be affected. I'm pasting my code during this process below. Can anyone tell me what might be going wrong, and when the best point to delete bad channels? Thanks in advance, Akiko %%% to run freq analysis %%% cfg.output = 'pow'; cfg.method = 'mtmconvol'; cfg.taper = 'hanning'; cfg.foi = 4:2:50; cfg.t_ftimwin = ones(length(cfg.foi),1).*0.5; cfg.toi = -.5:0.05:2; cfg.channel = {'all','-1'}; % when the first channel is noisy TFRhann_Rvalid = freqanalysis(cfg, Rvalid); cfg = []; cfg.baseline = [-.1 0]; cfg.baselinetype = 'relative'; cfg.xlim = [-0.1 1.2]; cfg.showlabels = 'yes'; cfg.colorbar = 'yes'; figure(1);clf cfg.ylim = [5 50]; cfg.zlim = [0 2]; multiplotTFR(cfg, TFRhann_Rvalid); % after importing channel layout ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From christine.gruetzner at GOOGLEMAIL.COM Tue Dec 22 17:00:56 2009 From: christine.gruetzner at GOOGLEMAIL.COM (Christine Gruetzner) Date: Tue, 22 Dec 2009 17:00:56 +0100 Subject: Source analysis on timelockdata Message-ID: Hi everyone, I got a problem with performing source analysis (minimum norm estimate) on timelockdata, and I would be very glad if anyone could help me out! So far, I've done the following steps (using fieldtrip version 20091221): 1) Compute timelockanalysis with cfg.latency = [0.05 0.4] and baseline correction for condition 1 and 2 2) Source analysis with cfg. method = 'mne' on the timelock data, using inverse grids In the output from the source analysis I have avg.pow = 4560x211 for each subject (211 = number of time samples) The problem is that I can't compute sourcegrandaverage (see code below) on these data (error at sourcegrandaverage at 178, dat(:,i) = tmp(:)); I already tried to put the single datasets directly into sourcestatistics, but this doesn't work either (error: "the function requires source or volume data as input") I guess the problem is caused by the time dimension in the timelock data - does anyone have an idea how to handle this information in source analysis / source grandaverage / source statistics? Best Christine %------------------------------------------------- % Code for Source Statistics datapath = '/data/home1/ctillman/data/MooneyMEEGFieldtripAnalysis/ERF/Pilot/MNE/'; DataFaceFiles = { 'ERF_Task_BaseCorr_PreprocNew1secbase_ABA04_MooneyFacesMEEG_20070625_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_BBA06_MooneyFacesMEEG_20080318_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_CSA25_MooneyFacesMEEG_20070912_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_FSA04_MooneyFacesMEEG_20070529_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_GDE03_MooneyFacesMEEG_20071002_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_IFS20_MooneyFacesMEEG_20070809_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_IKE28_MooneyFacesMEEG_20070329_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_JHA07_MooneyFacesMEEG_20070327_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_JPA05_MooneyFacesMEEG_20080403_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_MKA21_MooneyFacesMEEG_20070711_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_MMA07_MooneyFacesMEEG_20070706_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_PSS16_MooneyFacesMEEG_20080312_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_SNI05_MooneyFacesMEEG_20080313_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_TWS22_MooneyFacesMEEG_20070831_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_UWA31_MooneyFacesMEEG_20070914_0_cond_1SRC_MNE_0p5iws_lambda05.mat'; }; DataInvertedFiles = { 'ERF_Task_BaseCorr_PreprocNew1secbase_ABA04_MooneyFacesMEEG_20070625_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_BBA06_MooneyFacesMEEG_20080318_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_CSA25_MooneyFacesMEEG_20070912_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_FSA04_MooneyFacesMEEG_20070529_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_GDE03_MooneyFacesMEEG_20071002_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_IFS20_MooneyFacesMEEG_20070809_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_IKE28_MooneyFacesMEEG_20070329_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_JHA07_MooneyFacesMEEG_20070327_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_JPA05_MooneyFacesMEEG_20080403_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_MKA21_MooneyFacesMEEG_20070711_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_MMA07_MooneyFacesMEEG_20070706_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_PSS16_MooneyFacesMEEG_20080312_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_SNI05_MooneyFacesMEEG_20080313_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_TWS22_MooneyFacesMEEG_20070831_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; 'ERF_Task_BaseCorr_PreprocNew1secbase_UWA31_MooneyFacesMEEG_20070914_0_cond_4SRC_MNE_0p5iws_lambda05.mat'; }; template = load('/data/home1/ctillman/data/MooneyMEEGFieldtripAnalysis/Beamforming/MNIgrids/Grids0p5_170109/MNItemplate_170109_-0p5iws.mat'); Nx = length(template.template_grid.xgrid); Ny = length(template.template_grid.ygrid); Nz = length(template.template_grid.zgrid); %-------------------------------------------------------------------------- for i = 1:length(DataFaceFiles) fullname1 = strcat(datapath,DataFaceFiles{i,1}); DataFace{i} = load(fullname1); end for i = 1:length(DataInvertedFiles) fullname2 = strcat(datapath,DataInvertedFiles{i,1}); DataInverted{i} = load(fullname2); end %-------------------------------------------------------------------------- % Fixing the structure properties % Absolute power difference for l = 1:length(DataFaceFiles) DataFace{l}.DataERFOut.xgrid = template.template_grid.xgrid; DataFace{l}.DataERFOut.ygrid = template.template_grid.ygrid; DataFace{l}.DataERFOut.zgrid = template.template_grid.zgrid; DataFace{l}.DataERFOut.dim = [Nx Ny Nz]; DataFace{l}.DataERFOut.pos = template.template_grid.pos; DataFace{l}.DataERFOut.inside = template.template_grid.inside; DataFace{l}.DataERFOut.outside = template.template_grid.outside; DataFace{l} = DataFace{l}.DataERFOut; end for l = 1:length(DataInvertedFiles) DataInverted{l}.DataERFOut.xgrid = template.template_grid.xgrid; DataInverted{l}.DataERFOut.ygrid = template.template_grid.ygrid; DataInverted{l}.DataERFOut.zgrid = template.template_grid.zgrid; DataInverted{l}.DataERFOut.dim = [Nx Ny Nz]; DataInverted{l}.DataERFOut.pos = template.template_grid.pos; DataInverted{l}.DataERFOut.inside = template.template_grid.inside; DataInverted{l}.DataERFOut.outside = template.template_grid.outside; DataInverted{l} = DataInverted{l}.DataERFOut; end % Compute grand average for Condition 1 and 2 cfgGA = []; cfgGA.keepindividual = 'yes'; % cfg.parameter = 'pow'; % create command strings for the computation: commandstr1 = strcat ('DataGAFace', '= sourcegrandaverage(cfgGA'); commandstr2 = strcat ('DataGAInverted', '= sourcegrandaverage(cfgGA'); for l = 1 : length(DataFace) commandstr1 = strcat(commandstr1, ',DataFace{', num2str(l) , '}'); end % finalize command strings commandstr1 = strcat(commandstr1,');'); eval(commandstr1) % yields DataGADiff; for l = 1 : length(DataInverted) commandstr2 = strcat(commandstr2, ',DataInverted{', num2str(l) , '}'); end % finalize command strings commandstr2=strcat(commandstr2,');'); eval(commandstr2) % yields DataGADiff; cfg = []; cfg.dimord = 'voxel'; cfg.dim = [15 19 16]; nSubjects = length(DataFaceFiles); a = [1:nSubjects]; b = ones(1,nSubjects); cfg.design = [a a; b (2*b)]; cfg.uvar = 1; % "subject" is unit of observation cfg.ivar = 2; % row cfg.method = 'montecarlo'; cfg.correctm = 'fdr'; cfg.alpha = 0.05; cfg.numrandomization = 6000; cfg.parameter = 'pow'; cfg.statistic = 'depsamplesT'; sourceStat = sourcestatistics(cfg, DataGAFace, DataGAInverted); -- Christine Grützner, geb.Tillmann Max-Planck-Institut für Hirnforschung Abt. Neurophysiologie Deutschordenstr. 46 60528 Frankfurt am Main Germany Phone: +49 (0)69/6301-83225 E-Mail: tillmann at mpih-frankfurt.mpg.de http://www.mpih-frankfurt.mpg.de/global/Np/Staff/tillmann.htm ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From manish.saggar at GMAIL.COM Thu Dec 24 07:41:13 2009 From: manish.saggar at GMAIL.COM (Manish Saggar) Date: Thu, 24 Dec 2009 00:41:13 -0600 Subject: Frequency stats on Individual Alpha Frequency (IAF) based bands Message-ID: Dear All, I have a question about doing freqstatistics on a group of subjects, where each subject can have a different frequency range for a band of interest. For example, based on individual alpha frequency (IAF) I define alpha band to be [8-12Hz] in one subject and [7-11Hz] in another, then how can I do non-parametric alpha power analysis using freqstatistics function, since I can only give one range for all subjects in the cfg structure. Is there a way to directly give power values for a band rather than frequency of interest OR is there a separate function in such cases. Any help is appreciated. Happy Holidays!!! Regards, Manish ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From nhutche at GMAIL.COM Mon Dec 28 21:45:48 2009 From: nhutche at GMAIL.COM (Nathan Hutcheson) Date: Mon, 28 Dec 2009 21:45:48 +0100 Subject: topoplotTFR problem Message-ID: Hello, I am a graduate student at UAB and am having a problem getting Fieldtrip to plot my EEG preprocessed data using the topoplotTFR function. Below is what I entered into the Matlab command line: addpath(genpath('/usr/local/pkg/MATLAB/toolbox/eeglab7_1_3_14b/external/fie ldtrip-20090727/')) ' cfg = []; cfg.xlim = [-.5 -.25]; %cfg.zlim = [-1.5e-27 1.5e-27]; cfg.ylim = [8 12]; cfg.baseline = [-0.5 -0.1]; cfg.baselinetype = 'absolute'; cfg.showlabels = 'markers'; figure topoplotTFR(cfg,TFRhann) This is the error message I get: ??? Error using ==> topoplot at 1019 Odd number of input arguments?? Error in ==> topoplotER at 482 topoplot(cfg,chanX,chanY,datavector,chanLabels); Error in ==> topoplotTFR at 101 cfg=topoplotER(cfg, varargin{:}); Error in ==> tempFieldtriptest at 11 topoplotTFR(cfg,TFRhann) Any ideas/ suggestions? ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From bibi.raquel at GMAIL.COM Tue Dec 29 04:32:30 2009 From: bibi.raquel at GMAIL.COM (Raquel Bibi) Date: Mon, 28 Dec 2009 22:32:30 -0500 Subject: topoplotTFR problem In-Reply-To: Message-ID: I had a similar problem. It was due to having the same function in EEGLAB. If you are using EEGLAB make sure to set the path below fieldtrip. Best, Raquel On Mon, Dec 28, 2009 at 3:45 PM, Nathan Hutcheson wrote: > Hello, > > I am a graduate student at UAB and am having a problem getting Fieldtrip to > plot my EEG preprocessed data using the topoplotTFR function. Below is > what > I entered into the Matlab command line: > > addpath(genpath('/usr/local/pkg/MATLAB/toolbox/eeglab7_1_3_14b/external/fie > ldtrip-20090727/')) ' > > cfg = []; > cfg.xlim = [-.5 -.25]; > %cfg.zlim = [-1.5e-27 1.5e-27]; > cfg.ylim = [8 12]; > cfg.baseline = [-0.5 -0.1]; > cfg.baselinetype = 'absolute'; > cfg.showlabels = 'markers'; > figure > topoplotTFR(cfg,TFRhann) > > This is the error message I get: > > ??? Error using ==> topoplot at 1019 > Odd number of input arguments?? > > Error in ==> topoplotER at 482 > topoplot(cfg,chanX,chanY,datavector,chanLabels); > > Error in ==> topoplotTFR at 101 > cfg=topoplotER(cfg, varargin{:}); > > Error in ==> tempFieldtriptest at 11 > topoplotTFR(cfg,TFRhann) > > Any ideas/ suggestions? > > ---------------------------------- > The aim of this list is to facilitate the discussion between users of the > FieldTrip toolbox, to share experiences and to discuss new ideas for MEG > and EEG analysis. See also > http://listserv.surfnet.nl/archives/fieldtrip.html and > http://www.ru.nl/neuroimaging/fieldtrip. > ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From dsenkows at UKE.UNI-HAMBURG.DE Wed Dec 30 11:51:36 2009 From: dsenkows at UKE.UNI-HAMBURG.DE (Daniel Senkowski) Date: Wed, 30 Dec 2009 11:51:36 +0100 Subject: Open PhD Position Message-ID: Hi, I hope you don't mind announcing a job opening for a PhD position at our Department in Hamburg (see below). Regards, Daniel ---------------------------------------------------------------- PhD Position at the Dept. of Neurophysiology and Pathophysiology, Hamburg The Department of Neurophysiology and Pathophysiology (Head: Prof. Dr. Andreas K. Engel) at the University Medical Center Hamburg-Eppendorf (Germany) invites applications for a PhD student position, starting February/March 2010. The PhD student will conduct studies on unisensory and multisensory processing of auditory and audiovisual information in cochlear-implant users. The project incorporates advanced psychophysical measurements as well as EEG and MEG recordings. The project will be conducted in collaboration with Prof. Dr. Andrej Kral from the Medical University Hannover. Main research interests of the Department of Neurophysiology are the dynamics of distributed sensory processing, intermodal and sensorimotor integration, as well as theories of perception, action and consciousness. Current projects involve EEG/MEG/fMRI studies in humans or physiological studies in animals. Further information on research at the Department of Neurophysiology can be obtained at http://www.uke.de/institute/neurophysiologie or http://www.40hz.net. Applicants should have a background in psychology, medicine, biology or neuroscience. Experience in human EEG studies or biosignal analysis is desirable. For further details, please contact Dr. Daniel Senkowski (phone +49-40-42803-57047, email: dsenkows at uke.de, www.danielsenkowski.com) or Prof. Dr. Andreas K. Engel (phone +49-40-42803-56170, email: ak.engel at uke.de) or Prof. Dr. Andrej Kral (phone: +49-511-532-7272, email: kral.andrej at mh-hannover.de). Applicants are asked to submit their CV and documentation of relevant qualification to Dr. Daniel Senkowski (dsenkows at uke.de), Dept. of Neurophysiology and Pathophysiology, University Medical Center Hamburg-Eppendorf, Martinistr. 52, 20246 Hamburg, Germany. -- Pflichtangaben gem�� Gesetz �ber elektronische Handelsregister und Genossenschaftsregister sowie das Unternehmensregister (EHUG): Universit�tsklinikum Hamburg-Eppendorf K�rperschaft des �ffentlichen Rechts Gerichtsstand: Hamburg Vorstandsmitglieder: Prof. Dr. J�rg F. Debatin (Vorsitzender) Dr. Alexander Kirstein Prof. Dr. Dr. Uwe Koch-Gromus ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: From r.vandermeij at DONDERS.RU.NL Wed Dec 30 13:33:19 2009 From: r.vandermeij at DONDERS.RU.NL (Roemer van der Meij) Date: Wed, 30 Dec 2009 13:33:19 +0100 Subject: topoplotTFR problem In-Reply-To: Message-ID: Hi Nathan, TopoplotER has been extensively modified the past few weeks and the latest version no longer uses the topoplot.m (which presumably overlaps with EEGLAB). If you update your FieldTrip version the problem should be solved I think. The cfg-options have been changed as well though, so it would be a good idea to read the documentation at the top of the function (e.g. cfg.showlabels has now been integrated into cfg.markers if I recall correctly). Kind regards, Roemer van der Meij Quoting Nathan Hutcheson : > Hello, > > I am a graduate student at UAB and am having a problem getting Fieldtrip to > plot my EEG preprocessed data using the topoplotTFR function. Below is what > I entered into the Matlab command line: > > addpath(genpath('/usr/local/pkg/MATLAB/toolbox/eeglab7_1_3_14b/external/fie > ldtrip-20090727/')) ' > > cfg = []; > cfg.xlim = [-.5 -.25]; > %cfg.zlim = [-1.5e-27 1.5e-27]; > cfg.ylim = [8 12]; > cfg.baseline = [-0.5 -0.1]; > cfg.baselinetype = 'absolute'; > cfg.showlabels = 'markers'; > figure > topoplotTFR(cfg,TFRhann) > > This is the error message I get: > > ??? Error using ==> topoplot at 1019 > Odd number of input arguments?? > > Error in ==> topoplotER at 482 > topoplot(cfg,chanX,chanY,datavector,chanLabels); > > Error in ==> topoplotTFR at 101 > cfg=topoplotER(cfg, varargin{:}); > > Error in ==> tempFieldtriptest at 11 > topoplotTFR(cfg,TFRhann) > > Any ideas/ suggestions? > > ---------------------------------- > The aim of this list is to facilitate the discussion between users > of the FieldTrip toolbox, to share experiences and to discuss new > ideas for MEG and EEG analysis. See also > http://listserv.surfnet.nl/archives/fieldtrip.html and > http://www.ru.nl/neuroimaging/fieldtrip. > > -- Roemer van der Meij MSc Scientific Programmer & Data-Analyst Donders Institute for Brain, Cognition and Behaviour Centre for Cognition P.O. Box 9104 6500 HE Nijmegen The Netherlands Tel: +31(0)24 3612631 E-mail: r.vandermeij at donders.ru.nl@donders.ru.nl ---------------------------------------------------------------- This message was sent using IMP, the Internet Messaging Program. ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. From Jan.Hirschmann at MED.UNI-DUESSELDORF.DE Wed Dec 30 16:03:46 2009 From: Jan.Hirschmann at MED.UNI-DUESSELDORF.DE (Jan Hirschmann) Date: Wed, 30 Dec 2009 16:03:46 +0100 Subject: problems with segmentation Message-ID: Hi there, I am having trouble segmenting an MRI scan using volumesegment on a realigned scan (obtained by volumerealign). Actually, I think this not really a fieldtrip but a spm problem. It seems there are nans or infs in some covariance matrix calculated by spm_segment, but honestly, I don't really see through this. Strangely, it did work once but then found no gray nor white matter but only CSF. Maybe it depends on how I choose the fiducials... If someone has any experience with this I would be really glad for any clue, as I am completley stuck. Thanks in advance! Here's the code and the error message: addpath('/data/apps/spm/spm2') cd('/net/avidya/storage/home/jan/seidel_dicom/S00002/SER00002'); mrifilename = 'I00001'; mri = read_mri(mrifilename); cfg=[]; cfg.interactive='yes'; seg_mri=volumerealign(cfg,mri); cd('/net/avidya/storage/home/jan/seidel_dicom/mat_anatomy_files'); save mri_realigned mri cfg = []; cfg.template = '/data/apps/spm/spm2/templates/T1.mnc'; cfg.coordinates = 'ctf'; cfg.write = 'no'; cfg.name = 'temp'; [segmentedmri] = volumesegment(cfg, mri); ??? Error using ==> schur Input to SCHUR must not contain NaN or Inf. Error in ==> sqrtm at 33 [Q, T] = schur(A,'complex'); % T is complex Schur form. Error in ==> spm_segment>get_p at 552 dst = (cor-ones(size(cor,1),1)*CP.mn(:,i)')/sqrtm(CP.cv(:,:,i)); Error in ==> spm_segment>run_segment at 335 [P,ll0] = get_p(cor,msk,s,sums,CP,bf); Error in ==> spm_segment at 106 [CP,BP,SP] = run_segment(CP,BP,SP,VF,sums,x1,x2,x3); Error in ==> ft_volumesegment at 176 spm_segment(Va,cfg.template,flags); Error in ==> volumesegment at 17 [varargout{1:nargout}] = funhandle(varargin{:}); ---------------------------------- The aim of this list is to facilitate the discussion between users of the FieldTrip toolbox, to share experiences and to discuss new ideas for MEG and EEG analysis. See also http://listserv.surfnet.nl/archives/fieldtrip.html and http://www.ru.nl/neuroimaging/fieldtrip. -------------- next part -------------- An HTML attachment was scrubbed... URL: