Anda di halaman 1dari 6

Assignment 3

Qn: Following the exercise in the lab session on 6th April, pick a series of short term and long term interest rates and fit a VAR model to it. You must follow all steps discussed for testing variables, lag length, IRF and FEVD etc. -----------------------------------------------------------------------------------------------------------------------This assignment aims to fit a VAR to the following variables:
canrate3monthprimecorporatepaper: canyield10yearfederalgovernmentb: Step 1 short term interest rate (renamed st) long term interest rate (renamed lt)

As the date provided is a time series data, we initiate the assignment by the command tsset obs by telling Stata to identify this data type by time period (denoted by the variable obs). Step 2 Testing Variables for Order of stationarity We now test for the order of stationarity of the two variables sr and lr. To do this, we can either informally test the variables by investigating their correlograms or formally test them by the Philips Perron or Dicky Fuller test. I shall test for the order of stationarity by the Dicky Fuller Test 1. The results from the test show that both lt and st are non-stationery (p-value = 0.6837 and 0.832 > 0.05 respectively, => we d not reject H0 at 5% significance level). Hence they are have an order of integration higher than I(0). To determine their order of integration, we difference the two series and check their order of stationarity by the Durbin Watson Test till we reject H0. On first differencing both st and lt (lagged vars are named slt and dlt respectively) and applyinf Durbin Watson test for order of stationarity, we obtain p-values of 0.000 for both the variables. (As t-stat <0.05, we reject H0 at 5% significance level.). Conclusion: The

short run and long run interest rates are both I(1).

Note: We can proceed with the rest of the exercise by choosing either the differenced variables or the undifferenced variables. I choose to use the undifferenced variables for further procedure.

For Dicky Fuller Test: Ho : unit root (series is non-stationery) and H1 : not unit root (series is stationery)

Step 3 Optimal Lag Length We now determine the optimal number of lags to include in our VAR model by pre-estimation i.e, we shall provide the software with the variables to fit the VAR model on and check from amongst AIC/BIC/Likelihood ratio etc values that Stata returns to decide for the optimal lag length. Pre-estimation: The results obtained are as follows:

Selection-order criteria Sample: 6 - 120 lag 0 1 2 3 4 5 LL -289.212 74.7703 111.026 114.206 120.125 122.111 LR 727.96 72.511 6.3607 11.839* 3.9708 df 4 4 4 4 4 p 0.000 0.000 0.174 0.019 0.410 FPE .542698 .001037 .000592 .0006 .000581* .000602

Number of obs AIC 5.06455 -1.196 -1.75697 -1.74271 -1.77609* -1.74106 HQIC 5.08393 -1.13788 -1.66008* -1.60708 -1.6017 -1.52791

= SBIC

115

5.11229 -1.05279 -1.51828* -1.40855 -1.34645 -1.21594

Endogenous: lt st Exogenous: _cons


Pre-estimation detects two choices for optimal lag length (2 and 4). In case of a contradiction, we prefer SBIC and LR over all statistics, however there is a contradiction between the two stats (SBIC suggests 2 lags and LR suggests 4). Hence we go for the post-estimation technique. Post-estimation: In this technique, we estimate a VAR first with different no of lag lengths and then conclude (based on whether predicted residuals from each VAR model is white noise or not) as to what lag length is optimal. I model VAR with lags 2, 3, 4 and 5 in Stata and store estimates (estimates of the VAR models) from each VAR model as (A2, A3, A4 and A5). Now, I run post-estimation on these saved estimates. The results from the post-estimation do not solve the contradiction between lag lengths 2 and 4. Hence, I apply the Lagrange multiplier test to check whether the VAR model with lags 2 and 4 obtain residuals that white noise or not. This gives the following results:

For VAR (2 lags)


Lagrange-multiplier test lag 1 2 chi2 4.4808 7.0339 df 4 4 Prob > chi2 0.34482 0.13411

H0: no autocorrelation at lag order

For VAR (4 lags)


Lagrange-multiplier test lag 1 2 chi2 4.9999 1.6209 df 4 4 Prob > chi2 0.28731 0.80503

H0: no autocorrelation at lag order

Both tables show p-value > 0.05 at both lags 1 and 2 (for lags of residuals). Hence, we do not reject H0 and conclude that both models have white-noise residuals. Conclusion: As all techniques above have been unable to break the tie between optimal lag lengths 2 and 4, we choose the more parsimonious model that compromises the least on degrees of freedom.

Optimal lag length = 2


Step 4 Obtaining IRF (Impulse Response Function) The IRF tells what the time path effect on both variables is if a shock occurs today. We can obtain the IRF graphically or in tabular form: Graphical representation:

abc, lt, lt
3 2 1 0 -1

abc, lt, st

abc, st, lt
3 2 1 0 -1 0 2 4 6 8 0 2

abc, st, st

step 95% CI impulse response function (irf)

Graphs by irfname, impulse variable, and response variable

Abc lt, lt: impact of shock of lt on lt Abc lt, st: impact of shock of lt on st Abc st, lt: impact of shock of st on lt Abc st, st: impact of shock of st on st. Impulse response functions value declines over time, converging to some value. (As can be seen from the graph) and the series eventually converges to its long run mean value.

Tabular representation:

Results from varbasic abc (1) irf 1 1.04393 .978769 .922176 .879698 .845412 .815213 .787037 .759941 (1) Lower 1 .864491 .781806 .720929 .662434 .605518 .550043 .495843 .442921 (1) Upper 1 1.22337 1.17573 1.12342 1.09696 1.08531 1.08038 1.07823 1.07696 (2) irf 0 .118363 .169408 .170389 .146786 .11301 .075942 .038674 .002541 (2) Lower 0 -.03045 -.077567 -.133204 -.201571 -.281411 -.367895 -.456613 -.544649 (2) Upper 0 .267175 .416383 .473982 .495143 .50743 .519779 .533961 .549732 (3) irf 0 -.210611 -.319868 -.350369 -.340988 -.314037 -.280248 -.244481 -.208874 (3) Lower 0 -.387624 -.598834 -.671231 -.681463 -.671718 -.658673 -.647406 -.638745 (3) Upper 0 -.033597 -.040903 -.029507 -.000513 .043644 .098176 .158444 .220998

step 0 1 2 3 4 5 6 7 8

step 0 1 2 3 4 5 6 7 8

(4) irf 1 1.51635 1.74349 1.82899 1.84905 1.83925 1.81569 1.78555 1.75209

(4) Lower 1 1.36955 1.42766 1.38129 1.31145 1.23813 1.16188 1.08072 .994404

(4) Upper 1 1.66315 2.05931 2.27669 2.38664 2.44037 2.4695 2.49039 2.50977

(5) irf 1 1.04393 .978769 .922176 .879698 .845412 .815213 .787037 .759941

(5) Lower 1 .864491 .781806 .720929 .662434 .605518 .550043 .495843 .442921

(5) Upper 1 1.22337 1.17573 1.12342 1.09696 1.08531 1.08038 1.07823 1.07696

(6) irf 0 .118363 .169408 .170389 .146786 .11301 .075942 .038674 .002541

(6) Lower 0 -.03045 -.077567 -.133204 -.201571 -.281411 -.367895 -.456613 -.544649

(6) Upper 0 .267175 .416383 .473982 .495143 .50743 .519779 .533961 .549732

step 0 1 2 3 4 5 6 7 8 95% (1) (2) (3) (4) (5) (6) (7) (8) .

(7) irf 0 -.210611 -.319868 -.350369 -.340988 -.314037 -.280248 -.244481 -.208874

(7) Lower 0 -.387624 -.598834 -.671231 -.681463 -.671718 -.658673 -.647406 -.638745

(7) Upper 0 -.033597 -.040903 -.029507 -.000513 .043644 .098176 .158444 .220998

(8) irf 1 1.51635 1.74349 1.82899 1.84905 1.83925 1.81569 1.78555 1.75209 = = = = lt st lt st

(8) Lower 1 1.36955 1.42766 1.38129 1.31145 1.23813 1.16188 1.08072 .994404

(8) Upper 1 1.66315 2.05931 2.27669 2.38664 2.44037 2.4695 2.49039 2.50977

lower and irfname = irfname = irfname = irfname = irfname = irfname = irfname = irfname =

upper bounds reported varbasic, impulse = lt, and response varbasic, impulse = lt, and response varbasic, impulse = st, and response varbasic, impulse = st, and response abc, impulse = lt, and response = lt abc, impulse = lt, and response = st abc, impulse = st, and response = lt abc, impulse = st, and response = st

Theoretically, IRF is the matrix phi ( ) where: = +


i

Steps 0-8 signify that, starting from today, what is the value for each shock till the next 8 periods. (for eg, Table 1 shows phi11 (1), phi11 (2) . phi11 (8). Table 2 shows phi12 (1), phi12 (2) . phi12 (8) and so on phi11 (1) indicates that, if there is a shock to lt of 1 unit, its impact n lt in time period 1is 1.04393.

Obtaining FEVD (Factor Error Variance Decomposition FEVD indicates that, out of the total forecast variance, how much is there because of variance in error f var 1 and how much because of variance in error of var 2. (assuming that there are two variables under consideration.)