powered by
Computes the density of values of an image with the option for a mask.
# S3 method for nifti density(x, ..., mask)# S3 method for anlz density(x, ..., mask)
# S3 method for anlz density(x, ..., mask)
Output of density
density
Object of class nifti
nifti
Arguments passed to density.default
density.default
object to subset the image. If missing, then all values of the image are plotted.
img = nifti(array(rnorm(10^3), dim = rep(10, 3))) mask = img > 0 density(img, mask = mask) density(img) density(as.anlz(img), mask = mask) density(as.anlz(img))
Run the code above in your browser using DataLab