Page 1 of 1

index out of bounds ...

PostPosted: Sat May 08, 2010 11:16 am
by samirhuseyn
Hi everyone

While running my mod file in Dynare, I got the following error message,can anyone suggest solution?

thanks in advance

best

Samir


Configuring Dynare ...
[mex] Generalized QZ.
[mex] Sylvester equation solution.
[mex] Kronecker products.
[mex] Sparse kronecker products.

Starting Dynare ...
Starting preprocessing of the model file ...
20 equation(s) found
Processing derivation ...
Processing Order 1... done
Processing Order 2... done
Processing outputs ...
Preprocessing completed.
Starting Matlab computing ...


STEADY-STATE RESULTS:

y 1.11022e-016
a 0
psi_t 0
mc 0
c 1.11022e-016
pi_f 0
pi_h 0
pi_t 0
q 1.11022e-016
r 0
y_st 0
r_st 0
tot -2.22045e-016
nu_tot 0
nu_q 0
nu_pih 0
nu_pif 0
nu_r 0
nu_rst 0
nu_yst 0

EIGENVALUES:
Modulus Real Imaginary

1.887e-016 -1.887e-016 0
2.882e-016 2.882e-016 0
0.3897 0.2728 0.2783
0.3897 0.2728 -0.2783
0.5 0.5 0
0.5 0.5 0
0.5 0.5 0
0.5212 0.3792 0.3576
0.5212 0.3792 -0.3576
0.6539 0.6539 0
0.9 0.9 0
0.9 0.9 0
0.9 0.9 0
0.9 0.9 0
0.9 0.9 0
0.9 0.9 0
0.9 0.9 0
1.254 1.254 0
2.898 2.898 0
4.006 4.006 0
Inf Inf 0


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

The rank condition is verified.


You did not declare endogenous variables after the estimation command.

You did not declare endogenous variables after the estimation command.
??? Attempted to access k(1); index out of bounds because numel(k)=0.

Error in ==> draw_prior_density at 114
binf = abscissa(k(1));

Error in ==> plot_priors at 97
[x,f,abscissa,dens,binf,bsup] = draw_prior_density(i);

Error in ==> dynare_estimation_1 at 92
plot_priors

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

Error in ==> d2 at 297
dynare_estimation(var_list_);

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

Re: index out of bounds ...

PostPosted: Sat May 08, 2010 11:53 am
by jpfeifer
Hi,
please post the data-file so people can try to debug the code.

Re: index out of bounds ...

PostPosted: Sat May 08, 2010 11:59 am
by samirhuseyn
jpfeifer wrote:Hi,
please post the data-file so people can try to debug the code.



Thanks for reply!

I am attaching data file as well..

It is in txt format,I usually keep it in upper directory,from where mod file exist. Maybe it seems silly, but it is the best way I found. As I could not "produce" proper mat file:(

Re: index out of bounds ...

PostPosted: Sat May 08, 2010 1:53 pm
by samirhuseyn
Sorry,

And please keep this file in the same directory with the mod file. Without it mod file would not read data.txt

Re: index out of bounds ...

PostPosted: Sat May 08, 2010 4:24 pm
by jpfeifer
Your problem seems to be the line

Code: Select all
thetah,          beta_pdf,           0.5,       0.5;

Apparently, the standard deviation of 0.5 (the second value) is too large. If you set it to 0.49, it runs.

Re: index out of bounds ...

PostPosted: Mon May 10, 2010 8:07 am
by StephaneAdjemian
Hi, The problem is that when the prior expectation and the prior standard deviation are equal to one half the prior density is not defined. Dynare computes the parameters \alpha and \beta of the beta density (in set_prior.m) and in this special case obtains \alpha=\beta=0. We will add a warning for this exception in a future release.

Best, Stéphane.