R/croppingAndPaddingUtilities.R
padOrCropImageToSize.Rd
Pad or crop image to a specified size
padOrCropImageToSize(image, size)
image | Input ANTs image |
---|---|
size | size of the output image. |
a padded/cropped image
Tustison NJ
library( ANTsR ) image <- antsImageRead( getANTsRData( "r16" ) ) paddedImage <- padOrCropImageToSize( image, c( 333, 333 ) )