Mixed Model Time Series Regression – TechToday

Using multiple model forms to capture and forecast the components of complex time series

Bradley Stephen Shaw
Towards Data Science
Photo by Hunter Haley on Unsplash

I recently had to fix the fence in my back yard. It’s old, wooden, and has been threatening to topple over for a while now. Between curses it really struck me how many tools I needed to use to get the job done, and how sometimes you really need more than one tool for the job.

What does this have to do with time series regression? In general, very little. In particular, quite a bit: today we’ll be diving into using mixed models for time series analysis and forecasting. Or in more DIY terms — using more model tools to get the forecasting job done.

So, without too much more rambling, we will get cracking with:

  1. Revisiting the big picture, and talking a bit about mixed models.
  2. Looking at some real-world data.
  3. Using a simple model to capture the trend in our time series.
  4. Seasonality three ways: decision trees, linear regression, and classic time series.
  5. Putting Humpty Dumpty back together to get a single time series prediction.

Aside: you’ll be pleased to know that my thumbs have made a full recovery following some hammer-related accidents.

As always, we’re trying to build the most “accurate” model possible. In this case, we’re focusing on forecasting so we’ll prioritise models which can produce the most accurate estimates of future time series values.

I’ve previously written at length about using a regression approach based on Meta’s Prophet methodology. In those articles, I explained why I chose to use the LASSO model: non-stationarity made using classic methods difficult, the need for sensible extrapolation ruled out tree-based approaches, and the desire for simplicity and explainability excluded any sort of neural network.

But I also hinted at using mixed model forms — that is, modelling each of the time series components using a different model form, and combining the output of the…

Source link

Source link