R/read_fs_transform.R
read.fs.transform.dat.Rd
Load transformation matrix from a tkregister dat file.
read.fs.transform.dat(filepath)
filepath | character string, the full path to the transform file. |
---|
4x4 numerical matrix, the transformation matrix
Other header coordinate space:
mghheader.is.ras.valid()
,
mghheader.ras2vox.tkreg()
,
mghheader.ras2vox()
,
mghheader.scanner2tkreg()
,
mghheader.tkreg2scanner()
,
mghheader.vox2ras.tkreg()
,
mghheader.vox2ras()
,
read.fs.transform.lta()
,
read.fs.transform.xfm()
,
read.fs.transform()
,
sm0to1()
,
sm1to0()
tf_file = system.file("extdata", "register.dat",
package = "freesurferformats",
mustWork = TRUE);
transform = read.fs.transform.dat(tf_file);
transform$matrix;
#> [,1] [,2] [,3] [,4]
#> [1,] 0.999869585 0.006901878 0.01459838 0.08490597
#> [2,] -0.014461628 -0.019486522 0.99970520 -17.40991402
#> [3,] 0.007197575 -0.999786258 -0.01938400 -7.02687693
#> [4,] 0.000000000 0.000000000 0.00000000 1.00000000