split a mask into n labeled sub-masks

splitMask(mask, n = NA, voxchunk = NA)

Arguments

mask

antsImage mask

n

number of mask chunks (if voxchunk is not set)

voxchunk

number of voxels per chunk (if n is not set)

Value

relabeledMask

Author

Avants BB, Tustison NJ, Pustina D

Examples

mask <- getMask(antsImageRead(getANTsRData("r16")))
smask <- splitMask(mask, 10)