Computes sample quantiles for an image, with the option of a mask.

# S3 method for class 'antsImage'
quantile(x, ..., mask)

Arguments

x

Object of class antsImage

...

Arguments passed to quantile

mask

object to subset the image. If missing, then all values of the image are used

Value

Output of quantile

Examples

img <- makeImage(c(10, 10), rnorm(100))
mask <- img > 0
quantile(img, mask = mask)
#>         0%        25%        50%        75%       100% 
#> 0.02704368 0.27065562 0.63341951 0.91105765 2.61811447