mne.vertex_to_mni¶
-
mne.
vertex_to_mni
(vertices, hemis, subject, subjects_dir=None, mode=None, verbose=None)[source]¶ Convert the array of vertices for a hemisphere to MNI coordinates.
- Parameters
- vertices
int
, orlist
ofint
Vertex number(s) to convert
- hemis
int
, orlist
ofint
Hemisphere(s) the vertices belong to
- subject
str
Name of the subject to load surfaces from.
- subjects_dir
str
, orNone
Path to SUBJECTS_DIR if it is not set in the environment.
- mode
str
|None
Either ‘nibabel’ or ‘freesurfer’ for the software to use to obtain the transforms. If None, ‘nibabel’ is tried first, falling back to ‘freesurfer’ if it fails. Results should be equivalent with either option, but nibabel may be quicker (and more pythonic).
- verbosebool,
str
,int
, orNone
If not None, override default verbose level (see
mne.verbose()
and Logging documentation for more).
- vertices
- Returns
- coordinates
array
, shape (n_vertices, 3) The MNI coordinates (in mm) of the vertices
- coordinates
Notes
This function requires either nibabel (in Python) or Freesurfer (with utility “mri_info”) to be correctly installed.