See also:
Time Series Intervention Analysis with R and SAS
In previous posts I have discussed the
basics of time series analysis methods, provided an example of an
applied ARIMA model (using fertilizer application data), and discussed how
vector auto regressions can be used to accommodate a multivariate analysis of time series. What if you want to measure the impact of some shock or event (such as a change in government policy, the impact of a natural disaster, a negative news report etc. ) on a the behavior of a series of data? For instance, lets assume beef consumption was holding steady or even trending downward. Then at time ‘t’ someone of national prominence or importance makes false claims about beef safety. We notice a downward trend in beef consumption follows. How much of this decrease can be attributed to the headline making false claims, and how much is just the continued momentum of other factors. Or, assume that corn prices have been trending upward for some time and at some time ‘t’, the government increases renewable fuels mandates. It follows that we notice an increase in the trend of corn prices. How much of this can be attributed to the public policy vs. the momentum of other evolving factors?
Time series intervention analysis (ARIMA modeling with intervention) provides the framework for answering these types of questions. As explained in the introductory business forecasting text written by Newbold and Bos:
“ When a significant intervention has interrupted the stable behavior of a time series of interest, it is important to attempt to explicitly model its impact. Box and Tao(1975) introduced a procedure , known as intervention analysis, for this purpose. Essentially these authors proposed the use of the transfer function-noise class of models…but with Xt a dummy variable series defined to take the value zero up to the point in time that the intervention occurs, and the value one thereafter.”
As described by Nelson (2000) intervention analysis is
“an extension of the ARIMA methods introduced by Box and Tao (1975) and Jenkins(1976) to measure the effect of a policy change or event on the outcome of a variable...In summary, intervention models generalize the univariate Box-Jenkins methodology by allowing the time path of the dependent variable to be influenced by the time path of the intervention variables”
So it seems a time series intervention analysis can be a valuable tool for assessing the impact of some policy change or other intervention on the trend of some variable we are interested in. This however first requires an understanding of the transfer function-noise class of models described by Newbold and Bos.
Transfer Functions
ARIMA models are simply models of a single dependent variable (Y) as a function of past values of Y as well as past values of the error terms (e).
For example, ARIMA(2,1,1) : Y*t = b0 + b1Y*t-1 + b2Y*t-2 + b3 et-1 + et represents an ARIMA model with 2 autoregressive terms, 1 first difference, and 1 moving average term. But what if we want to include the impact of some other variable on Y, such as X. A basic regression model Y = B0 + B1X provides a static model for this relationship, but what if we want a model that captures this relationship between both the time path of X and Y. One way to look at the impact of the time path of X on Y would be to model:
Yt = V0 + V1Xt + V2Xt-1 + V3Xt-3 +…..et
This can more compactly, flexibly, and efficiently be represented and estimate as
Yt = α +w(B)/ δ(B) *Xt + et
where:
w(B) = wo + w1B +w2B +…wrBr
δ(B) = 1- δ1B -… -δs Bs
B = the backshift operator
Xt = the independent explanatory variable of interest
et =noise/error term
As pointed out by Newbold and Bos, this model often can fit many data series quite well with only a few polynomial terms, such as the very popular formulation below:
Yt = α +[wo/ 1- δ1B ]*Xt + et
Which is equivalent to:
Yt = α + woXt + wo δ1Xt-1 + woδ12 Xt-2 + woδ13 Xt-3 +…+ et
This model implies that a 1 unit increase in X during time t increases Y by wo units, increases Y by wo δ1 units in the next time period and by woδ12 units the following period with the impact of the change in X phasing out over time. The polynomial expression [wo/ 1- δ1B ]*Xt represents what’s referred to as a transfer function.
What about the time path of Y itself? We previously modeled this via an ARIMA process. Letting et be represented by the ARIMA process ( aka noise process Nt) as follows:
[θ(B) θ(Bs) / Φ(B) Φ(Bs) ΔdΔs ] * at where
B = backshift operator such that BY = Yt-1
θ(B) = MA(q)
θ(Bs) = seasonal MA(Q)
Φ(B) = AR(p)
Φ(Bs) = seasonal AR(P)
Δd= differencing
Δs = seasonal differencing
at = white noise term
which is just another way of representing the ARIMA(p,d,q)(P,D,Q) process where
P = # of seasonally differenced autoregressive terms
D = # of seasonal differences
Q = # of seasonally differenced moving average terms
The combined transfer function-noise model can be represented more compactly as:
Yt = C + w(B)/ δ(B) *Xt + Nt
Or even more compactly:
Yt = C + v(B)*Xt + Nt
This brings us back to the description of intervention analysis previously described by Bos and Newbold:
Essentially these authors proposed the use of the transfer function-noise class of models…but with Xt a dummy variable series defined to take the value zero up to the point in time that the intervention occurs, and the value one thereafter.”
That is, we use the noise-transfer model above, with the independent variable Xt being a dummy or indicator variable flagging the intervention at time ‘T’. If we let Xt be the intervention variable It, it can take two forms, depending on they impact of the intervention on the series of interest (Y):
Let It be a pulse function St such that:
Pt = 0 if t != T
1 if t = T
Pulse functions are typically employed if the effects are expected to be only temporary, and decay over time.
Let It be a step function St such that:
St = 0 if t < T
1 if t >= T
Step functions are typically employed if the effects of the intervention are expected to remain permanently after time T.
So a time series intervention model can be compactly expressed in two ways, as a pulse function:
Yt = C + v(B)*Pt + Nt
Or as a step function
Yt = C + v(B)*St + Nt
Min(2008) provides some interesting graphs illustrating these various specifications.
Pulse: [wB/ 1- δB ]Pt
The above specification illustrates an intervention with an abrupt temporary effect ‘w’ that gradually decay or ‘wears off’ at rate δ with a return back to original or pre-intervention levels.
Step: [wB/ 1- δB ]St
The above specification illustrates an intervention with a gradual permanent effect with an initial impact or level change of ‘w’ and rate of adjustment equal to δ and long run response level w/1- δB. To better illustrate the role of δ, note that if δ = 0 then we would have [wB ]St. There would be no adjustment process as illustrated below.
There are many other possible specifications depending on the behavior of the series we are interested in (Yt) and the impact of the intervention on the time path of Yt. As noted in Wei(1990) you can even specify a combination of step and pulse functions as follows:
[woB/ 1- δB ]Pt + w1St
It also follows that we could have both an input series Xt (as discussed previously in the context of transfer functions) and an intervention It specified as follows:
Yt = C + v(B)*It + w1BXt + Nt
Where It is either a step or pulse function.
References:
Consumer Bankruptcies and the Bankruptcy Reform Act: A Time-Series Intervention Analysis, 1960–1997. Jon P. Nelson. Journal of Financial Services Research
Volume 17, Number 2, Aug 2000. 181-200, DOI: 10.1023/A:1008166614928
Box, G. E. P. and G. C. Tiao. 1975. “Intervention Analysis with
Applications to Economic and Environmental Problems.” Journal of the American Statistical Association. 70:70-79
Introductory Business Forecasting. Newbold and Bos. 1990.
Jennifer C.H. Min, (2008) "Forecasting Japanese tourism demand in Taiwan using an intervention analysis", International Journal of Culture, Tourism and Hospitality Research, Vol. 2 Iss: 3, pp.197 – 216
Time Series Analysis: Univariate and Multivariate Methods. William W.S.Wei. 1990.