<html><body><div style="color:#000; background-color:#fff; font-family:HelveticaNeue-Light, Helvetica Neue Light, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:10pt"><div style="" class="" id="yiv1867486344"><div style="" class=""><div class="" style="color:#000;background-color:#fff;font-family:HelveticaNeue-Light, Helvetica Neue Light, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:10pt;"><div style="" class="" id="yiv1867486344yui_3_16_0_1_1403170573665_4835">Hello,<br class="" style="">I was following the tutorial in page <a style="" class="" href="http://fieldtrip.fcdonders.nl/tutorial/headmodel_eeg">http://fieldtrip.fcdonders.nl/tutorial/headmodel_eeg</a> to construct a head model for EEG, I've done the same steps explained in the tutorial but when I reach the meshing stage and use:<br style="" class=""><pre style="" class="">bnd=ft_prepare_mesh(cfg,segmentedmri);<br style="" class=""><br style=""
 class="">I get the following error:<br style="" class=""><br style="" class="">??? Undefined function or method 'myvolumefillholes' for input arguments of type 'logical'.<br style="" class=""><br style="" class=""><br style="" class="">error in ==> triangulate_seg at 73<br style="" class="">seg = myvolumefillholes(seg);<br style="" class=""><br style="" class=""><br style="" class=""><br style="" class="">error in ==> prepare_mesh_segmentation at 101<br style="" class="">  [pnt, tri] = triangulate_seg(seg, cfg.numvertices(i), ori);<br style="" class=""><br style="" class=""><br style="" class="">error in ==> ft_prepare_mesh at 178<br style="" class="">  bnd = prepare_mesh_segmentation(cfg, mri);<br style="" class="">-----------------------------------------------------------------------------<br style="" class="">although I'm geting the same results for the data structure as in the tutorial:<br><br style="" class="">disp(segmentedmri)<br
 style="" class="">          <br style="" class="">dim: [256 256 256]<br style="" class="">    <br style="" class="">transform: [4x4 double]<br style="" class="">     <br style="" class="">coordsys: 'ctf'<br style="" class="">         <br style="" class="">unit: 'mm'<br style="" class="">        <br style="" class="">brain: [256x256x256 logical]<br style="" class="">        <br style="" class="">skull: [256x256x256 logical]<br style="" class="">        <br style="" class="">scalp: [256x256x256 logical]<br style="" class="">          <br style="" class="">cfg: [1x1 struct]<br>----------------------------------------------------------<br>can any one help in this matter please?<br><br>Regards<br>Rasha<br style="" class=""><br style="" class=""><br style="" class=""><br style="" class=""></pre><br style="" class=""></div><div style="" class="" id="yiv1867486344yui_3_16_0_1_1403170573665_4835"> </div></div></div></div></div></body></html>