surfplot.utils.add_fslr_medial_wall

surfplot.utils.add_fslr_medial_wall(data, split=False)[source]

Add medial wall to data in fsLR space

Data in 32k fs_LR space (e.g., Human Connectome Project data) often exclude the medial wall in their data arrays, which results in a total of 59412 vertices across hemispheres. This function adds back in the missing medial wall vertices to produce a data array with the full 64984 vertices, which is required for plotting with 32k density fsLR surfaces.

Parameters
  • data (numpy.ndarray) – Surface vertices. Must have exactly 59412 or 64984 vertices. Note that if 64984 vertices are present, then the medial wall is already included. If so, then only hemisphere splitting will be performed, if applied.

  • split (bool) – Return left and right hemipsheres as separate arrays. Default: False

Returns

numpy.ndarray – Vertices with medial wall included (64984 vertices total)

Raises

ValueErrordata has the incorrect number of vertices (59412 or 64984 only accepted)