sablib
Loading...
Searching...
No Matches
arpls.h File Reference

Baseline estimation using asymmetrically reweighted Penalized Least Squares(arPLS). More...

#include <stdexcept>
#include "../smoothing/whittaker.h"

Go to the source code of this file.

Functions

const std::vector< double > sablib::BaselineArPLS (std::vector< double > &y, const double lambda, const unsigned int s=2, const unsigned int loop=50, const double eps=1e-3)
 Performs baseline estimation using asymmetrically reweighted Penalized Least Squares(arPLS).

Detailed Description

Baseline estimation using asymmetrically reweighted Penalized Least Squares(arPLS).

Author
Izadori

References:

  • Baek, S.-J.; Park, A.; Ahn, Y.-J.; Choo, J. Baseline Correction Using Asymmetrically Reweighted Penalized Least Squares Smoothing. Analyst 2015, 140(1), 250–257.

Definition in file arpls.h.

Function Documentation

◆ BaselineArPLS()

const std::vector< double > sablib::BaselineArPLS ( std::vector< double > & y,
const double lambda,
const unsigned int s = 2,
const unsigned int loop = 50,
const double eps = 1e-3 )

Performs baseline estimation using asymmetrically reweighted Penalized Least Squares(arPLS).

Parameters
yThe input data for baseline estimation.
lambdaSmoothing parameter.
sThe order of the difference (usually s = 1, 2, or 3).
loopMaximum number of iterations.
epsConvergence threshold.
Returns
The estimated baseline.
Exceptions
std::invalid_argumentOne or more parameters are wrong.

Definition at line 17 of file arpls.cpp.