View source: R/smooth_intens.R
smooth_intens | R Documentation |
This smoother can enhance the signal to noise ratio of the data and uses a Savitzky-Golay filter with a running window of data points and the polynomial specified.
smooth_intens(x, ...)
## Default S3 method:
smooth_intens(x, ...)
## S3 method for class 'OpenSpecy'
smooth_intens(
x,
polynomial = 3,
window = 11,
derivative = 1,
abs = TRUE,
make_rel = TRUE,
...
)
x |
an object of class |
polynomial |
polynomial order for the filter |
window |
number of data points in the window, filter length (must be odd). |
derivative |
the derivative order if you want to calculate the derivative. Zero (default) is no derivative. |
abs |
logical; whether you want to calculate the absolute value of the resulting output. |
make_rel |
logical; if |
... |
further arguments passed to |
This is a wrapper around the filter function in the signal package to improve integration with other Open Specy functions. A typical good smooth can be achieved with 11 data point window and a 3rd or 4th order polynomial.
smooth_intens()
returns an OpenSpecy
object.
Win Cowger, Zacharias Steinmetz
Savitzky A, Golay MJ (1964). “Smoothing and Differentiation of Data by Simplified Least Squares Procedures.” Analytical Chemistry, 36(8), 1627–1639.
sgolay()
data("raman_hdpe")
smooth_intens(raman_hdpe)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.