Fit a model

trendfilter()

Fit a trend filtering model (front-end function focused on ease of use)

.trendfilter()

Fit a trend filtering model (back-end function with more options for experts)

relax_trendfilter()

(Not yet available) Fit a "relaxed" trend filtering model by computing a weighted average of the standard trend filtering estimate and an (unpenalized) spline that shares the same knot set.


Optimize hyperparameter(s)


cv_trendfilter()

Optimize the trend filtering hyperparameter by V-fold cross validation

sure_trendfilter()

Optimize the trend filtering hyperparameter by minimizing Stein's unbiased risk estimate


Compute bootstrap ensembles & uncertainties


bootstrap_trendfilter(<trendfilter>)

Generate an ensemble of trend filtering estimates via a bootstrap

vbands(<bootstrap_trendfilter>)

Compute variablity bands from the sample quantiles of the bootstrap ensemble


Call generic stats functions

predict(<trendfilter>)

Evaluate a trend filtering estimator

fitted(<trendfilter>)

Compute the fitted values of a trend filtering estimate

residuals(<trendfilter>)

Compute the residuals of a trend filtering estimate

Data

data(eclipsing_binary)

Phase-folded light curve of an eclipsing binary star system

data(quasar_spectrum)

Lyman-α forest in the absorption spectrum of a distant quasar