convert MNI coordinates into the surface vertex index

Dear AFNI experts,

I would like to use a function to convert the x, y, z MNI152 coordinates into the vertex index of a surface.

Do you know any function that can give me the vertex index which corresponds to certain coordinates as output?

Thank you very much in advance.

Best regards,
Marina

Hi, Marina-

This post describes how to do it with Surf2VolCoord:
https://afni.nimh.nih.gov/afni/community/board/read.php?1,162943,163051#msg-163051
Basically, you put your coordinate location into a text file (“x y z” values in one row), preferably using RAI DICOM coordinates, and then you can get the closest surface index (and the Euclidean distance between your coords and that point). It might also be a good idea to doublecheck things in SUMA.

Here is a set of SUMA-generated standard surfaces and parcellations for the MNI 152 brain, if you don’t have it already:
https://afni.nimh.nih.gov/pub/dist/tgz/suma_MNI152_2009.tgz

–pt

Hi Paul,

Thank you very much for the information!

Now we are using the Freesurfer surfaces and I would like to implement that function. In addition, we are also interested in using SUMA for certain analyzes.

So how should I treat my freesurfer surfaces to use AFNI/SUMA functions?
If I have to transform them to gifti, what is the most correct way?

Thank you very much in advance.

Best wishes,
Marina

Hi, Marina-

After you run FreeSurfer, you just need to run @SUMA_Make_Spec_FS to convert everything to AFNI+SUMA usable formats (NIFTI, GIFTI, etc.) and standard meshes.

Maybe see here for an example?
https://afni.nimh.nih.gov/pub/dist/doc/htmldoc/tutorials/fs/fs_fsprep.html

–pt

Perfect!

Thank you very much for the help, Paul.

Best regards,
Marina