as.array¶
purpose:
antsImage to numeric array
description:
Convert/coerce an antsImage object to a numeric array . More precisely, extract a numeric array from an antsImage .
usage:
as.array( x [, mask] [, region] )
examples:
# extract a vector from an image 'img' of class 'antsImage' by considering
# only the region starting at index (1,1,1) with size (10,10,10)
reg = new("antsRegion", index = c(1, 1, 1), size = c(10, 10, 10))
vect = as.array(img, region = reg)