[FieldTrip] Group analysis at source level

Laura Rueda Delgado Laura.Rueda at faber.kuleuven.be
Fri Jul 25 12:00:21 CEST 2014


Dear Tyler,

Thank you for your suggestion.

I had checked the option of warping the individual grid to the template grid, but I discarded it, maybe for wrong reasons. From the tutorial, I understand that warping is done via the individual MRI. I have done the segmentation, mesh creation and grid preparation at the individual level. So the warping of grids seems to redo this segmentation and mesh creation from the individual MRI to get the individual grid and warp it. The function ft_prepare_sourcemodel does not have the option to include the headmodel that I've already created (in my case, a 3-shell BEM), and that's why I excluded this option.
However, maybe I can use the template grid with the BEM like this:

 cfg = [];
    cfg.grid = template_grid;
    cfg.inwardshift = 0;
    cfg.vol = individual_vol; %result from segmentation and mesh creation
    warped_grid  = ft_prepare_sourcemodel(cfg);

And then create the headmodel:

    cfg = [];
    cfg.vol = individual_vol;
    cfg.elec = individual_sens;
    cfg.grid = warped_grid;
    cfg.grid.tight  = 'yes';
    cfg.reducerank =  'no'; %
    cfg.normalize = 'no';
    leadfield = ft_prepare_leadfield(cfg);

My question is whether this is correct given that warped_grid would be in MNI coordinates, and individual_vol and individual_sens would not. And also, would this mean that the points of the grid would all be the same for all subjects?

Best regards,

Laura

From: fieldtrip-bounces at science.ru.nl [fieldtrip-bounces at science.ru.nl] on behalf of Tyler Grummett [tyler.grummett at flinders.edu.au]
Sent: 25 July 2014 02:20
To: FieldTrip discussion list
Subject: Re: [FieldTrip] Group analysis at source level


Hey laura,


Im not 100% sure of what I am about to tell you, as I am not an expert, but I think ft_sourceinterpolate is used in tutorials

to display results on an mri model basically. One such tutorial is:

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


If you want to be consistent over subjects, I would use a sourcemodel when calculating your source variable, like in:

http://fieldtrip.fcdonders.nl/faq/how_can_i_map_source_locations_between_two_different_representations?s[]=atlas

and: http://fieldtrip.fcdonders.nl/example/create_single-subject_grids_in_individual_head_space_that_are_all_aligned_in_mni_space?s[]=subject&s[]=grid&s[]=mni​


I really hope this helps, it helped me :)


Tyler


*************************

Tyler Grummett ( BBSc, BSc(Hons I))
PhD Candidate
Brain Signals Laboratory
Flinders University
Rm 5A301
Ext 66124
________________________________
From: fieldtrip-bounces at science.ru.nl <fieldtrip-bounces at science.ru.nl> on behalf of Laura Rueda Delgado <Laura.Rueda at faber.kuleuven.be>
Sent: Friday, 25 July 2014 1:06 AM
To: fieldtrip at science.ru.nl
Subject: [FieldTrip] Group analysis at source level

Dear fieldtrip users,

I'm working with source estimations of EEG data. At the moment, I have estimated the sources at the individual level with individual MRIs. I've used ft_sourceinterpolate and ft_volumenormalise to transform the resulting estimation maps into a template for comparison, and I do this for every subject:

 cfg             = [];
    cfg.parameter   = 'avg.pow';
    source  = ft_sourceinterpolate(cfg, source, mri);

    cfg = [];
    cfg.template = '\spm8\templates\T1.nii';
    cfg.parameter = 'all';
    cfg.nonlinear = 'yes';
    cfg.coordsys = 'spm';
    source = ft_volumenormalise(cfg, source);

Once I have the estimated sources for all the subjects, I use ft_sourcestatistics:

cfg             = [];
cfg.dim         = sourcePre_con{1}.dim;
cfg.method      = 'montecarlo';
cfg.statistic   = 'depsamplesT';
cfg.parameter   = 'avg.pow';
cfg.correctm    = 'cluster';
cfg.numrandomization = 'all';
cfg.alpha       = 0.05;
cfg.tail        = 0;
cfg.design(1,:) = [1:num 1:num];
cfg.design(2,:) = [ones(1,num) ones(1,num)*2];
cfg.uvar        = 1;
cfg.ivar        = 2;
stat = ft_sourcestatistics(cfg,sourcePost_con{:},  sourcePre_con{:});

And I get this error:

Reference to non-existent field 'pos'.

Error in statistics_wrapper>get_source_avg (line 643)
  fprintf('only selecting voxels inside the brain for statistics (%.1f%%)\n', 100*length(varargin{1}.inside)/size(varargin{1}.pos,1));

Error in statistics_wrapper (line 206)
    [dat, cfg] = get_source_avg(cfg, varargin{:});

Error in ft_sourcestatistics (line 107)
    [stat, cfg] = statistics_wrapper(cfg, varargin{:});

I check the data structure and the structure of the sources at the individual level, before interpolating and normalising has the pos field, but after these steps, it's gone. How can I work around this error? Do I have to keep the pos field and transform it according to the template?

Thank you in advance for your help.

Best regards,

Laura Rueda
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20140725/5a5d5c67/attachment.html>


More information about the fieldtrip mailing list