I’m trying to replicate their particle filter estimation. Prof. Schorfheide uploaded replication code written in Matlab and I’m trying to translate it. My problem is I can’t compute mode. The following error occurs.
ESTIMATION_CHECKS: There was an error in computing the likelihood for initial parameter values.
ESTIMATION_CHECKS: You should try using the calibrated version of the model as starting values. To do
ESTIMATION_CHECKS: this, add an empty estimated_params_init-block with use_calibration option immediately before the estimation
ESTIMATION_CHECKS: command (and after the estimated_params-block so that it does not get overwritten):
Error using chol
Matrix must be positive definite.
I am wondering anyone could kindly give me some indication about this. Thank in advance. I’m attaching my mod file and data. abs_nonlinear2.mod (10.3 KB) usdat.m (15.3 KB)
Thank you for your quick response, Prof. Pfeifer, but I thought I included measurement errors and don’t understand where is wrong. I’d appreciate you correct me.
In your monograph titled by “A Guide to Specifying Observation Equations for the
Estimation of DSGE Models”, you explain there are two ways to treat measurement error. I tried to follow the method in section 6.1, i.e. treating measurement errors as a special case of exogenous variables. I defined measurement equation as follows.
However, I treated the standard deviation params (cst_eYobs, eDNWobs, eINFobs, eRobs) as fixed parameter. Is this problematic? Or, are there other mistake?
Dynare’s current implementation of the particle filter relies on using measurement error specified with Dynare’s syntax. But my hunch is that this alone will not solve the issue. Regardless, please change the specification and then provide the updated mod-file for further debugging.
in the estimation-command. abs_nonlinear2.mod (10.6 KB)
On top of that, in Dynare 4.6.3 there is this problem is due to a bug in error handling in Dynare. See the change in non_linear_dsge_likelihood.m.