Creates a data object for subcortical brain atlases. Subcortical atlases use individual 3D meshes for each structure (e.g., hippocampus, amygdala).
Usage
ggseg_data_subcortical(geom = NULL, meshes = NULL, ...)
brain_data_subcortical(sf = NULL, meshes = NULL)Arguments
- geom
2D geometry for rendering, stored in the single
geomslot: either an sf data.frame (columnslabel,view,geometry) or abrain_polygonsdata.frame (seesf_to_polygons()). The class ofgeomdetermines the rendering path used downstream.- meshes
data.frame with columns label and mesh (list-column). Each mesh is a list with:
vertices: data.frame with x, y, z columns
faces: data.frame with i, j, k columns (1-based triangle indices)
- ...
Captures a deprecated
sfargument: if supplied it is converted to the polygon representation viasf_to_polygons()and a deprecation warning is issued. Prefer passing 2D geometry viageom.- sf
Deprecated. Pass 2D geometry via
geominstead.
Examples
data <- ggseg_data_subcortical(
meshes = data.frame(
label = "hippocampus_left",
mesh = I(list(list(
vertices = data.frame(x = 1:10, y = 1:10, z = 1:10),
faces = data.frame(i = 1:3, j = 2:4, k = 3:5)
)))
)
)
