17  a perfect smoother

Source: Eilers (2003)

GitHub repository

Noisy series \(y\) of length \(m\).

The smoothed series is called \(z\).

We have conflicting interests:

Roughness:

\[ R = \displaystyle\sum_i (z_i - z_{i-1})^2 \]

Fit to data:

\[ S = \displaystyle\sum_i (y_i - z_i)^2 \]

Cost functional to be minimized:

\[ Q = S + \lambda R \]