Page 2 of 2

Re: problem with estimation_params

PostPosted: Sat Oct 08, 2016 4:01 pm
by jpfeifer
Then you need to find out what is going on. Did you try a different mode-finder?

Re: problem with estimation_params

PostPosted: Sat Oct 08, 2016 4:29 pm
by lilia
I did and the plot is always weird. May it depend on the model being unstable under some parameters configurations? Thanks for your help
Lilia

Re: problem with estimation_params

PostPosted: Sun Oct 09, 2016 8:55 am
by jpfeifer
Something here seems to be fundamentally wrong. Could you please upload a zip-file with the most recent version of the mod-file, the data, and the mode-file you found.

Re: problem with estimation_params

PostPosted: Sun Oct 09, 2016 9:52 am
by lilia
me too, I think something must be wrong but I do not see what. the model is correct. what I'm not completely sure about is the relation between the theoretical and the observed variables. I've tried with both per capita consumption and aggregate consumption together with different methods for making these variables stationary. the results are always the same...

thanks a lot, I do appreciate your help

Re: problem with estimation_params

PostPosted: Sun Oct 09, 2016 7:22 pm
by jpfeifer
There is clearly an issue with the mean here. I would recommend using demeaned growth rates for estimation if possible. Related to this, Dynare has a hard time finding the steady state during MCMC. That is where the red dots come from. If the steady state exists for those values of b and Dynare is not able to find them, you might move to a more analytical approach of steady state finding.

Re: problem with estimation_params

PostPosted: Mon Oct 10, 2016 3:39 pm
by lilia
Hi, thanks for the patience!
The problem of the steady state seems solved (no more red dots). however, the mode check plot and the estimation results are still strange. The likelihood is very small and the Hessian eigenvalues are equal! what does it mean?

This is from the log:

Initial value of the log posterior (or likelihood): -6972520.5243
Gradient norm 17418.6617
Minimum Hessian eigenvalue 7568286935.463
Maximum Hessian eigenvalue 7568286935.463

Iteration 1
Predicted improvement: 0.020044812
lambda = 1; f = 6972520.4849095
lambda = 1.9332; f = 6972520.4481676
lambda = 3.7372; f = 6972520.3771577
lambda = 7.2247; f = 6972520.2399525

Norm of First-order Trust-region
Iteration Func-count f(x) step optimality radius
0 1 9.31346e-11 9.28e-06 1
1 2 1.31201e-21 0.000275185 3.63e-11 1

<a href = "matlab: helpview([docroot '/toolbox/optim/msg_csh/optim_msg_csh.map'],'eqn_solved','CSHelpWindow');">Equation solved</a>.

fsolve completed because the vector of function values is near zero
as measured by the selected value of the <a href = "matlab: helpview([docroot '/toolbox/optim/msg_csh/optim_msg_csh.map'],'fcn_tolerance_fsolve','CSHelpWindow');">function tolerance</a>, and
the <a href = "matlab: helpview([docroot '/toolbox/optim/msg_csh/optim_msg_csh.map'],'appears_regular','CSHelpWindow');">problem appears regular</a> as measured by the gradient.

Re: problem with estimation_params

PostPosted: Mon Oct 10, 2016 6:34 pm
by jpfeifer
Did you use demeaned growth rates? If yes, please provide the newest version.

Re: problem with estimation_params

PostPosted: Mon Oct 10, 2016 6:51 pm
by lilia
no, the previous run is with differenced data. I'll try with demeaned growth rates and see what happens. the reason why I haven't done it sofar is that the model is in levels and the means of the theoretical variables are not zero. thanks again!

Re: problem with estimation_params

PostPosted: Wed Oct 12, 2016 12:52 pm
by lilia
Dear Pfeifer,
please find attached the log with demeaned growth rates, something is still wrong... thanks

lilia

Re: problem with estimation_params

PostPosted: Wed Oct 12, 2016 12:53 pm
by lilia
the attachment

Re: problem with estimation_params

PostPosted: Thu Oct 13, 2016 7:07 am
by jpfeifer
Your calibrated standard deviation for the shock makes no sense. Your data is percent times 100. Try using

Code: Select all
c_obs = (c-mean(c))/100;

and estimating the standard deviation, for example
Code: Select all
estimated_params ;
b, normal_pdf, 1.16,0.05;
teta, normal_pdf, 5.3181, 0.05;
stderr zz, gamma_pdf, 0.1, 5;
end;

You need to adjust the prior according to your tastes.

Re: problem with estimation_params

PostPosted: Thu Oct 13, 2016 9:39 am
by lilia
many many thanks! I finally see where the problem came from and now everything works fine.