R/compose_transform_to_file.R
compose_transform_to_file.RdThis is a thin wrapper for antsApplyTransforms but
is specifically for composing a transform and getting a file out.
compose_transform_to_file( fixed, moving, transformlist = NULL, output_prefix = NULL )
| fixed | fixed image defining domain into which the moving image is transformed. |
|---|---|
| moving | moving image to be mapped to fixed space. |
| transformlist | haracter vector of transforms generated by
|
| output_prefix | Prefix of output filename to return. The prefix will
add |
A character filename
library(ANTsR) fixed <- antsImageRead( getANTsRData("r16") ,2) moving <- antsImageRead( getANTsRData("r64") ,2) fixed <- resampleImage(fixed,c(64,64),1,0) moving <- resampleImage(moving,c(64,64),1,0) mytx <- antsRegistration(fixed=fixed , moving=moving , typeofTransform = c("SyN"), verbose = TRUE ) composed <- compose_transform_to_file( fixed=fixed, moving=moving, transformlist=mytx$fwdtransforms)