msc | R Documentation |
This function performs multiplicative scatter/signal correction (MSC) on an input data of spectra. It corrects for multiplicative and additive effects in the spectral data by regressing against a reference spectrum.
msc(
x,
xref = NULL,
drop.offset = TRUE,
robust = TRUE,
window = NULL,
drop.na = TRUE
)
x |
A numeric matrix or data frame containing the input spectra. Each row represents a sample, and each column represents a spectral variable. |
xref |
An optional numeric vector representing the reference spectrum.
If |
drop.offset |
A logical value indicating whether the offset should be
removed from the spectra (default is |
robust |
A logical value indicating whether the mean or median of |
window |
An optional list of numeric vectors specifying the indices of spectral windows. If provided, MSC is performed separately for each window. |
drop.na |
A logical value indicating whether to remove missing values
(NA) from the calculations. If |
A list with the following components:
correction |
The corrected spectra. |
offset |
The intercepts/offsets. |
slope |
The multiplicative scatter factors/slopes. |
Christian L. Goueguel
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.