You are on page 1of 24

# methods@manchester

Denise Osborn
Economics

## What Is Time Series Analysis?

A time series is a set of data observed over time Examples: o Stock market returns each trading day over the last month o Monthly rainfall in Manchester o Number of recorded property crimes each year for the last 50 years o Weekly online sales by Amazon since 2005

## What is Time Series Analysis? Denise Osborn, Methods@Manchester, 11 November 2010

Time series analysis: statistical models to represent characteristics of time series data Why??? May want/need to: Understand changing world temperature patterns Predict river flows Forecast future stock market returns Evaluate effects of macroeconomic policy change

## o Accuracy estimates (probabilities for ranges), as well as forecast values

What is Time Series Analysis? Denise Osborn, Methods@Manchester, 11 November 2010 4

Time Series Patterns Temporal patterns sometimes divided into: o Trend (or change in level) o Seasonality (over the year) o Cycles (eg, recession/expansion in the economy) Useful way to think about features to be represented

## Inflation Again Monthly UK consumer price index inflation, since 1993:

15.0 10.0 5.0 0.0 -5.0 -10.0 -15.0

o Main characteristic is seasonality: January & July price declines, April peaks

## What is Time Series Analysis? Denise Osborn, Methods@Manchester, 11 November 2010

19 93 J 19 an 94 J 19 an 95 J 19 an 96 J 19 an 97 J 19 an 98 J 19 an 99 J 20 an 00 J 20 an 01 J 20 an 02 J 20 an 03 J 20 an 04 J 20 an 05 J 20 an 06 J 20 an 07 J 20 an 08 J 20 an 09 J 20 an 10 Ja n

Exploring Time Series Patterns Can use visual or statistical approaches - Better: use both! Graphs are invaluable Summary statistics: autocorrelations

## What is Time Series Analysis? Denise Osborn, Methods@Manchester, 11 November 2010

Autocorrelations Correlations provide important information on strength of relationships: in time series, use autocorrelations Say we have observations on a variable over time:

y1, y2, , yT
o Eg, inflation each month, January 1988 to October 2010

## Sample Autocorrelations of UK Monthly Inflation

0.8 0.6 0.4 0.2 0 -0.2 -0.4 0 3 6 9 12 15 18 21 24 27 30 33 36

Autocorrelation at k = 12 (one year lag) very strong (0.71); only marginally lower at 2 & 3 year lags o Also 6, 18, 30-month autocorrelations 0.4 Confirms importance of seasonality for monthly CPI inflation
What is Time Series Analysis? Denise Osborn, Methods@Manchester, 11 November 2010 9

Output Growth: Another Example o Real output growth is a key measure for the economy o Available quarterly, seasonally adjusted
Quarterly Real UK Output Growth 1960-2010
4 2 0 -2 -4
19 60 Q 1 19 63 Q 1 19 66 Q 1 19 69 Q 1 19 72 Q 1 19 75 Q 1 19 78 Q 1 19 81 Q 1 19 84 Q 1 19 87 Q 1 19 90 Q 1 19 93 Q 1 19 96 Q 1 19 99 Q 1 20 02 Q 1 20 05 Q 1 20 08 Q 1

## o Principal time series characteristics?

What is Time Series Analysis? Denise Osborn, Methods@Manchester, 11 November 2010 10

## Autocorrelations from 1960 to 2010:

Sample Autocorrelations of Growth 1960-2010
0.2

0.1

-0.1

-0.2 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20

Relatively low! Growth each quarter close to random o But some evidence of positive relationship with preceding 3 quarters
What is Time Series Analysis? Denise Osborn, Methods@Manchester, 11 November 2010 11

## Autocorrelations from 1985 to 2010:

Sample Autocorrelations of Growth 1985-2010
0.8 0.6 0.4 0.2 0 -0.2 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20

Much stronger autocorrelations since 1985! Each quarter strongly related to following one o Suggests possibility of forecasting future growth

## What is Time Series Analysis? Denise Osborn, Methods@Manchester, 11 November 2010

12

Time Series Models Graphical and autocorrelation analyses are only preliminary steps for time series modelling o Statistical models used for formal analysis and forecasting Simplest time series model has form: o yt = + yt-1 + ut

ut random

## o A regression of yt on its own past: an autoregression of order 1 (ie, 1 lag)

What is Time Series Analysis? Denise Osborn, Methods@Manchester, 11 November 2010 13

Models for Output Growth Constant 1960-1984 1985-2010 0.501 (3.87) 0.192 (2.94) AR(1) coefficient 0.009 (0.08) 0.664 (8.86) R2 0.00007 0.440 Residual St.Dev. 1.18 0.50

(t-ratios in parentheses) AR(1) explains nothing before 1985; but highly significant after 1985

## What is Time Series Analysis? Denise Osborn, Methods@Manchester, 11 November 2010

14

Point Forecasts Time series models are important in forecasting For growth example o Estimated AR(1), 1985Q1-2010Q2:

## yt = 0.192 + 0.664 yt-1 + residual

o Using this to forecast:

and so on

## What is Time Series Analysis? Denise Osborn, Methods@Manchester, 11 November 2010

15

How well would AR(1) have forecast recent past? o Assume growth to 2008Q4 known; forecast 2009 & 2010: Forecast 2009Q1 2009Q2 2009Q3 2009Q4 -1.20 -0.58 -0.18 0.08 Actual -2.12 -0.82 -0.21 0.51 2010Q1 2010Q2 2010Q3 2010Q4 Forecast 0.25 0.36 0.43 0.47 Actual 0.31 1.22

## What is Time Series Analysis? Denise Osborn, Methods@Manchester, 11 November 2010

16

Repeating exercise for 2008 & 2009 (data to 2007Q4): Forecast 2008Q1 2008Q2 2008Q3 2008Q4 0.50 0.59 0.64 0.65 Actual 0.48 -0.29 -1.16 -2.17 2009Q1 2009Q2 2009Q3 2009Q4 Forecast 0.66 0.67 0.67 0.67 Actual -2.12 -0.82 -0.21 0.51

Would NOT have forecast onset of recession! Simple linear models, such as AR(1), are useful, but have limitations in forecasting

## What is Time Series Analysis? Denise Osborn, Methods@Manchester, 11 November 2010

17

Model Specification Much of time series analysis concerns methods to specify the appropriate model form o A (univariate) time series model has form

ut random

f(yt-1, yt-2, )

18

## yt = + 1 yt-1 + 2 yt-2 + + p yt-p + ut

Higher p may help to capture seasonality and cycles; But need to decide appropriate p LARGE TOPIC: But can use hypothesis tests or other data-based procedure o In yt = f(yt-1, yt-2, ) + ut f can be nonlinear but difficult in practice o Also diagnostic tests available to check that model residuals are random over time
What is Time Series Analysis? Denise Osborn, Methods@Manchester, 11 November 2010 19

Multivariate Time Series Modelling single time series in isolation not always very useful o Including in Economics o Or any (other) context where relationships between variables are important

20

## yt = 1 + 11 yt-1 + 12 xt-1 + u1t xt = 2 + 21 yt-1 + 22 xt-1 + u2t

o Represents dynamic interactions o Similarly more variables and longer lags o Model specification is again key consideration o Known as a VAR (vector autoregressive) model

## What is Time Series Analysis? Denise Osborn, Methods@Manchester, 11 November 2010

21

Example: US and Euro Area US/Euro area interest rate interactions (from a 7-variable VAR analysis of the relationships between these economies):

## (i)r_US s hoc k onr_E A

0.3 0.2 0.1 0 -0.1 1 9 17 25 33 41 49 57

## (i)r_E As hoc konr_US

0.06 0.03 0 -0.03 -0.06 -0.09 1 9 17 25 33 41 49 57

## What is Time Series Analysis? Denise Osborn, Methods@Manchester, 11 November 2010

22

Here illustrate the strong effect of US policy on interest rates in the Euro Area; o But little in opposite direction Such VAR models are widely used in economic policy analyses o Especially in central banks (including Bank of England)

## What is Time Series Analysis? Denise Osborn, Methods@Manchester, 11 November 2010

23

Concluding Remarks Time series analysis focuses on capturing patterns over time Intuition fairly straightforward o But implementation can be difficult o And theory of time series analysis is complex! Techniques have a wide variety of applications o Some illustrated today for Economics

24