[242173]: / man / get_neighbors.Rd

Download this file

46 lines (38 with data), 1.1 kB

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/amoment.R
\name{get_neighbors}
\alias{get_neighbors}
\title{Calculate Moments of Neighborhood}
\usage{
get_neighbors(
image,
window = NULL,
nvoxels = NULL,
mask = NULL,
rm.value = FALSE,
check.wrap = TRUE,
rep.value = 0,
...
)
}
\arguments{
\item{image}{input image}
\item{window}{window (in width) for the neighborhood}
\item{nvoxels}{window (in voxels) for the neighborhood 1 results in a 3x3 cube}
\item{mask}{array or object of class nifti of same size as image}
\item{rm.value}{remove the voxel itself before taking the moment}
\item{check.wrap}{Logical - check wrapround and put \code{rep.value} in
for the wrapped values}
\item{rep.value}{Replace wrapped values (edge of image) to this value}
\item{...}{Not used}
}
\value{
Array with same dimensions as image
}
\description{
This function calculates Local Moments (mean, standard deviation, skew) for an array.
}
\examples{
x = array(rnorm(1000), dim=c(10, 10, 10))
neigh = get_neighbors(x, nvoxels = 1)
}