SVAR model with long and short run restrictions

Questions and discussions on Vector Autoregressions
Benedek11
Posts: 7
Joined: Tue Dec 03, 2013 7:34 am

SVAR model with long and short run restrictions

Unread post by Benedek11 »

Hello,

Has anyone had any experience estimating a Structural VAR like the one in Gali (1999) Technology, Employment, and the Business Cycle: Do Technology Shocks Explain Aggregate Fluctuations?

Thank you
Last edited by Benedek11 on Thu Dec 05, 2013 2:37 am, edited 1 time in total.
TomDoan
Posts: 7814
Joined: Wed Nov 01, 2006 4:36 pm

Re: SVAR model with long run restriction only

Unread post by TomDoan »

It's included with RATS. See http://ideas.repec.org/c/boc/bocode/rtz00062.html. Note, that you could have found that by googling

Gali 1999 RATS
Benedek11
Posts: 7
Joined: Tue Dec 03, 2013 7:34 am

Re: SVAR model with long and short run restrictions

Unread post by Benedek11 »

Hi,

I ran the package available at http://ideas.repec.org/c/boc/bocode/rtz00062.html as suggested by TomDoan. It runs fine producing the correct results. However, the impulse response of non-technology shocks on productivity is not right. (Graphs below.)

Do you have any idea why this might me be the case?

Many thanks.
Attachments
Figure 2 -Gali (original).jpg
Figure 2 -Gali (original).jpg (128.44 KiB) Viewed 17963 times
Figure 2 -Gali (reproduced).jpg
Figure 2 -Gali (reproduced).jpg (142.88 KiB) Viewed 17963 times
TomDoan
Posts: 7814
Joined: Wed Nov 01, 2006 4:36 pm

Re: SVAR model with long and short run restrictions

Unread post by TomDoan »

Benedek11 wrote:Hi,

I ran the package available at http://ideas.repec.org/c/boc/bocode/rtz00062.html as suggested by TomDoan. It runs fine producing the correct results. However, the impulse response of non-technology shocks on productivity is not right. (Graphs below.)

Do you have any idea why this might me be the case?

Many thanks.
You'll note that the center response matches up so it's a question about the error bands. The program includes calculations of error bands both using the delta method (which are the ones labeled with the "Figure 2" and "Figure 3") and Monte Carlo integration (which are earlier ones which aren't labeled). The two give relatively similar answers in the modernized RATS code, so it's possible that there was some minor computational error in the empirical work in the paper which made the error bands too narrow.
Benedek11
Posts: 7
Joined: Tue Dec 03, 2013 7:34 am

Re: SVAR model with long and short run restrictions

Unread post by Benedek11 »

TomDoan wrote:
Benedek11 wrote:Hi,

I ran the package available at http://ideas.repec.org/c/boc/bocode/rtz00062.html as suggested by TomDoan. It runs fine producing the correct results. However, the impulse response of non-technology shocks on productivity is not right. (Graphs below.)

Do you have any idea why this might me be the case?

Many thanks.
You'll note that the center response matches up so it's a question about the error bands. The program includes calculations of error bands both using the delta method (which are the ones labeled with the "Figure 2" and "Figure 3") and Monte Carlo integration (which are earlier ones which aren't labeled). The two give relatively similar answers in the modernized RATS code, so it's possible that there was some minor computational error in the empirical work in the paper which made the error bands too narrow.
That makes perfect sense, thank you.
Benedek11
Posts: 7
Joined: Tue Dec 03, 2013 7:34 am

Re: SVAR model with long and short run restrictions

Unread post by Benedek11 »

Hi,

Could anyone advise me on which part of the code for the Gali (1999) paper defines the number of periods the impulse response functions plot? I am running the model with a new data series and the unit root test suggests that the series might be stationary in a longer time span and therefore it would be helpful to know what happens if the time horizon is not 12 quarters as in Gali (1999), but 36 or 48.


Thanks in advance
TomDoan
Posts: 7814
Joined: Wed Nov 01, 2006 4:36 pm

Re: SVAR model with long and short run restrictions

Unread post by TomDoan »

It's

COMPUTE IRH = 13
Benedek11
Posts: 7
Joined: Tue Dec 03, 2013 7:34 am

Re: SVAR model with long and short run restrictions

Unread post by Benedek11 »

Thank you.

Is there also a way to modify the impulse response graphs so that labour (i.e. hours/employment) is also plotted cumulatively similarly to the impulse response of productivity?

On a different note, do you probably know what the procedure is to test the stability of the parameters in a VAR?
TomDoan
Posts: 7814
Joined: Wed Nov 01, 2006 4:36 pm

Re: SVAR model with long and short run restrictions

Unread post by TomDoan »

Benedek11 wrote:Thank you.

Is there also a way to modify the impulse response graphs so that labour (i.e. hours/employment) is also plotted cumulatively similarly to the impulse response of productivity?
I believe that's what it's already doing. The options have that first differenced then accumulated.
Benedek11 wrote: On a different note, do you probably know what the procedure is to test the stability of the parameters in a VAR?
See Bai, Lumsdaine and Stock 1998. There's also a section on this in Lutkepohl's book and there are some examples.
Benedek11
Posts: 7
Joined: Tue Dec 03, 2013 7:34 am

Re: SVAR model with long and short run restrictions

Unread post by Benedek11 »

Thank you the article is very useful.

Do you know in the Gali model what controls a) the confidence bands (i.e. I would like to set them more conservative)
b) the number of lags in the VAR?


Many thanks
TomDoan
Posts: 7814
Joined: Wed Nov 01, 2006 4:36 pm

Re: SVAR model with long and short run restrictions

Unread post by TomDoan »

Benedek11 wrote:Thank you the article is very useful.

Do you know in the Gali model what controls a) the confidence bands (i.e. I would like to set them more conservative)
Change the options on @MCGRAPHIRF. The default is PERCENTILES=||.16,.84|| which is a "robust" version of one standard error bands. If you want 90% bands instead, use PERCENTILES=||.05,.95||.

Benedek11 wrote: b) the number of lags in the VAR?
The model setup is in islmvarsetup.src which is pulled into all the other program files.
Benedek11
Posts: 7
Joined: Tue Dec 03, 2013 7:34 am

Re: SVAR model with long and short run restrictions

Unread post by Benedek11 »

I cannot seem to find @MCGRAPHIRF in the code when searching for it in the original gali_aer.rpf
What could be the reason for that?

The package also does not include islmvarsetup.src. Is that not for the "How Well Does the IS-LM Model Fit Postwar U.S. Data" Gali (1992) article? I am working on the "Technology, Employment, and the Business Cycle - Do Technology Shocks Explain Aggregate Fluctuations" Gali (1999)

Thanks
TomDoan
Posts: 7814
Joined: Wed Nov 01, 2006 4:36 pm

Re: SVAR model with long and short run restrictions

Unread post by TomDoan »

Sorry, I got the Gali papers crossed. The controls for the 1999 paper are:

COMPUTE LAGS=4
COMPUTE NVAR=2
COMPUTE NSTEP= 100
COMPUTE NDRAWS= 500
COMPUTE NSE = 2
COMPUTE IRH = 13
COMPUTE NW = 6

NSE controls the number of standard errors in the bands.
Post Reply