Description Usage Arguments Value Author(s) Examples
View source: R/multiscaleSVDxpts.R
Compute a smoothing matrix based on an input matrix of point coordinates as well as neighborhood intensity patterns. this performs a form of edge preserving smoothing.
1 2 3 4 5 6 7 8 9 | knnSmoothImage(
img,
mask,
radius,
intensityWeight = 0.1,
spatialSigma = 20,
iterations = 1,
returnMatrix = FALSE
)
|
img |
input image to smooth |
mask |
input image mask |
radius |
number of neighbors, higher causes more smoothing |
intensityWeight |
weight for intensity component, value 1 will weight local voxel intensity roughly equally to spatial component |
spatialSigma |
for gaussian defining spatial distances |
iterations |
number of iterations over which to apply smoothing kernel |
returnMatrix |
boolean, will return smoothing matrix instead of image. |
antsImage is output
Avants BB
1 2 3 4 5 6 7 | ## Not run:
img = antsImageRead( getANTsRData( 'r16' ) )
mask = getMask( img )
simg = knnSmoothImage( img=img, mask=mask, radius=2, intensityWeight=1,
spatialSigma=1.5, iterations=1 )
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.