volumesegment in BEM model

A. Stolk A.Stolk at EWI.UTWENTE.NL
Tue Dec 9 11:26:22 CET 2008

Hi there,
Using the example script 'create bemmodel for eeg', I keep struggling with the volumesegment part. 
mri = read_fcdc_mri('t1_icbm_normal_1mm_pn0_rf0.mnc');
cfg = [];
seg = volumesegment(cfg, mri);
And when I add commands like,
cfg.write = 'no';

cfg.coordinates = 'spm';

cfg.template = '\fieldtrip-20081015\spm5\templates\T1.mnc';


I receive the same errors related to the file's dimensions, namely;

??? Error using ==> spm_slice_vol
Wrong sized dim.

Error in ==> spm_read_vols at 35
 Y(:,:,p,i) = spm_slice_vol(V(i),spm_matrix([0 0 p]),V(i).dim(1:2),0);

Error in ==> read_fcdc_mri at 107
  img = spm_read_vols(hdr);

Error in ==> bemmodelfieldtrip at 14
mri = read_fcdc_mri('t1_icbm_normal_1mm_pn0_rf0.mnc');


I got this error using multiple fieldtrip versions. p.s. Also did have to add the spm_slice_vol.mexw32 file, found in the spm2 update.


Regards, Arjen



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/fcdonders/fieldtrip.

More information about the fieldtrip mailing list