<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div style="font-family: Tahoma; font-size: 13px;" class="">Dear Fieldtrippers, </div><div style="font-family: Tahoma; font-size: 13px;" class=""><br class=""></div><div style="font-family: Tahoma; font-size: 13px;" class="">my current question(s) has previously been answered here by Julian Keil: <a href="https://mailman.science.ru.nl/pipermail/fieldtrip/2015-December/009882.html" class="">https://mailman.science.ru.nl/pipermail/fieldtrip/2015-December/009882.html</a> yet I appear to face a conceptual problems in my understanding. </div><div style="font-family: Tahoma; font-size: 13px;" class=""><br class=""></div><div style="font-family: Tahoma; font-size: 13px;" class="">So the goal is to compute the virtual channels of a certain atlas region let say the SMA. </div><div style="font-family: Tahoma; font-size: 13px;" class="">As we do not have individual MRI, I thought it should be possible to make use of the MNI template MRI the 'standard_mri.mat' as included in fieldtrip. </div><div style="font-family: Tahoma; font-size: 13px;" class=""><br class=""></div><div style="font-family: Tahoma; font-size: 13px;" class="">Now according to Julian's answer from the above link the steps to go about the virtual channels reconstruction is: </div><div style="font-family: Tahoma; font-size: 13px;" class="">1. Compute the virtual channels for all grid points in the cortex (regular grid /sourcemodel)</div><div style="font-family: Tahoma; font-size: 13px;" class="">--> So here I construct an MRI based grid</div><div style="font-family: Tahoma; font-size: 13px;" class="">
</div><div style="font-family: Tahoma; font-size: 13px;" class="">load standard_mri.mat</div><div style="font-family: Tahoma; font-size: 13px;" class="">cfg = [];</div><div style="font-family: Tahoma; font-size: 13px;" class="">cfg.mri = mri;</div><div style="font-family: Tahoma; font-size: 13px;" class="">template_grid = ft_prepare_sourcemodel(cfg);</div><div style="font-family: Tahoma; font-size: 13px;" class=""><br class=""></div><div style="font-family: Tahoma; font-size: 13px;" class="">this yields a grid with dimensions of 19x22x18 and 4093 gridpoints within the brain.</div><div style="font-family: Tahoma; font-size: 13px;" class=""><br class=""></div><div style="font-family: Tahoma; font-size: 13px;" class="">2. If you have computed the virtual channels on an individual MRI, make sure that the position corresponds to the standard MRI (I think that's described in the source analysis -tutorial)</div><div style="font-family: Tahoma; font-size: 13px;" class="">--> this is obsolete in my case i guess</div><div style="font-family: Tahoma; font-size: 13px;" class=""><br class=""></div><div style="font-family: Tahoma; font-size: 13px;" class="">3. Build a high resolution 3D-Grid on the standard MRI (It's important to use one grid point per voxel)</div><div style="font-family: Tahoma; font-size: 13px;" class="">--> I am not sure how. the following gives me an Error 'incorrect cfg specification for constructing a dipole grid':</div><div style="font-family: Tahoma; font-size: 13px;" class="">cfg = [];</div><div style="font-family: Tahoma; font-size: 13px;" class="">cfg.grid.xgrid = -90:1:90;</div><div style="font-family: Tahoma; font-size: 13px;" class="">cfg.grid.ygrid = -108:1:108;</div><div style="font-family: Tahoma; font-size: 13px;" class="">cfg.grid.zgrid = -90:1:90;</div><div style="font-family: Tahoma; font-size: 13px;" class="">cfg.grid.unit = 'mm';</div><div style="font-family: Tahoma; font-size: 13px;" class="">cfg.grid.tight = 'yes';</div><div style="font-family: Tahoma; font-size: 13px;" class="">cfg.mri = mri;</div><div style="font-family: Tahoma; font-size: 13px;" class="">high_res_grid_mm = ft_prepare_sourcemodel(cfg)</div><div style="font-family: Tahoma; font-size: 13px;" class=""><br class=""></div><div style="font-family: Tahoma; font-size: 13px;" class=""><br class=""></div><div style="font-family: Tahoma; font-size: 13px;" class="">4. Select all grid points from the grid of step 3 which belongs to an atlas (ft_volumelookup)</div><div style="font-family: Tahoma; font-size: 13px;" class="">--> Now atlas has a dimension of 91x109x91 but the standard mri of 181x217x181. Here, I am wondering how to align the two to use logical indexing for finding the ROI voxels.</div><div style="font-family: Tahoma; font-size: 13px;" class=""><br class=""></div><div style="font-family: Tahoma; font-size: 13px;" class="">5. Use pythagoras to find the virtual channels from step 2 closest to the grid points from step 4.</div><div style="font-family: Tahoma; font-size: 13px;" class="">--> This is clear if the grid from step 1 and 3 are of the same dimension which is however not the case here.</div><div style="font-family: Tahoma; font-size: 13px;" class=""><br class=""></div><div style="font-family: Tahoma; font-size: 13px;" class="">I would appreciate any feedback and ideas on this issue.</div><div style="font-family: Tahoma; font-size: 13px;" class=""><br class=""></div><div style="font-family: Tahoma; font-size: 13px;" class="">Kind regards, </div><div style="font-family: Tahoma; font-size: 13px;" class=""><br class=""></div><div style="font-family: Tahoma; font-size: 13px;" class="">Gabriel</div></body></html>