[FieldTrip] problems with dipole fitting and anatomical alignment

Kaelasha Tyler ktyler at swin.edu.au
Wed Apr 2 09:50:48 CEST 2014


Hi All,

I am having a great deal of difficulty accurately fitting dipoles. 'Dipoles' are ending up being shown outside the head......
This may be to do with problems in aligning the anatomical data with the sensors. I have used ft_volumerealign to fit the MRI to the neuromag coordinate system, so I am not sure where the problem is arising from.

Any help or suggestions, especially from Neuromag users, much appreciated!

Here is my code:


mri = ft_read_mri('MRI.nii');


%%



cfg=[];

cfg.method = 'interactive';

cfg.coordsys = 'neuromag';

mri_real = ft_volumerealign(cfg, mri); % Marked left and right fiducials along with naison


%%


cfg           = [];

cfg.coordsys='neuromag';

cfg.output    = {'skullstrip' 'brain'};

seg           = ft_volumesegment(cfg, mri_real);


%%

cfg = [];

cfg.coordsys='neuromag';

cfg.method = 'singleshell';

vol = ft_prepare_headmodel(cfg, seg); %Volume conduction model


%% Plotting volume conduction model along with sensor positions.

% When these are plotted, the volume conduction model does appear to be positioned too high in the sensors- see jpg


vol = ft_convert_units(vol,'cm');

sens = grad;% 'grad' contains neuromag sensor info- taken from MEG data

figure

ft_plot_sens(sens, 'style', '*b');

hold on

ft_plot_vol(vol);


%% Fitting dipoles



cfg=[];

cfg.numdipoles =1;

cfg.latency = [0.05, 0.10];

cfg.vol = vol; %volume conduction model for the subject

cfg.model = 'regional';

cfg.grad=grad;% 'grad' contains neuromag sensor info- taken from MEG data

source = ft_dipolefitting(cfg, timelocked_data);


%% make a plot of the location of the dipoles

cfg = [];

cfg.location = source.dip.pos* 10;   % convert from cm to mm

figure; ft_sourceplot(cfg, mri_real);



Once again, any help or suggestions, especially from Neuromag users, much appreciated!

Kaelasha Tyler
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.science.ru.nl/pipermail/fieldtrip/attachments/20140402/d044b42f/attachment-0001.html>


More information about the fieldtrip mailing list