load.T.MAT {espadon}R Documentation

Loading of information about transfer matrices between frames of reference of patient Rdcm objects.

Description

The load.T.MAT function lists all the frames of reference of the objects included in the patient directory. It concatenates all the information of the reg matrices of a directory, creating, among other things, a list of 4x4 transfer matrices between frames of reference.

Usage

load.T.MAT(dirname, upgrade.to.latest.version = FALSE)

Arguments

dirname

Full paths of the directories of a single patient, or vector of full.path of Rdcm.files.

upgrade.to.latest.version

Boolean. If TRUE, the function attempts to upgrade to the latest version, parsing the DICOM data. It may take longer to load the data. Consider using the Rdcm.upgrade function.

Value

Returns a "t.mat" class object. It is a list that includes :

Examples

# First, save toy patient objects to a temporary file pat.dir for testing.
pat.dir <- file.path (tempdir(), "PM_Rdcm") 
dir.create (pat.dir, recursive = TRUE) 
patient <- toy.load.patient (modality = c("ct", "mr"), roi.name = "", 
                             dxyz = c (4, 4, 4))
save.to.Rdcm (patient$ct[[1]], dirname = pat.dir)
save.to.Rdcm (patient$mr[[1]], dirname = pat.dir)
save.T.MAT (patient$T.MAT, dirname = pat.dir)
# Rdcm files in pat.dir
list.files(pat.dir)

T.MAT <- load.T.MAT (pat.dir)
T.MAT

# Cleaning  temporary directory
unlink (pat.dir, recursive = TRUE)

[Package espadon version 1.7.0 Index]