Load a brain surface annotation, i.e., a cortical parcellation based on an atlas, for a group of subjects.
Arguments
- subjects_dir,
string. The FreeSurfer SUBJECTS_DIR, i.e., a directory containing the data for all your subjects, each in a subdir named after the subject identifier.
- subjects_list,
vector of strings. The subject identifiers.
- hemi,
string, one of 'lh' or 'rh'. The hemisphere name. Used to construct the names of the annotation and morphometry data files to be loaded.
- atlas,
string. The atlas name. E.g., "aparc", "aparc.2009s", or "aparc.DKTatlas". Used to construct the name of the annotation file to be loaded.
Value
list of annotations, as returned by freesurferformats::read.fs.annot(). If hemi is 'both', the annotations are the results of merging over the hemispheres for each subject.
See also
Other atlas functions:
get.atlas.region.names(),
group.agg.atlas.native(),
group.agg.atlas.standard(),
group.label.from.annot(),
label.from.annotdata(),
label.to.annot(),
regions.to.ignore(),
spread.values.over.annot(),
spread.values.over.hemi(),
spread.values.over.subject(),
subject.annot(),
subject.atlas.agg(),
subject.label.from.annot(),
subject.lobes()
Examples
if (FALSE) { # \dontrun{
fsbrain::download_optional_data();
subjects_dir = fsbrain::get_optional_data_filepath("subjects_dir");
subjects_list = c("subject1", "subject2");
annotations = group.annot(subjects_dir, subjects_list, "lh", "aparc");
} # }