Skip to contents

Create Brain Atlases

Turn a parcellation into a ggseg_atlas you can plot

create_cerebellar_from_annotation() experimental
Create cerebellar atlas from FreeSurfer annotation
create_cerebellar_from_gifti() experimental
Create cerebellar atlas from SUIT flatmap
create_cerebellar_from_volume() experimental
Create cerebellar atlas from volume segmentation
create_cortical_from_annotation() maturing
Create cortical atlas from FreeSurfer annotation
create_cortical_from_cifti() experimental
Create cortical atlas from a CIFTI file
create_cortical_from_gifti() experimental
Create cortical atlas from GIFTI annotation files
create_cortical_from_labels() experimental
Create brain atlas from label files
create_cortical_from_neuromaps() experimental
Create cortical atlas from a neuromaps annotation
create_subcortical_from_volume() experimental
Create brain atlas from subcortical segmentation
create_tract_from_tractography() experimental
Create brain atlas from white matter tracts
create_tract_from_volume() experimental
Create a white matter tract atlas from a label volume
create_wholebrain_from_volume() experimental
Create atlas from whole-brain volumetric parcellation

Shape an Atlas’s Geometry

Simplify, smooth and grow a finished atlas’s 2D outlines. These run on the returned atlas, not during the build, so retuning one is cheap.

atlas_polish() experimental
Simplify and smooth an atlas against a vertex budget
atlas_simplify()
Reduce an atlas's vertex count
atlas_smooth()
Round off an atlas's voxel staircase
atlas_dilate()
Grow or shrink an atlas's regions
context_pattern() experimental
The label pattern that matches an atlas's backdrop
count_vertices()
Count the vertices an atlas carries

Curate an Atlas

The atlas_region_* and atlas_view_* vocabulary, re-exported from ggseg.formats, plus the constructor that validates a hand-edited atlas. ?atlas-verbs groups them by what they change.

Atlas Repository

Create and maintain a ggseg atlas package

setup_atlas_repo()
Create a new ggseg atlas package
use_atlas_github_actions()
Add ggsegverse GitHub Actions workflows to a package
ggseg_atlas_github_actions()
Workflows use_atlas_github_actions() can write
sitrep()
Report on the ggseg.extra setup

Lookup Tables

Read, write and build FreeSurfer-style colour lookup tables

read_lut()
Read FreeSurfer LUT
write_lut()
Write FreeSurfer LUT
get_lut()
Read LUT and add hex colours
is_lut()
Check if object is a LUT
lut_add()
Add rows to a FreeSurfer LUT
lut_combine()
Combine FreeSurfer LUTs
lut_classify_anatomy()
Classify lookup-table labels as cortical, subcortical, or cerebellar
lut_generate_colors()
Generate a palette for a colourless lookup table

Subcortical Helpers

Compose slice views and anatomical context for subcortical atlases

subcortical_slabs()
Build subcortical slabs from a label bounding box

Anatomical Coregistration

Align an atlas volume to a FreeSurfer subject for anatomical context

coregister_volume()
Coregister an atlas volume to a FreeSurfer subject
project_volume_anatomical()
Project atlas labels onto FreeSurfer anatomical context
prepare_subcortical_anatomical()
Prepare an atlas for the subcortical pipeline with anatomical context
prepare_subcortical_mni152()
Embed MNI152 subcortical parcels in a FreeSurfer aseg for grey-brain context
aseg_subcortical_labels()
Lumped aseg subcortical structures a parcellation typically subdivides

Cerebellar Helpers

SUIT surfaces and MNI-to-SUIT transforms for cerebellar atlases

suit_flatmap_path()
Path to bundled SUIT flatmap surface
suit_3d_path()
Path to bundled SUIT 3D cerebellar surface
suit_deformation_field() experimental
Download SUIT deformation field for MNI-to-SUIT transforms
transform_mni_to_suit() experimental
Transform a volume from MNI space to SUIT cerebellar space
read_suit_parcellation() experimental
Read SUIT cerebellar parcellation from GIFTI

Reading Parcellation Files

Read the formats the creation pipelines accept

read_annotation_data()
Read annotation data from files
read_gifti_annotation()
Read GIFTI annotation files
read_cifti_annotation()
Read CIFTI annotation file
read_cifti_subcortical() experimental
Extract subcortical labels from a CIFTI file
read_neuromaps_annotation()
Read neuromaps annotation files
read_neuromaps_volume()
Read neuromaps volume annotation via surface projection
read_tractography()
Read tractography file

Utilities

mri_surf2surf_rereg()
Re-register an annotation file
label_to_region()
Derive an atlas region from a label
get_verbose()
Get verbose setting
as_verbosity()
Coerce a value to a verbosity level