Econ 240 C Lecture 4.

Slides:



Advertisements
Similar presentations
Autocorrelation Functions and ARIMA Modelling
Advertisements

Dates for term tests Friday, February 07 Friday, March 07
Unit Roots & Forecasting
Time Series Building 1. Model Identification
STAT 497 APPLIED TIME SERIES ANALYSIS
1 ECON 240C Lecture Outline Box-Jenkins Passengers Box-Jenkins Passengers Displaying the Forecast Displaying the Forecast Recoloring Recoloring.
1 Econ 240 C Lecture 3. 2 Part I Modeling Economic Time Series.
1 Econ 240 C Lecture White noise inputoutput 1/(1 – z) White noise input output Random walkSynthesis 1/(1 – bz) White noise input output.
1 Econ 240 C Lecture Time Series Concepts Analysis and Synthesis.
Econ 240C Lecture Review 2002 Final Ideas that are transcending p. 15 Economic Models of Time Series Symbolic Summary.
1 Midterm Review. 2 Outline The Triangle of Stability - Power 7 The Triangle of Stability - Power 7 Augmented Dickey-Fuller Tests – Power 10 Augmented.
1 Power 2 Econ 240C. 2 Lab 1 Retrospective Exercise: –GDP_CAN = a +b*GDP_CAN(-1) + e –GDP_FRA = a +b*GDP_FRA(-1) + e.
1 Econ 240 C Lecture 6. 2 Part I: Box-Jenkins Magic ARMA models of time series all built from one source, white noise ARMA models of time series all built.
1 Identifying ARIMA Models What you need to know.
1 Econ 240C Lecture Five Outline w Box-Jenkins Models w Time Series Components Model w Autoregressive of order one.
1 Econ 240 C Lecture 3. 2 Time Series Concepts Analysis and Synthesis.
1 Econ 240C Power Outline The Law of One Price.
1 Econ 240C Lecture Five. 2 Outline w Box-Jenkins Models: the grand design w What do you need to learn? w Preview of partial autocorrelation function.
1 ECON 240C Lecture 8. 2 Outline: 2 nd Order AR Roots of the quadratic Roots of the quadratic Example: capumfg Example: capumfg Polar form Polar form.
1 ECON 240C Lecture 8. 2 Part I. Economic Forecast Project Santa Barbara County Seminar –April 17, 2003 URL:
Econ 240C Lecture Part I. VAR Does the Federal Funds Rate Affect Capacity Utilization?
1 ECON 240C Lecture 8. 2 Outline: 2 nd Order AR Roots of the quadratic Roots of the quadratic Example: change in housing starts Example: change in housing.
ARIMA Forecasting Lecture 7 and 8 - March 14-16, 2011
1 Econ 240C Lecture Five Outline w Box-Jenkins Models w Time Series Components Model w Autoregressive of order one.
1 ECON 240C Lecture 8. 2 Part I. Economic Forecast Project Santa Barbara County Seminar Santa Barbara County Seminar  April 22, 2004 (April 17, 2003)
1 Econ 240C Power Outline The Law of One Price Moving averages as a smoothing technique: Power 11_06: slides Intervention models: Power 13_06:
1 ECON 240C Lecture 8. 2 Outline: 2 nd Order AR Roots of the quadratic Roots of the quadratic Example: change in housing starts Example: change in housing.
ARMA models Gloria González-Rivera University of California, Riverside
STAT 497 LECTURE NOTES 2.
Linear Stationary Processes. ARMA models. This lecture introduces the basic linear models for stationary processes. Considering only stationary processes.
TIME SERIES ANALYSIS Time Domain Models: Red Noise; AR and ARMA models LECTURE 7 Supplementary Readings: Wilks, chapters 8.
Byron Gangnes Econ 427 lecture 11 slides Moving Average Models.
Byron Gangnes Econ 427 lecture 12 slides MA (part 2) and Autoregressive Models.
Data analyses 2008 Lecture Last Lecture Basic statistics Testing Linear regression parameters Skill.
Week 21 Stochastic Process - Introduction Stochastic processes are processes that proceed randomly in time. Rather than consider fixed random variables.
K. Ensor, STAT Spring 2004 Memory characterization of a process How would the ACF behave for a process with no memory? What is a short memory series?
Time Series Basics Fin250f: Lecture 8.1 Spring 2010 Reading: Brooks, chapter
MULTIVARIATE TIME SERIES & FORECASTING 1. 2 : autocovariance function of the individual time series.
Time Series Analysis Lecture 11
Dynamic Models, Autocorrelation and Forecasting ECON 6002 Econometrics Memorial University of Newfoundland Adapted from Vera Tabakova’s notes.
Review and Summary Box-Jenkins models Stationary Time series AR(p), MA(q), ARMA(p,q)
Previously Definition of a stationary process (A) Constant mean (B) Constant variance (C) Constant covariance White Noise Process:Example of Stationary.
Computational Finance II: Time Series K.Ensor. What is a time series? Anything observed sequentially (by time?) Returns, volatility, interest rates, exchange.
Components of Time Series Su, Chapter 2, section II.
1 Econ 240C Lecture Five. 2 Part I: Time Series Components Model w The conceptual framework for inertial (mechanical) time series models: w Time series.
Introduction to stochastic processes
1 Lecture Plan : Statistical trading models for energy futures.: Stochastic Processes and Market Efficiency Trading Models Long/Short one.
EC 827 Module 2 Forecasting a Single Variable from its own History.
Analysis of Financial Data Spring 2012 Lecture 4: Time Series Models - 1 Priyantha Wijayatunga Department of Statistics, Umeå University
Stochastic Process - Introduction
Covariance, stationarity & some useful operators
Financial Econometrics Lecture Notes 2
Time Series Analysis and Its Applications
Ch8 Time Series Modeling
Model Building For ARIMA time series
Econ 240C Lecture 18.
ECON 240C Lecture 7.
Stochastic models - time series.
Chapter 6: Forecasting/Prediction
Box-Jenkins models Stationary Time series AR(p), MA(q), ARMA(p,q)
Machine Learning Week 4.
Stochastic models - time series.
Chapter 9 Model Building
Module 3 Forecasting a Single Variable from its own History, continued
Unit Root & Augmented Dickey-Fuller (ADF) Test
Introduction to Time Series
The Spectral Representation of Stationary Time Series
Why does the autocorrelation matter when making inferences?
CH2 Time series.
BOX JENKINS (ARIMA) METHODOLOGY
Presentation transcript:

Econ 240 C Lecture 4

Outline Part I: Time Averages Part II: Autocovariance Function Part III: Random Walk Part IV: Deciding Between a Random Walk Or an ARONE?

Practicum: Lab Two Natural Logarithm of the Rotterdam Import Price for Dark Northern Spring Wheat Trace Histogram Autocorrelation function

Practicum: Lab Two First difference of Natural Logarithm of the Rotterdam Import price for Dark Northern Spring Wheat Trace Histogram Autocorrelation function

Part I Stationarity and Time Averages

Many Observations of White Noise Using simulation, we can create many different white noise time series of arbitrary length, say 1000 Using these time series we could average them at each point in time to obtain an average of the group or ensemble at that time, creating the mean function, m(t) = E wn(t).

Time Averages In economics, as a practical matter, we usually only have one observation of a time series In this case it is necessary to be able to average over time If the time series is stationary, then averaging over time makes sense

Five Simulated White Noise Time Series WN WN2 WN3 WN4 WN5 1.617983 0.837389 0.263717 1.498148 -0.017667 -0.981121 -0.037318 0.118295 0.073137 -0.468611 -0.644877 -0.177607 0.235936 0.504890 1.184326 1.548977 -0.372428 -0.483331 -0.285102 -0.569788 -0.800501 0.259279 0.020538 -0.674818 0.042432 0.111573 -0.442504 0.942710 0.625115 -1.546601 0.579694 0.371160 0.405358 -1.996286 -0.947028 -0.205539 -0.110242 -0.388757 0.615279 0.589821 -0.209470 -0.197190 0.178364 0.828461 -0.792716 0.034237 0.199730 0.339069 0.430797 0.912555

Trace of Five Simulated White Noise Time Series

Ensemble Average

Appeal to Central Limit Theorem If I had generated 100 or 1000 simulated white noise time series, then the ensemble average would come close to zero for every time period. Mean Function, m(t) =E X(t)

Ensemble Average

Ensemble Averages Are a Luxury Good in Economics Need to consider time average Think of the time average for the first white noise time series

Time Average

Trace of Time Average

Mean Function For a Time Average m = E WN(t) = c = 0

Time Average Will Not Work Well for an Evolutionary Time Series

Mean Function For An Evolutionary Time Series M(t) = E x(t) is not independent of time

Part II Autocovariance Function E{ [x(t) - Ex(t)][x(t-u) - Ex(t)]} = = gx,x(t,u) If a time series is covariance stationary, then gx,x(t,u) = gx,x(u) i.e. depends only on lag. Only relative time not absolute time counts.

Autocovariance of White Noise At Lag Zero Autocovariance Function E{ [wn(t) - Ewn(t)][wn(t-0) - Ewn(t)]} E{ [wn(t) - m(t)][wn(t) - m(t)]} E{ [wn(t) - 0][wn(t) - 0]} E{wn(t)*wn(t)}

Autocovariance of White Noise At Lag Zero

Variance For Entire Series

Autocovariance of White Noise at Lag 1 = ? Autocovariance Function E{ wn(t)*wn(t-1) } = gx,x(u=1) = ?

Average Cross Product For WN Series for 999

Autocovariance of White Noise at Lag 1 = ? gx,x(u=1) = 0 Since white noise is independent as well as identically distributed

Autocovariance of White Noise at Lag 2 = ? gx,x(u=2) = 0 Since white noise is independent as well as identically distributed

Theoretical Autocovariance, WN

Autocovariance, WN Theoretical Vs. Simulated

Autocorrelation Function The Autocorrelation function is just a standardized autocovariance function, i.e. just the autocovariance function divided by the variance rx,x (u) = gx,x(u) / gx,x(0)

Simulated Autocorrelation Function, WN WN Simulated Sample: 1 1000 Included observations: 1000 Autocorrelation Partial Correlation AC PAC Q-Stat Prob .| | .| | 1 -0.004 -0.004 0.0163 0.899 .| | .| | 2 0.042 0.042 1.7669 0.413 *| | *| | 3 -0.059 -0.058 5.2307 0.156 .| | .| | 4 0.007 0.005 5.2772 0.260 .| | .| | 5 0.012 0.017 5.4252 0.366 .| | .| | 6 0.051 0.047 8.0109 0.237 .| | .| | 7 0.018 0.018 8.3524 0.303 .| | .| | 8 0.021 0.019 8.8068 0.359 .| | .| | 9 -0.038 -0.035 10.300 0.327 .| | .| | 10 0.039 0.039 11.812 0.298

Part III Random Walk as an evolutionary process RW(t) = RW(t-1) + WN(t) lag by one RW(t-1) = RW(t-2) +WN(t-1) Substitute for RW(t-1) RW(t) = RW(t-2) + WN(t) + WN(t-1)

Random Walk Lag again to obtain RW(t-2) = RW(t-3) + WN(t-2) and Substitute for RW(t-2) RW(t) = RW(t-3) + WN(t) + WN(t-1) + WN(t-2) etc. so RW(t) = current shock plus all past shocks with past shocks weighted equally to the current shock so a random walk has infinite memory

Random Walk RW(t) -RW(t-1) = WN(t) Z0 RW(t) - Z RW(t) = WN(t) RW(t) = 1/[1-Z] * WN(t) RW(t) = [1 + Z + Z2 + …] WN(t) RW(t) = WN(t) + Z WN(t) + Z2 WN(t) + .. RW(t) = WN(t) + WN(t-1) + WN(t-2) + ...

Random Walk, Synthesis from White Noise RW(t) 1/[1-Z] WN(t) RW(t) 1 + Z + Z2 + ... WN(t)

Autocovariance of RW in Theory gRW,RW(u) = E{RW(t) - ERW(t)][RW(t-u)- ERW(t) ERW(t) = E[WN(t) + WN(t-1) +…] = 0 gRW,RW(u=0) = E[RW(t)*RW(t)] gRW,RW(0) = E[WN(t) + WN(t-1) + WN(t-2) + ..]* [WN(t) + WN(t-1) + WN(t-2) + ..] gRW,RW(0) = [s2 + s2 + s2 + ….] =

Autocovariance of RW in Practice, Length 100 gRW,RW(u=1) = E[RW(t)*RW(t-1)] gRW,RW(1) = E[WN(t) + WN(t-1) + WN(t-2) + ..]* [WN(t-1) + WN(t-2) + WN(t-3) + ..] gRW,RW(1) = [s2 + s2 + s2 + ….] = 99 s2 rRW,,RW (1) = gRW,,RW(1) / gRW,,RW(0) rRW,,RW (1) = 99/100

Simulated Autocorrelation, RW Simulated Random Walk Sample: 1 100 Included observations: 100 Autocorrelation Partial Correlation AC PAC Q-Stat Prob . |*******| . |*******| 1 0.940 0.940 91.068 0.000 . |*******| . | . | 2 0.883 -0.005 172.28 0.000 . |****** | . | . | 3 0.823 -0.055 243.59 0.000 . |****** | .*| . | 4 0.757 -0.093 304.44 0.000 . |***** | .*| . | 5 0.677 -0.154 353.66 0.000 . |***** | . | . | 6 0.609 0.052 393.94 0.000 . |**** | . | . | 7 0.543 -0.010 426.34 0.000 . |**** | .*| . | 8 0.475 -0.061 451.31 0.000 . |*** | . | . | 9 0.412 0.012 470.37 0.000 . |*** | . | . | 10 0.353 -0.038 484.52 0.000

Part IV: Random Walk Vs. ARONE X(t) = b*x(t-1) + wn How close to 1 is b?

Exchange Rate $/Euro

Exchange Rate $/Euro

Exchange Rate, $ Per Euro Sample: 1999:01 2003:03 Included observations: 51 Autocorrelation Partial Correlation AC PAC Q-Stat Prob . |*******| . |*******| 1 0.879 0.879 41.738 0.000 . |****** | .*| . | 2 0.750 -0.098 72.753 0.000 . |***** | . | . | 3 0.639 0.007 95.750 0.000 . |**** | . |*. | 4 0.560 0.067 113.78 0.000 . |**** | . | . | 5 0.504 0.046 128.71 0.000 . |**** | . | . | 6 0.467 0.055 141.83 0.000 . |*** | .*| . | 7 0.418 -0.068 152.54 0.000 . |*** | .*| . | 8 0.338 -0.137 159.71 0.000 . |** | .*| . | 9 0.236 -0.127 163.29 0.000 . |*. | .*| . | 10 0.116 -0.168 164.18 0.000 . | . | . | . | 11 0.021 -0.016 164.21 0.000 . | . | . | . | 12 -0.050 -0.036 164.38 0.000 .*| . | . | . | 13 -0.106 -0.052 165.18 0.000 .*| . | . | . | 14 -0.134 0.064 166.49 0.000 .*| . | . | . | 15 -0.163 -0.023 168.49 0.000 **| . | . | . | 16 -0.192 0.023 171.33 0.000 **| . | . |*. | 17 -0.204 0.094 174.64 0.000 **| . | **| . | 18 -0.269 -0.274 180.57 0.000 ***| . | .*| . | 19 -0.346 -0.122 190.70 0.000 ***| . | . | . | 20 -0.398 -0.029 204.50 0.000 ***| . | . |*. | 21 -0.397 0.079 218.67 0.000 ***| . | . |*. | 22 -0.362 0.086 230.87 0.000 ***| . | . | . | 23 -0.322 -0.037 240.89 0.000 **| . | .*| . | 24 -0.318 -0.133 250.99 0.000

Hong Kong $ Per US $

Hong Kong $ Per US $ Hong Kong $ Per US $ Sample: 1981:01 2003:03 Included observations: 267 Autocorrelation Partial Correlation AC PAC Q-Stat Prob .|*******| .|*******| 1 0.961 0.961 249.52 0.000 .|*******| .|. | 2 0.921 -0.034 479.67 0.000 .|*******| .|. | 3 0.883 -0.008 691.62 0.000 .|*******| .|. | 4 0.844 -0.012 886.38 0.000 .|****** | .|. | 5 0.806 -0.025 1064.5 0.000 .|****** | .|. | 6 0.769 -0.002 1227.2 0.000 .|****** | .|. | 7 0.736 0.028 1376.7 0.000 .|***** | .|. | 8 0.707 0.042 1515.4 0.000 .|***** | .|. | 9 0.679 -0.009 1643.8 0.000 .|***** | .|. | 10 0.651 -0.019 1762.2 0.000 .|***** | *|. | 11 0.612 -0.158 1867.2 0.000 .|**** | *|. | 12 0.570 -0.065 1958.6 0.000

Correlogram of Ratio of inventory To sales

Autocorrelation of Residuals from an ARONE model of Ratio of Inventory To Sales

First Difference of Ratio Dratinvsale=ratinvsale-ratinvsale(-1)

Correlogram of dratinvsale

Correlogram of Residuals from ARONE model of First difference of The ratio of Inventory to sales

First order autoregressive Arone(t) = b*Arone(t-1) + wn(t) Root of the deterministic diference equation: arone(t) –b*arone(t-1) = 0 Let x1-u = arone(t-u) x – bx0 = 0, x =b =root

Is b = 1? Regression: arone(t) = b* arone(t-1) + wn (t) , H0 : b=1 Equivalently, subtract arone(t-1) from both sides (1-z)arone(t) = (b-1)*arone(t-1) + wn(t), H0 : (b-1) = 0, i.e. b=1

The fly in the ointment As b approaches 1, the estimated parameter no longer has Student’s t-distribution Dickey and Fuller use simulation to derive the appropriate distribution

Ratio of inventory to Sales example of the Dickey-Fuller test