surfaceras.to.ras: Translate surface RAS coordinates, as used in surface...

Description Usage Arguments Value Note

View source: R/mghheader.R

Description

Translate surface RAS coordinates, as used in surface vertices and surface labels, to volume RAS.

Usage

1
2
3
4
5
6
surfaceras.to.ras(
  header_cras,
  sras_coords,
  first_voxel_RAS = c(1, 1, 1),
  invert_transform = FALSE
)

Arguments

header_cras

an MGH header instance from which to extract the cras (center RAS), or the cras vector, i.e., a numerical vector of length 3

sras_coords

nx3 numerical vector, the input surface RAS coordinates. Could be the vertex coordinates of an 'fs.surface' instance, or the RAS coords from a surface label. Use the orig surfaces.

first_voxel_RAS

the RAS of the first voxel, see mghheader.centervoxelRAS.from.firstvoxelRAS for details. Ignored if 'header_cras' is a vector.

invert_transform

logical, whether to invert the transform. Do not use this, call link{ras.to.surfaceras} instead.

Value

the RAS coords for the input sras_coords

Note

The RAS can be computed from Surface RAS by adding the center RAS coordinates, i.e., it is nothing but a translation.


freesurferformats documentation built on May 25, 2021, 5:10 p.m.