Dear Jack,
I have two questions concerning VARs:
1. Is there any built in function in gretl for historical forecast error
variance decompositions?
> Not at the moment, but addinbg this to the SVAR package has been on my to-do list for a long time. I'll see what I can do in the next few days.
No worries, thanks!
2. Is it possible to estimate a recursive linear VAR imposing zero
restrictions on some coefficients? That is, is it possible to estimate a
VAR with a block exogenous set of variables?
If I understand correctly what you want to do, the SVAR package should make your job relatively painless: I'm attaching an example which uses the AWM dataset to set up a NK 3-equation model and estimate it under an identification strategy like the one you describe. For more details, see the SVAR documentation.
<hansl>
# load the SVAR package
include SVAR.gfn
# use the classic ECB data set
open AWM.gdt --quiet
genr time
genr dummy
# set up the data for the New Keynesian 3-eq model
series y = 100 * hpfilt(ln(YER))
series u = 100 * URX
series p = 100 * sdiff(ln(HICP))
list X = y u p
list exo = const time dq1 dq2 dq3
# find the VAR order via HQC
var 8 X ; exo --lagselect
scalar bestlag = iminc($test[,3])
# set up the model
Mod = SVAR_setup("C", X, exo, bestlag)
Mod["horizon"] = 40
#set up recursive restrictions
SVAR_restrict(&Mod, "C", 1, 2, 0)
SVAR_restrict(&Mod, "C", 1, 3, 0)
SVAR_restrict(&Mod, "C", 2, 3, 0)
#now add two extra restrictions
SVAR_restrict(&Mod, "C", 3, 1, 0)
SVAR_restrict(&Mod, "C", 3, 2, 0)
I'm not sure this is what I'm looking for. If I correctly understood, here you are adding "extra" restrictions in
the standard Cholesky approach, right? Instead, what I would like to have is an estimate of the following system:
Y1,t = a11 Y1,t-1 + u1t
Y2,t = a21 Y1,t-1 + a22 Y2,t-1 + a23 Y3,t-1 + u2t
Y3,t = a31 Y1,t-1 + a32 Y2,t-1 + a33 Y3,t-1 + u3t
Does the SVAR function allow one to estimate it?
Thanks,
Gabriela