get_neighbors: Calculate Moments of Neighborhood

Description Usage Arguments Value Examples

View source: R/amoment.R

Description

This function calculates Local Moments (mean, standard deviation, skew) for an array.

Usage

1
2
get_neighbors(image, window = NULL, nvoxels = NULL, mask = NULL,
  rm.value = FALSE, check.wrap = TRUE, rep.value = 0, ...)

Arguments

image

input image

window

window (in width) for the neighborhood

nvoxels

window (in voxels) for the neighborhood 1 results in a 3x3 cube

mask

array or object of class nifti of same size as image

rm.value

remove the voxel itself before taking the moment

check.wrap

Logical - check wrapround and put rep.value in for the wrapped values

rep.value

Replace wrapped values (edge of image) to this value

...

Not used

Value

Array with same dimensions as image

Examples

1
2
x = array(rnorm(1000), dim=c(10, 10, 10))
neigh = get_neighbors(x, nvoxels = 1)

neuroconductor-devel/ichseg documentation built on Sept. 5, 2019, 8:01 p.m.