mne.morph_labels

mne.morph_labels(labels, subject_to, subject_from=None, subjects_dir=None, surf_name='white', verbose=None)[source]

Morph a set of labels.

This is useful when morphing a set of non-overlapping labels (such as those obtained with read_labels_from_annot()) from one subject to another.

Parameters
labelslist

The labels to morph.

subject_tostr

The subject to morph labels to.

subject_fromstr | None

The subject to morph labels from. Can be None if the labels have the .subject property defined.

subjects_dirstr | None

The path to the FreeSurfer subjects reconstructions. It corresponds to FreeSurfer environment variable SUBJECTS_DIR.

surf_namestr

Surface used to obtain vertex locations, e.g., ‘white’, ‘pial’.

verbosebool, str, int, or None

If not None, override default verbose level (see mne.verbose() and Logging documentation for more). If used, it should be passed as a keyword-argument only.

Returns
labelslist

The morphed labels.

Notes

This does not use the same algorithm as Freesurfer, so the results morphing (e.g., from 'fsaverage' to your subject) might not match what Freesurfer produces during recon-all.

New in version 0.18.