Page 1 of 1

Bayesian estimation, steady state problem

PostPosted: Mon Apr 04, 2011 11:43 am
by moh
Hi all,
I'm trying to estimate a DSGE model using Bayesian method but I've a problem with my steady state values. When I run Dynare, I obtain the following message:
There are 13 eigenvalue(s) larger than 1 in modulus
for 13 forward-looking variable(s)
The rank condition is verified.
You did not declare endogenous variables after the estimation command.
Loading 83 observations from data.m
??? Error using ==> initial_estimation_checks
The seadystate values returned by algeria_steadystate.m don't solve the static model!
Error in ==> dynare_estimation_1 at 367
initial_estimation_checks(xparam1,gend,data,data_index,number_of_observations,no_more_missing_observations);
Error in ==> dynare_estimation at 62
dynare_estimation_1(var_list,varargin{:});
Error in ==> algeria at 381
dynare_estimation(var_list_);
Error in ==> dynare at 132
evalin('base',fname) ;
What could be wrong ?

Re: Bayesian estimation, steady state problem

PostPosted: Tue Apr 19, 2011 9:40 am
by SébastienVillemot
This means that the steady state file that you wrote is wrong: the values returned by it are not an effective steady state of the model, at least for some parameter values.

Bayesian estimation problem

PostPosted: Thu May 26, 2011 12:37 am
by Dulamzaya
Hi,

I have been trying to estimate new keynesian model by bayesian estimation. And i have faced almost same problem here. I stated my all steady states by 0.But i don't know if that's ok. Here is the error note on matlab. Please help me.

??? Error using ==> print_info at 39
Blanchard Kahn conditions are not satisfied: no stable equilibrium

Error in ==> initial_estimation_checks at 101
print_info(info, options_.noprint)

Error in ==> dynare_estimation_1 at 367
initial_estimation_checks(xparam1,gend,data,data_index,number_of_observations,no_more_missing_observations);

Error in ==> dynare_estimation at 62
dynare_estimation_1(var_list,varargin{:});

Error in ==> model at 437
dynare_estimation(var_list_);

Error in ==> dynare at 132
evalin('base',fname) ;

I'm uploading my .mod and datafile. Please have a look.

Re: Bayesian estimation, steady state problem

PostPosted: Wed Jun 08, 2011 1:41 pm
by SébastienVillemot
This means that, at the mean values of your priors, the Blanchard-Kahn conditions are not satisfied. You need to modify your priors.

Re: Bayesian estimation, steady state problem

PostPosted: Mon Jun 20, 2011 10:28 pm
by dsinigaglia
Dear all,

I have the very same error message while trying to estimate a LINEAR macro model. This is a situation where I am trying to replicate the results of a working paper, so I already have a very good idea about the priors and the posteriors. In the simulation step, I get the message that the B-K condition IS verified. In this case, I calibrate the parameters and get the expected IRFs. When passing on to the estimation step, I provide priors whose means are either:

a) equal to the priors suggested by the author;

b) equal to the posteriors suggested by the author.

In both cases, I get the following error message:

*******************************************

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

The rank condition is verified.


You did not declare endogenous variables after the estimation command.
Posterior IRFs and posterior forecats will be computed for the
122 endogenous variables of your model, this can be very
long....


Choose one of the following options:

[1] Consider all the endogenous variables.
[2] Consider all the observed endogenous variables.
[3] Stop Dynare and change the mod file.

options [default is 1] = 2
Loading 46 observations from Datos.m

Error in computing likelihood for initial parameter values
??? Error using ==> print_info at 39
Blanchard Kahn conditions are not satisfied: no stable equilibrium

Error in ==> initial_estimation_checks at 101
print_info(info, options_.noprint)

Error in ==> dynare_estimation_1 at 367
initial_estimation_checks(xparam1,gend,data,data_index,number_of_observations,no_more_missing_observations);

Error in ==> dynare_estimation at 62
dynare_estimation_1(var_list,varargin{:});

Error in ==> Your_model at 1072
dynare_estimation(var_list_);

Error in ==> dynare at 132
evalin('base',fname) ;

***************************************

One key difference between the simultion step and the estimation step is that I use measurement errors in the second. This, however, shouldn't be a problem. Also, I get the same error message if a restrict the number of parameters to be estimated to only one.

Any ideas of what might be happening?

Thanks is advance.

Daniel

Re: Bayesian estimation, steady state problem

PostPosted: Tue Jun 21, 2011 6:56 am
by jpfeifer
If your model still contains a unit root, set lik_init=2 in the estimation command. If you model is already stationary, make sure you pass on the calibrated values from the stochastic simulation that satisfy the BK condition as starting values in the estimation (see the manual on where to put the starting values). Otherwise, the prior mean is used and these parameter values apparently do not satisfy the BK-conditions.

Re: Bayesian estimation, steady state problem

PostPosted: Tue Jun 21, 2011 12:41 pm
by dsinigaglia
Thanks for your prompt reply. I will try in that line of work. However, I should also notice that the estimation DOES work when I use the Dynare version 4.0.4. The problem seems to be restricted to the 4.2.0 version. I still have to run some tests on that, but it seems the Dynare version has something to do with that.

Regards,

Daniel

Re: Bayesian estimation, steady state problem

PostPosted: Tue Jun 21, 2011 2:18 pm
by jpfeifer

Re: Bayesian estimation, steady state problem

PostPosted: Tue Jun 21, 2011 6:21 pm
by dsinigaglia
True. It worked fine in the latest version. In addition, choosing proper starting values also improved the maximization routine significantly. Thanks a lot.

Best regards,

Daniel