If you load in a surface, then use the annotation (read_annotation.m, there are lots of docs in the mfile)
On 08/22/2018 12:18 PM, Yash Patel wrote: > > External Email - Use Caution > > Hi Dr.Greve, > > I ran: > seg = MRIread('aparc+aseg.mgz'); > > input = MRIread('surface_pf05.mgh'); > > ind = find('aparc+aseg.mgz' == 1002); #where 1002 is a roi number > > segmode = mode(input(ind)); > > This is where i run into an error: Index exceeds array bounds. > > Is this due to ".mgz" as segmentation vol and input is ".mgh" ? > > Thanks, > Yash > > On Wed, Aug 22, 2018 at 11:30 AM, Bruce Fischl > <fis...@nmr.mgh.harvard.edu <mailto:fis...@nmr.mgh.harvard.edu>> wrote: > > Hi Yash > > we already create the volumetric representations for you (e.g. the > aparc+aseg.mgz). You should be able to use it to generate > histograms of each parcel in 5-10 lines of matlab code > > cheers > Bruce > > > On Wed, 22 Aug 2018, Yash Patel wrote: > > > External Email - Use Caution > > > Hi FS experts, > > I am attempting to extract signal intensity from the middle of > the cortex, using mri_vol2surf. With said surface, I would like > to extract the mode (and other histogram measures) from each > of the 34 parcellations of the DK atlas. I realize this needs to > be done in matlab, and hence the difficulty. Would I need to > first convert the segmentation volume (such as lh.aparc.annot ) > into ".mgh" format, and use it with the output of mri_vol2surf > which would be in ".mgh" surface format. Since I am a complete > beginner to matlab exemplary code would be very helpful. > > Thank you, > Yash > > On Wed, Mar 14, 2018 at 6:26 PM, Douglas N. Greve > <dgr...@mgh.harvard.edu <mailto:dgr...@mgh.harvard.edu>> wrote: > No, sorry. You can do it easily enough in matlab, eg > > seg = MRIread('seg.mgz'); > > input = MRIread('input.mgz'); > > ind = find(seg.vol == SegNo); > > segmode = mode(input.vol(ind)); > > [h x] = hist(input.vol(ind),100); > > > > On 03/13/2018 07:58 PM, Yash Patel wrote: > > Any updates or ideas in extracting histogram data from > mri_segstats? > > > > On Sun, Mar 11, 2018 at 1:16 PM Yash Patel > > <ypa...@research.baycrest.org > <mailto:ypa...@research.baycrest.org> > <mailto:ypa...@research.baycrest.org > <mailto:ypa...@research.baycrest.org>>> > > wrote: > > > > Dear all, > > > > I am using mri_segstats to obtain intensity values > from each of > > the 34 cortical parcellations in the > Desikan-Killiany Atlas; this > > provides metrics such as mean, min, max, range, > and standard > > deviation. > > Is there a way to extract information such as the > *mode*, or > > information to create a histogram for each of the > particular regions? > > > > Thank you, > > Yash > > > > > > > > _______________________________________________ > > Freesurfer mailing list > > Freesurfer@nmr.mgh.harvard.edu > <mailto:Freesurfer@nmr.mgh.harvard.edu> > > > https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer > <https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer> > > _______________________________________________ > Freesurfer mailing list > Freesurfer@nmr.mgh.harvard.edu > <mailto:Freesurfer@nmr.mgh.harvard.edu> > https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer > <https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer> > > > The information in this e-mail is intended only for the > person to whom it is > addressed. If you believe this e-mail was sent to you in > error and the e-mail > contains patient information, please contact the > Partners Compliance HelpLine at > http://www.partners.org/complianceline > <http://www.partners.org/complianceline> . If the e-mail was > sent to you in error > but does not contain patient information, please contact > the sender and properly > dispose of the e-mail. > > > > > _______________________________________________ > Freesurfer mailing list > Freesurfer@nmr.mgh.harvard.edu <mailto:Freesurfer@nmr.mgh.harvard.edu> > https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer > <https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer> > > > The information in this e-mail is intended only for the person to > whom it is > addressed. If you believe this e-mail was sent to you in error and > the e-mail > contains patient information, please contact the Partners > Compliance HelpLine at > http://www.partners.org/complianceline > <http://www.partners.org/complianceline> . If the e-mail was sent > to you in error > but does not contain patient information, please contact the > sender and properly > dispose of the e-mail. > > _______________________________________________ Freesurfer mailing list Freesurfer@nmr.mgh.harvard.edu https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer