Read vertex-wise brain surface data from a GIFTI file. The file must be a GIFTI *func* file (not a GIFTI *surf* file containing a mesh, use read_nisurface for loading GIFTI surf files).

read.fs.morph.gii(filepath, element_index = 1L)

Arguments

filepath,

string. Full path to the input GIFTI file.

element_index

integer, the element to load in case the GIFTI file containes several datasets (usually time series). Defaults to the first element, 1L.

Value

data, vector of double or integer. The brain morphometry data, one value per vertex. The data type depends on the data type in the file.

Note

This function requires the `gifti` package, which is an optional dependency, to be installed. It also assumes that the dataset contains a vector or a matrix/array in which all dimensions except for 1 are empty.

See also