Questions on bayesian estimation

Dear Professor Pfeifer,

I’ve got three questions when doing the bayesian estimation. Would you please give any advice? Thank you very much.

  1. The moments of main variables I got after bayesian estimation are much larger than the moments of real data. I try to use endogenous_prior option, but I get errors as bellow:

There are 27 eigenvalue(s) larger than 1 in modulus
for 27 forward-looking variable(s)

The rank condition is verified.

In endogenous_prior (line 88)
In dsge_likelihood (line 833)
In initial_estimation_checks (line 137)
In dynare_estimation_1 (line 165)
In dynare_estimation (line 105)
In czh (line 779)
In dynare (line 235)
Warning: Matrix is singular, close to singular or badly
scaled. Results may be inaccurate. RCOND = NaN.

Error in computing likelihood for initial parameter values

ESTIMATION_CHECKS: There was an error in computing the likelihood for initial parameter values.
ESTIMATION_CHECKS: If this is not a problem with the setting of options (check the error message below),
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 print_info (line 114)
Prior density is not a number (NaN)
Error in print_info (line 114)
error(‘Prior density is not a number (NaN)’);
Error in initial_estimation_checks (line 175)
print_info(info, DynareOptions.noprint,
Error in dynare_estimation_1 (line 165)
oo_ =
Error in dynare_estimation (line 105)
Error in czh (line 779)
Error in dynare (line 235)
evalin(‘base’,fname) ;

How should I deal with this?

  1. Is there any way to make the simulated moments close to the real moments?

  2. When running the bayesian estimation in a model with specified trend, could I use one-sided hp filter instead of one-differnece filter to deal with the observed data?

Thanks again for reading this post, and really appreciate your kindness.

  1. I would need to see the codes to replicate the issue.
  2. Not really. Tweaking the priors may be an option.
  3. Yes, you can use a different filter.

Dear Professor Pfeifer,

Thank you for your reply.
For the first question, I send you the code through message.
And I’ve got a new question: In which case could I add measurement error in the model?

  1. I cannot replicate your issue in Dynare 5.2.
  2. You can always add measurement error. The question is why you would want to do that.