predict.specproc_slope_bias: Correct Predictions for Slope and Bias

View source: R/transfer.R

predict.specproc_slope_biasR Documentation

Correct Predictions for Slope and Bias

Description

Applies the correction fitted by slope_bias() to new predictions.

Usage

## S3 method for class 'specproc_slope_bias'
predict(object, newdata, ...)

Arguments

object

The result of slope_bias().

newdata

Predictions of the model for new secondary spectra.

...

Not used.

Value

The corrected predictions.

See Also

slope_bias()

Examples

set.seed(1)
reference <- runif(20, 0.5, 4)
predicted <- 0.2 + 1.1 * reference + rnorm(20, sd = 0.05)
predict(slope_bias(predicted, reference), c(1.3, 2.4, 3.5))

specProc documentation built on Nov. 20, 2026, 5:11 p.m.