BASTION: A Bayesian Framework for Trend and Seasonality Decomposition
Jason B. Cho, David S. Matteson
TL;DR
BASTION tackles the challenge of robustly decomposing time series into trend and multiple seasonal components with principled uncertainty. It combines a penalized regression foundation for identifiability with a Bayesian framework using global–local shrinkage priors, explicit outlier modeling via horseshoe+ priors, and a stochastic-volatility extension for heteroskedastic residuals. The approach yields accurate decompositions and well-calibrated posterior uncertainty, performing favorably against TBATS, STR, and MSTL in simulations and real-world datasets such as airline traffic and electricity demand. Its practical impact lies in providing a flexible, interpretable tool for complex temporal dynamics, available as an R package for broad use.
Abstract
We introduce BASTION (Bayesian Adaptive Seasonality and Trend DecompositION), a flexible Bayesian framework for decomposing time series into trend and multiple seasonality components. We cast the decomposition as a penalized nonparametric regression and establish formal conditions under which the trend and seasonal components are uniquely identifiable, an issue only treated informally in the existing literature. BASTION offers three key advantages over existing decomposition methods: (1) accurate estimation of trend and seasonality amidst abrupt changes, (2) enhanced robustness against outliers and time-varying volatility, and (3) robust uncertainty quantification. We evaluate BASTION against established methods, including TBATS, STR, and MSTL, using both simulated and real-world datasets. By effectively capturing complex dynamics while accounting for irregular components such as outliers and heteroskedasticity, BASTION delivers a more nuanced and interpretable decomposition. To support further research and practical applications, BASTION is available as an R package at https://github.com/Jasoncho0914/BASTION
