MerQuR+Statistics Glossary

Statistics Glossary → Smoothing parameter (λ, span)

Smoothing parameter (λ, span)concept

The setting in curve-fitting methods that controls how flexible or smooth the curve is, that is, the balance between closeness to the data and smoothness.

In penalised splines and GAMs, λ is the multiplier of the penalty on the curve's wiggliness. At λ = 0 the curve follows the data almost exactly, noise included; as λ grows the curve becomes smoother, and for very large λ it approaches a linear function. In LOESS, the span is the share of observations used in each local fit; 0.75, for instance, means each point is fitted using its nearest 75% of the data. The seasonal and trend windows in STL decomposition play the same role: the wider the window, the less the seasonal pattern changes over the years and the smoother the trend.

This is a bias-variance trade-off. Too little smoothing leads to overfitting and makes noise look like real structure; too much smoothing wipes out real curvature. The parameter is usually chosen from the data by GCV or UBRE, REML, AICc or cross-validation; in GAMs, REML is generally more stable and less prone to overfitting. Inference based on a hand-picked value does not reflect the uncertainty of that choice, and tuning λ by looking at the shape of the curve risks steering the results in a desired direction.

An everyday example

A researcher examines the relationship between age and blood pressure with LOESS. With a span of 0.2 the curve rises and falls every few years, tracking chance fluctuations. With a span of 0.9, the increase that becomes clear after age 50 almost disappears. The span of 0.5 chosen by AICc shows both the general increase and its acceleration after 50.

In MerQur

The generalized additive model has 'λ (lambda) (fixed)' and 'Smoothing selection' (Fixed λ, Automatic GCV/UBRE, Automatic REML). In LOESS, 'Smoothing (span)' (default 0.75), 'Span selection' (Fixed, AICc, GCV) and 'Local polynomial degree', and in STL seasonal decomposition the 'Seasonal window' and 'Trend window', set this balance.

Analyses where this concept appears

Generalized Additive Model (GAM, Nonlinear Regression)STL Seasonal DecompositionLOESS (Local Regression)

Related concepts

Splines and basis dimension (k)Generalized cross-validation (GCV)