Hello, I am building a simple New Keynesian model using Bayesian estimation and Rotemberg price setting is used. When I run the mod file, the strange errors are follows:

Error using dynare_estimation_1 (line 82)
For estimating the model with a second order approximation using a non linear
filter, one should have options_.particle.status=true;
Error in dynare_estimation (line 105)
dynare_estimation_1(var_list,dname);
Error in RE.driver (line 279)
oo_recursive_=dynare_estimation(var_list_);
Error in dynare (line 293)
evalin(‘base’,[fname ‘.driver’]) ;

I am really confusing don’t know how to solve it. It seems that there is no same issue in the Forum. RE.mod (3.1 KB)

Thanks!!!
After I remove ‘clear’, new problem arises:

(minus) the hessian matrix at the “mode” is not positive definite!
=> posterior variance of the estimated parameters are not positive.
You should try to change the initial values of the parameters using
the estimated_params_init block, or use another optimization routine.
Warning: The results below are most likely wrong!

In dynare_estimation_1 (line 315)
In dynare_estimation (line 105)
In RE.driver (line 279)
In dynare (line 293)

MODE CHECK

Fval obtained by the minimization routine (minus the posterior/likelihood)): 306.828471
Warning: Matrix is singular, close to singular or badly scaled. Results may
be inaccurate. RCOND = NaN.

In dynare_estimation_1 (line 338)
In dynare_estimation (line 105)
In RE.driver (line 279)
In dynare (line 293)

I don’t want to use another optimization routine(I tried, not converge).
Would you please give some advice or related notes on how to change prior? mode check_1.fig (217.8 KB) mode check_2.fig (59.4 KB)

It seems you have an identification-problem. I get

MOMENTS (ISKREV, 2010):
!!!WARNING!!!
The rank of J (Jacobian of first two moments) is deficient!
SE_ev is collinear w.r.t. all other parameters!
SE_ea is collinear w.r.t. all other parameters!
SE_eq is collinear w.r.t. all other parameters!
sigma is collinear w.r.t. all other parameters!
phi is collinear w.r.t. all other parameters!
kp is collinear w.r.t. all other parameters!
phiy is collinear w.r.t. all other parameters!
phip is collinear w.r.t. all other parameters!

Thus, you cannot identify all parameters with your observables.

I add another observation INT = paiss + 100*rho + i, but still
SPECTRUM (QU AND TKACHENKO, 2012):
!!!WARNING!!!
The rank of Gbar (Jacobian of mean and spectrum) is deficient!

SE_ev is collinear w.r.t. all other parameters!
SE_ea is collinear w.r.t. all other parameters!
SE_eq is collinear w.r.t. all other parameters!
alpha is collinear w.r.t. all other parameters!
sigma is collinear w.r.t. all other parameters!
kp is collinear w.r.t. all other parameters!
phiy is collinear w.r.t. all other parameters!
phip is collinear w.r.t. all other parameters!

Why is such a case? Thank you so much for your time

I have another question: the ‘identification’ is warning, but it still successfully estimates and goes through all the procedure. In this case, are the results reliable?

MOMENTS (ISKREV, 2010):
!!!WARNING!!!
The rank of J (Jacobian of first two moments) is deficient!

SE_ea is collinear w.r.t. all other parameters!
phi is collinear w.r.t. all other parameters!
kp is collinear w.r.t. all other parameters!

RE.mod (3.1 KB) data_detr.xlsx (14.6 KB)
Here is my modified file. I also notice that for MCMC convergence diagnostic, red line and blue line of kp,SE_eq diverge in the middle sampling which is strange, though they finally converge.

For observation equation, output was detrended, inflation and nominal interest rate were demeaned, following your “A Guide to Specifying Observation Equations for the Estimation of DSGE Models” chp4.2

I usually recommend running one long chain with the Geweke convergence diagnostics as it does not rely on eye-ball econometrics.

The identification error is to be taken seriously. It implies that only a linear combination of the three parameters is identified. Thus, the individual values are meaningless.