-----------------------------------------------------------------------------------------------------------------------------
      name:  <unnamed>
       log:  /Users/baum/Documents/EC327S2010/327var.smcl
  log type:  smcl
 opened on:  10 Mar 2010, 11:32:44


. * 327 VAR . webuse lutkepohl,clear (Quarterly SA West German macro data, Bil DM, from Lutkepohl 1993 Table E.1)

. * estimate a simple 3-variable VAR . var dlinvestment dlincome dlconsumption if tin(,1978q4), lags(1/4)

Vector autoregression

Sample: 1961q2 - 1978q4 No. of obs = 71 Log likelihood = 598.4567 AIC = -15.75934 FPE = 2.91e-11 HQIC = -15.26509 Det(Sigma_ml) = 9.58e-12 SBIC = -14.51646

Equation Parms RMSE R-sq chi2 P>chi2 ---------------------------------------------------------------- dlinvestment 13 .045566 0.2231 20.39339 0.0600 dlincome 13 .012288 0.1312 10.72076 0.5530 dlconsumption 13 .009678 0.2942 29.59871 0.0032 ----------------------------------------------------------------

------------------------------------------------------------------------------ | Coef. Std. Err. z P>|z| [95% Conf. Interval] -------------+---------------------------------------------------------------- dlinvestment | dlinvestment | L1. | -.3097261 .1166643 -2.65 0.008 -.5383839 -.0810683 L2. | -.064884 .1244374 -0.52 0.602 -.3087768 .1790089 L3. | .1773046 .1256907 1.41 0.158 -.0690446 .4236538 L4. | .3308462 .1178554 2.81 0.005 .0998538 .5618385 | dlincome | L1. | .2092642 .5274412 0.40 0.692 -.8245016 1.24303 L2. | -.191566 .5576397 -0.34 0.731 -1.28452 .9013877 L3. | -.0507337 .5725192 -0.09 0.929 -1.172851 1.071383 L4. | -.2815694 .5372021 -0.52 0.600 -1.334466 .7713274 | dlconsumpt~n | L1. | .7420024 .6963473 1.07 0.287 -.6228133 2.106818 L2. | .7656762 .7693356 1.00 0.320 -.7421939 2.273546 L3. | -.3019971 .6951872 -0.43 0.664 -1.664539 1.060545 L4. | -.6559089 .6142497 -1.07 0.286 -1.859816 .5479984 | _cons | .0105584 .020222 0.52 0.602 -.0290759 .0501927 -------------+---------------------------------------------------------------- dlincome | dlinvestment | L1. | .0474452 .0314626 1.51 0.132 -.0142203 .1091107 L2. | .0492337 .0335588 1.47 0.142 -.0165405 .1150078 L3. | .0130569 .0338968 0.39 0.700 -.0533797 .0794935 L4. | .0015181 .0317838 0.05 0.962 -.060777 .0638131 | dlincome | L1. | -.0920232 .1422427 -0.65 0.518 -.3708139 .1867674 L2. | .0521895 .1503868 0.35 0.729 -.2425632 .3469422 L3. | .178493 .1543996 1.16 0.248 -.1241246 .4811106 L4. | -.0222867 .1448751 -0.15 0.878 -.3062367 .2616633 | dlconsumpt~n | L1. | .1547785 .1877941 0.82 0.410 -.2132911 .5228482 L2. | -.0927122 .2074779 -0.45 0.655 -.4993615 .313937 L3. | -.0302094 .1874812 -0.16 0.872 -.3976659 .337247 L4. | -.0212085 .1656537 -0.13 0.898 -.3458837 .3034667 | _cons | .0156082 .0054536 2.86 0.004 .0049194 .026297 -------------+---------------------------------------------------------------- dlconsumpt~n | dlinvestment | L1. | -.0027659 .0247788 -0.11 0.911 -.0513315 .0457997 L2. | .031397 .0264298 1.19 0.235 -.0204045 .0831984 L3. | .010819 .026696 0.41 0.685 -.0415041 .0631421 L4. | -.0184341 .0250318 -0.74 0.461 -.0674955 .0306274 | dlincome | L1. | .2237116 .1120255 2.00 0.046 .0041457 .4432775 L2. | .3686666 .1184394 3.11 0.002 .1365295 .6008036 L3. | .1765568 .1215998 1.45 0.147 -.0617743 .414888 L4. | .111645 .1140986 0.98 0.328 -.1119842 .3352742 | dlconsumpt~n | L1. | -.3632978 .1479002 -2.46 0.014 -.6531768 -.0734189 L2. | -.0710444 .1634024 -0.43 0.664 -.3913073 .2492185 L3. | .0023201 .1476537 0.02 0.987 -.2870759 .2917161 L4. | -.0773523 .1304631 -0.59 0.553 -.3330553 .1783506 | _cons | .011174 .004295 2.60 0.009 .0027559 .0195921 ------------------------------------------------------------------------------

. * check for stability . varstable

Eigenvalue stability condition +----------------------------------------+ | Eigenvalue | Modulus | |--------------------------+-------------| | -.1644803 + .8137038i | .830161 | | -.1644803 - .8137038i | .830161 | | -.7367489 | .736749 | | -.5297398 + .4252868i | .679333 | | -.5297398 - .4252868i | .679333 | | .6637999 + .1027901i | .671711 | | .6637999 - .1027901i | .671711 | | -.3538959 + .4409841i | .565428 | | -.3538959 - .4409841i | .565428 | | .2557499 + .334021i | .420688 | | .2557499 - .334021i | .420688 | | .2288345 | .228834 | +----------------------------------------+ All the eigenvalues lie inside the unit circle. VAR satisfies stability condition.

. * perform Granger causality tests . vargranger

Granger causality Wald tests +------------------------------------------------------------------+ | Equation Excluded | chi2 df Prob > chi2 | |--------------------------------------+---------------------------| | dlinvestment dlincome | .5338 4 0.970 | | dlinvestment dlconsumption | 2.7095 4 0.608 | | dlinvestment ALL | 4.9792 8 0.760 | |--------------------------------------+---------------------------| | dlincome dlinvestment | 3.5235 4 0.474 | | dlincome dlconsumption | 1.5569 4 0.817 | | dlincome ALL | 5.4077 8 0.713 | |--------------------------------------+---------------------------| | dlconsumption dlinvestment | 2.8044 4 0.591 | | dlconsumption dlincome | 11.609 4 0.021 | | dlconsumption ALL | 15.904 8 0.044 | +------------------------------------------------------------------+

. * generate eight-step-ahead dynamic forecasts . fcast compute m1_, step(8)

. * graph the forecasts vs actuals . fcast graph m1_dlinvestment m1_dlincome m1_dlconsumption, observed saving(327var8,replace) (note: file 327var8.gph not found) (file 327var8.gph saved)

. graph export 327var8.pdf,replace (file /Users/baum/Documents/EC327S2010/327var8.pdf written in PDF format)

. * generate orthogonalized IRFs based on this ordering . !rm 327irf1.irf

rm: 327irf1.irf: No such file or directory

. irf create order1,step(20) set(327irf1) (file 327irf1.irf created) (file 327irf1.irf now active) (file 327irf1.irf updated)

. irf graph oirf, impulse(dlincome) response(dlconsumption) saving(327irf8,replace) (note: file 327irf8.gph not found) (file 327irf8.gph saved)

. graph export 327irf8.pdf, replace (file /Users/baum/Documents/EC327S2010/327irf8.pdf written in PDF format)

. * generate table of FEVD for innovations in dlinvestment . irf ctable (order1 dlinvestment dlincome fevd) /// > (order1 dlinvestment dlconsumption fevd) /// > (order1 dlinvestment dlinvestment fevd), noci

+--------------------------------------------+ | | (1) | (2) | (3) | | step | fevd | fevd | fevd | |--------+-----------+-----------+-----------| |0 | 0 | 0 | 0 | |1 | .015684 | .120841 | 1 | |2 | .055523 | .119687 | .968818 | |3 | .06197 | .158301 | .966747 | |4 | .063336 | .160006 | .955585 | |5 | .065304 | .158634 | .955602 | |6 | .069096 | .174287 | .94992 | |7 | .070628 | .174743 | .947248 | |8 | .070657 | .174539 | .946295 | |9 | .071497 | .174646 | .94563 | |10 | .071921 | .175446 | .945563 | |11 | .071973 | .175467 | .944489 | |12 | .071981 | .175576 | .944489 | |13 | .072078 | .175696 | .944229 | |14 | .072079 | .175793 | .944218 | |15 | .072097 | .175854 | .944067 | |16 | .072101 | .175854 | .944015 | |17 | .072115 | .175884 | .944004 | |18 | .072122 | .175884 | .943964 | |19 | .072123 | .175899 | .943963 | |20 | .072128 | .175901 | .943939 | +--------------------------------------------+ (1) irfname = order1, impulse = dlinvestment, and response = dlincome (2) irfname = order1, impulse = dlinvestment, and response = dlconsumption (3) irfname = order1, impulse = dlinvestment, and response = dlinvestment

. * combined OIRFs . irf cgraph (order1 dlinvestment dlincome oirf) /// > (order1 dlinvestment dlconsumption oirf) /// > (order1 dlinvestment dlinvestment oirf), saving(327irfC,replace) (note: file 327irfC.gph not found) (file 327irfC.gph saved)

. graph export 327irfC.pdf, replace (file /Users/baum/Documents/EC327S2010/327irfC.pdf written in PDF format)

. log close name: <unnamed> log: /Users/baum/Documents/EC327S2010/327var.smcl log type: smcl closed on: 10 Mar 2010, 11:33:05 -----------------------------------------------------------------------------------------------------------------------------