Previous: , Up: The Model file   [Contents][Index]

4.25 Misc commands

Command: set_dynare_seed (INTEGER)
Command: set_dynare_seed (`default')
Command: set_dynare_seed (`clock')
Command: set_dynare_seed (`reset')
Command: set_dynare_seed (`ALGORITHM', INTEGER)

Sets the seed used for random number generation. It is possible to set a given integer value, to use a default value, or to use the clock (by using the latter, one will therefore get different results across different Dynare runs). The reset option serves to reset the seed to the value set by the last set_dynare_seed command. On MATLAB 7.8 or above, it is also possible to choose a specific algorithm for random number generation; accepted values are mcg16807, mlfg6331_64, mrg32k3a, mt19937ar (the default), shr3cong and swb2712.

Command: save_params_and_steady_state (FILENAME);

For all parameters, endogenous and exogenous variables, stores their value in a text file, using a simple name/value associative table.

Note that no variable type is stored in the file, so that the values can be reloaded with load_params_and_steady_state in a setup where the variable types are different.

The typical usage of this function is to compute the steady-state of a model by calibrating the steady-state value of some endogenous variables (which implies that some parameters must be endogeneized during the steady-state computation).

You would then write a first .mod file which computes the steady state and saves the result of the computation at the end of the file, using save_params_and_steady_state.

In a second file designed to perform the actual simulations, you would use load_params_and_steady_state just after your variable declarations, in order to load the steady state previously computed (including the parameters which had been endogeneized during the steady state computation).

The need for two separate .mod files arises from the fact that the variable declarations differ between the files for steady state calibration and for simulation (the set of endogenous and parameters differ between the two); this leads to different var and parameters statements.

Also note that you can take advantage of the @#include directive to share the model equations between the two files (see Macro-processing language).

Command: load_params_and_steady_state (FILENAME);

For all parameters, endogenous and exogenous variables, loads their value from a file created with save_params_and_steady_state.

This function is used in conjunction with save_params_and_steady_state; see the documentation of that function for more information.

MATLAB/Octave command: dynare_version ;

Output the version of Dynare that is currently being used (i.e. the one that is highest on the MATLAB/Octave path).

MATLAB/Octave command: write_latex_definitions ;

Writes the names, LaTeX names and long names of model variables to tables in a file named <<M_.fname>>_latex_definitions.tex. Requires the following LaTeX packages: longtable

MATLAB/Octave command: write_latex_parameter_table ;

Writes the LaTeX names, parameter names, and long names of model parameters to a table in a file named <<M_.fname>>_latex_parameters.tex. The command writes the values of the parameters currently stored. Thus, if parameters are set or changed in the steady state computation, the command should be called after a steady-command to make sure the parameters were correctly updated. The long names can be used to add parameter descriptions. Requires the following LaTeX packages: longtable, booktabs

MATLAB/Octave command: write_latex_prior_table ;

Writes descriptive statistics about the prior distribution to a LaTeX table in a file named <<M_.fname>>_latex_priors_table.tex. The command writes the prior definitions currently stored. Thus, this command must be invoked after the estimated_params block. If priors are defined over the measurement errors, the command must also be preceeded by the declaration of the observed variables (with varobs). The command displays a warning if no prior densities are defined (ML estimation) or if the declaration of the observed variables is missing. Requires the following LaTeX packages: longtable, booktabs

MATLAB/Octave command: collect_latex_files ;

Writes a LaTeX file named <<M_.fname>>_TeX_binder.tex that collects all TeX output generated by Dynare into a file. This file can be compiled using pdflatex and automatically tries to load all required packages. Requires the following LaTeX packages: breqn, psfrag, graphicx, epstopdf, longtable, booktabs, caption, float, amsmath, amsfonts, and morefloats


Previous: , Up: The Model file   [Contents][Index]