bootstrapping DSGE model; how are residuals in DLM computed?
Posted: Tue Jun 16, 2020 1:42 pm
Hi Tom (and everyone),
As I understand it, DLM does simulations of DSGE models by drawing Normal shocks according to the solved variance-covariance matrix. However, if one wishes to estimate the model via indirect inference, one must simulate the DSGE via bootstrapping.
DLM will provide the estimated residuals *after Kalman smoothing only*. For example, in the Ireland replication, if one uses the command
dlm(startup=SolveModel(),y=yf,$
a=afull,f=ffull,c=cfull,sw=swfull,presample=ergodic,$
pmethod=simplex,piters=5,method=bfgs,iters=100,$
reject=(eta<1.0.or.eta>1.05.or.rho>=1.0),type=smooth,what=what) 1948:1 2002:2 states
then DLM estimates residuals ("what") from which one can draw from.
However (apologies for my ignorance, since the answer is probably obvious), as far as I can tell, neither the manuals nor the state space/DSGE manual tell us how those residuals are calculated.
I ask because there are two versions of indirect inference (and at least two methods to calculate the residuals). The first, the "LIML" version, specifies a reduced-form model, such as a VAR, for how expectations are formed (and this seems to be what is done in the Angelini and Fanelli (2016, OxBullEconStat) "Expectations Correction" method, though the motivation for the latter is to soak up autocorrelation in the residuals--since these should not be autocorrelated). The second method uses the structural model to generate the forecast of the variable, and this method is evidently more time-consuming, as it involves iteration, and it can be a more challenging optimization problem.
I would guess that DLM does the latter ,but I was hoping you could clarify this for me. (Also, why is it that these residuals are only available after smoothing?)
I am trying to develop code to estimate the Ireland example via indirect inference, so I am developing code to do the bootstrapping. I believe that if I am going to use DLM, the LIML version is off the table?
thanks for any and all help!
As I understand it, DLM does simulations of DSGE models by drawing Normal shocks according to the solved variance-covariance matrix. However, if one wishes to estimate the model via indirect inference, one must simulate the DSGE via bootstrapping.
DLM will provide the estimated residuals *after Kalman smoothing only*. For example, in the Ireland replication, if one uses the command
dlm(startup=SolveModel(),y=yf,$
a=afull,f=ffull,c=cfull,sw=swfull,presample=ergodic,$
pmethod=simplex,piters=5,method=bfgs,iters=100,$
reject=(eta<1.0.or.eta>1.05.or.rho>=1.0),type=smooth,what=what) 1948:1 2002:2 states
then DLM estimates residuals ("what") from which one can draw from.
However (apologies for my ignorance, since the answer is probably obvious), as far as I can tell, neither the manuals nor the state space/DSGE manual tell us how those residuals are calculated.
I ask because there are two versions of indirect inference (and at least two methods to calculate the residuals). The first, the "LIML" version, specifies a reduced-form model, such as a VAR, for how expectations are formed (and this seems to be what is done in the Angelini and Fanelli (2016, OxBullEconStat) "Expectations Correction" method, though the motivation for the latter is to soak up autocorrelation in the residuals--since these should not be autocorrelated). The second method uses the structural model to generate the forecast of the variable, and this method is evidently more time-consuming, as it involves iteration, and it can be a more challenging optimization problem.
I would guess that DLM does the latter ,but I was hoping you could clarify this for me. (Also, why is it that these residuals are only available after smoothing?)
I am trying to develop code to estimate the Ireland example via indirect inference, so I am developing code to do the bootstrapping. I believe that if I am going to use DLM, the LIML version is off the table?
thanks for any and all help!