spc-loess: loess smoothing interpolation for spectra Spectra can be...

spc.loessR Documentation

loess smoothing interpolation for spectra Spectra can be smoothed and interpolated on a new wavelength axis using loess.

Description

Applying loess to each of the spectra, an interpolation onto a new wavelength axis is performed. At the same time, the specta are smoothed in order to increase the signal : noise ratio. See loess and loess.control on the parameters that control the amount of smoothing.

Usage

spc.loess(spc, newx, enp.target = nwl(spc)/4, surface = "direct", ...)

Arguments

spc

the hyperSpec object

newx

wavelengh axis to interpolate on

enp.target, surface, ...

parameters for loess and loess.control.

Value

a new hyperspec object.

Author(s)

C. Beleites

See Also

loess, loess.control

Examples


plot (flu, col = "darkgray")
plot (spc.loess(flu, seq (420, 470, 5)), add = TRUE, col = "red")

flu [[3, ]] <- NA_real_
smooth <- spc.loess(flu, seq (420, 470, 5))
smooth [[, ]]
plot (smooth, add = TRUE, col = "blue")


hyperSpec documentation built on May 29, 2024, 7:28 a.m.