antsMatrix_class.Rd
An S4 class to hold an antsMatrix imported from ITK types C++ type used to represent an element of the matrix pointer to the actual image C++ type 'itk::image< pixeltype , dimension >::Pointer'
# S4 method for class 'antsMatrix'
initialize(.Object, elementtype)
elementtype
string of the type of storage of the matrix e.g. "float"
pointer
the memory location
mat <- as.antsMatrix(matrix(rnorm(10), nrow = 2))
as.data.frame(mat)
#> V1 V2 V3 V4 V5
#> 1 0.3632291 0.5279072 -1.6132584 -0.7844056 -0.6159325
#> 2 -1.0105687 0.2486476 0.9243788 -0.9378335 0.2044871
as.matrix(mat)
#> V1 V2 V3 V4 V5
#> [1,] 0.3632291 0.5279072 -1.6132584 -0.7844056 -0.6159325
#> [2,] -1.0105687 0.2486476 0.9243788 -0.9378335 0.2044871