There are many types of models available to us:
A range of choices from mechanistic to purely statistical.
Bayesian, frequentist, machine learning.
Stochastic vs. Deterministic
How should we decide which model(s) to incorporate for nowcasting and forecasting?
What outputs and features do we require of these models?
Often, what motivates one’s modeling choices are the trends and patterns observed in the data.
Autocorrelation and Partial Autocorrelation (ACF/PACF) plots measure the linear relationship between lagged values of a time series.
ACF plots correlation of \(y_t\) and \(y_{t-k}\) as a function of k.
Correlations show periodicity of ~52 weeks.
PACF plots correlation of \(y_t\) and \(y_{t-k}\) as a function of k, adjusted for shorter lags.
Only a few partial correlations are significant.
Definition
A time series is stationary if the mean and variance of the data do not change over time.
Implications in practice
Stationarity means that there are no long-term predictable patterns in a time-series, but there can still be predictability in the short term.
Assumption
ARIMA (and other models) assume data are stationary (won’t work as well if data are not).
Seasonal patterns are common with many (but not all) endemic diseases. Seasonality can make a disease more predictable, but also means it’s not stationary.
A key assumption of many models is constant variance over time. Transformations often help.
Widely used for decades!
Notation is \(ARIMA(p, d, q).\)
Figuring out which \((p,d,q)\) to use is tricky!
Here is the equation for an ARIMA(1,0,0) model: \[ y_t = \mu_t + \phi_1 y_{t-1} + \varepsilon_t \]
Warning
Note the constant variance assumption!
Here is the equation for an ARIMA(0,1,0) model: \[y_t - y_{t-1} = \varepsilon_t \qquad\Longleftrightarrow\qquad y_t = y_{t-1} + \varepsilon_t\]
Tip
No AR terms (\(p=0\)), one difference (\(d=1\)), no MA terms (\(q=0\)). The model sees the first differences as white noise.
Here is an equation for an ARIMA(1,1,0) model: \[ y_t - y_{t-1} = \phi_1 (y_{t-1} - y_{t-2}) + \varepsilon_t.\]
Note
This model is the same as the last slide but here both the “outcome” variable and predictor variable is now a first-order difference of \(y_t\), corresponding to the second “1” in (1,1,0).
Time Series Forecasting 101