extractSlice | R Documentation |
extract a slice from an image and return an image of dimensionality, d-1
extractSlice(image, slice, direction, collapseStrategy = 0)
image |
antsImage to crop |
slice |
which slice, integer |
direction |
which axis, integer |
collapseStrategy |
collapse sub-matrix. 0: Collapse sub-matrix if positive definite. Otherwise, thrown exception. Default. 1: Set sub-matrix to identity. 2: Collapse if positive definite. Otherwise, set to identity. |
antsImage of dimension - 1
Brian B. Avants, Nicholas J. Tustison
fi <- makeImage(c(10, 10, 10), rnorm(1000))
slice <- extractSlice(fi, 1, 1)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.