Learn R Programming

SPUTNIK (version 1.1)

smoothImage,ms.image-method: Apply Gaussian smoothing to an MS image.

Description

Apply Gaussian smoothing to an MS image.

Usage

# S4 method for ms.image
smoothImage(object, sigma = 2)

Arguments

object

ms.image-class object. See msImage.

sigma

numeric (default = 2). Standard deviation of the smoothing Gaussian kernel.

Value

ms.image-class smoothed msImage.

Examples

Run this code
# NOT RUN {
## Load package
library("SPUTNIK")

## Create ms.image-class object
msIm <- msImage(values = matrix(rnorm(200), 40, 50), name = "test", scale = TRUE)

## Smooth the image colors
msImSmoothed <- smoothImage(msIm, sigma = 5)
# }

Run the code above in your browser using DataLab