Dynare can't recognize irf_shocks

Hi, good afternoon!

I’m building an application and, while testing the enverionment on my server (linux system) I’ve run on the following problem:

Dynare throws the a error while reading the line

stoch_simul(irf=12,irf_shocks=( e_B e_I)) c_O c_RT c;

through octave:

syntax error, unexpected NAME

I’ve run tests on the .mod code SEVERAL TIMES on my computer (a windows system) with no problem whatsoever, so I don’t believe there’s really something wrong with the code, but the dynare/octave installation itself on the server.

Can you guys give me any tips/advice/solutions in order to solve this pickled situation? :open_mouth:

Try putting a comma between the two shocks in irf_shocks.

I tried

**stoch_simul(irf=12,irf_shocks=(e_B , e_I)) c_O c_RT c;

stoch_simul(irf=12,irf_shocks=(e_B, e_I)) c_O c_RT c;

stoch_simul(irf=12, irf_shocks=(e_B,e_I)) c_O c_RT c;

stoch_simul(irf=12, irf_shocks=(e_B ,e_I)) c_O c_RT c;**

to no avail.

And I was able to run this same code on my home computer… any ideas T-T?

If you are not using Dynare 4.4, please try it.
If you are, please post the full error message. In particular, is it a Matlab or Dynare preprocessing error? If the problem occurs after preprocessing, please post the generated m-file (the one with the same name as your mod-file).

It doesn’t get to generate a .m file, this is the log:

**Configuring Dynare …
[mex] Generalized QZ.
[mex] Sylvester equation solution.
[mex] Kronecker products.
[mex] Sparse kronecker products.
[mex] Bytecode evaluation.
[mex] k-order perturbation solver.
[mex] k-order solution simulation.

ERROR: nakaneProgram.mod:515.21-30: syntax error, unexpected NAME
Starting Dynare (version 4.1.2).
Starting preprocessing of the model file …

error: DYNARE: preprocessing failed
error: called from:
error: /usr/share/octave/site/api-v37/m/dynare.m at line 128, column 1**

Hope it helps to shed some light

Please upgrade to 4.4.

I was able to update it only as far as 4.3, as I run a Debian Squeeze server. Other versions aren’t compatible with the system.

Anyhow, I think that now it compile the whole .mod to .m but still generates an error:

**Configuring Dynare …
[mex] Generalized QZ.
[mex] Sylvester equation solution.
[mex] Kronecker products.
[mex] Sparse kronecker products.
[mex] Local state space iteration (second order).
[mex] Bytecode evaluation.
[mex] k-order perturbation solver.
[mex] k-order solution simulation.
[mex] Quasi Monte-Carlo sequence (Sobol).
[mex] Markov Switching SBVAR.

Starting Dynare (version 4.3.0).
Starting preprocessing of the model file …
Substitution of endo leads >= 2: added 3 auxiliary variables and e
Substitution of endo lags >= 2: added 21 auxiliary variables and e
Found 113 equation(s).
Evaluating expressions…done
Computing static model derivatives:

  • order 1
    Computing dynamic model derivatives:
  • order 1
  • order 2
    Processing outputs …done
    Preprocessing completed.
    Starting MATLAB/Octave computing.

error: structure has no member `static_and_dynamic_models_differ’
error: called from:
error: /usr/share/dynare/matlab/evaluate_steady_state.m at line
error: /usr/share/dynare/matlab/resol.m at line 104, column 24
error: /usr/share/dynare/matlab/check.m at line 73, column 25
error: /root/sources/other_sources/nakaneProgram.m at line 1040,
error: /usr/share/dynare/matlab/dynare.m at line 182, column 1**

What is happening now?

Another note: the nakaneProgram.mod has only 515 lines of code, strongly confirming that the problem isn’t on the .mod …

The weird thing is that I it run on my windows machine, it’s dynare is on the version 4.3.3, is there a way to update from 4.3.0 to it on Squeeze?

Is this difference on subversions enough to cause such behavior?

The error message refers to the m-file generated by Dynare, not the mod-file.

Regarding the versions: yes, the version makes a difference, because the irf_shocks-option only exists for more recent versions and the error message you get now seems to be related to a bug in 4.3.


We don’t provide a pre-compiled binary of Dynare 4.4 for Debian Squeeze because some libraries are outdated/non-available on that platform.

You can however try to compile Dynare 4.4.1 from source.

An alternative is to upgrade your server to Debian Wheezy, which is the latest Debian stable release. We provide binaries of Dynare 4.4.1 for Debian Wheezy.