A suite of tools for denoising and analyzing one-dimensional signals with trend filtering. Trend filtering constructs a piecewise polynomial estimate for the signal with knots chosen adaptively from the observed data. Hyperpameter(s) can be optimized by cross validation (with any loss function) or by minimizing Stein's unbiased risk estimate. Methods are also included for trend filtering uncertainty quantification and a generalized "relaxed trend filtering" estimator.

Installation

install.packages("remotes")
remotes::install_github("capolitsch/trendfiltering")

Usage terms

When using the trendfiltering package, please use the following citations in your publications:

  1. Politsch et al. (2020a). Trend filtering – I. A modern statistical tool for time-domain astronomy and astronomical spectroscopy. Monthly Notices of the Royal Astronomical Society, 492(3), p. 4005-4018. [Publisher] [arXiv] [BibTeX]

  2. Politsch et al. (2020b). Trend Filtering – II. Denoising astronomical signals with varying degrees of smoothness. Monthly Notices of the Royal Astronomical Society, 492(3), p. 4019-4032. [Publisher] [arXiv] [BibTeX]