Node:stoch_simul, Previous:simul, Up:Computations and simulations



stoch_simul

stoch_simul[(OPTIONS)] [LIST OF VARIABLES]; Command
(available currently only in the Matlab and the Scilab versions)
OPTIONS:
AR = Integer
Order of autocorrelation coefficients to compute and to print (default = 5)
DR_ALGO = [0,1]
Specify the algorithm used for computing the quadratic approximation of the decision rules:
0: uses a "pure" perturbation approach as in Schmitt-Grohe and Uribe (2002) (default)
1: moves the point around which the Taylor expansion is computed toward the means of the distribution as in Collard and Juillard (2001)

DROP = Integer
Number of points dropped at the beginning of simulation before computing the summary statistics (default = 100)
HP_FILTER = Integer
Uses HP filter with lambda = Integer before computing moments (default: no filter)
HP_NGRID = Integer
Number of points in the grid for the discreet Inverse Fast Fourier Transform used in the HP filter computation. It may be necessary to increase it for highly autocorrelated processes (default = 512)
IRF = Integer
Number of periods on which to compute the IRFs (default = 40)
LINEAR
Indicates that the original model is linear (put it rather in the MODEL command).
NOCORR
Doesn't print the correlation matrix (default = PRINT)
NOFUNCTIONS
Doesn't print the coefficients of the approximated solution
NOMOMENTS
Doesn't print moments of the endogenous variables
PERIODS = Integer
Specify the number of periods to use in simulations. At order=1, no simulation is necessary to compute theoretical moments and IRFs. A number of PERIODS larger than one triggers automatically SIMUL=1 (default = 0).
ORDER = [1,2]
Order of Taylor approximation (default = 2)
REPLIC = Integer
Number of simulated series used to compute the IRFs (default = 1, if order = 1, and 50 otherwise)
SIMUL
Computes a stochastic simulation of the model for the number of periods specified in the PERIODS statement. Uses INITVAL values, possibly recomputed by STEADY, as initial values for the simulation. The simulated endogenous variables are made available to the user in a vector for each variable and in the global matrix y_. The variables are ordered alphabeticaly in the y_ matrix (default: no simulation)
SIMUL_SEED = Integer
Specify a seed for the random generator so as to obtain the same random sample at each run of the program. Otherwise a different sample is used for each run (default: seed not specified).

When a LIST OF VARIABLES is specified, results are displayed only for these variables.

stoch_simul computes a Taylor approximation of the decision and transition functions for the model, impulse response functions and various descriptive statistics (moments, variance decomposition, correlation and autocorrelation coefficients). For correlated shocks, the variance decomposition is computed as in the VAR literature through a Cholesky decomposition of the covariance matrix of the exogenous variables. When the shocks are correlated, the variance decomposition depends upon the order of the variables in the varexo command.

Variance decomposition, correlation, autocorrelation are only displayed for variables with positive variance. Impulse response functions are only ploted for variables with response larger than 1e-10.

The covariance matrix of the shocks is specified either with the shocks command or with the Sigma_e command.

Example 1

shocks;
var e;
stderr 0.0348;
end;

stoch_simul;
performs the simulation of the 2nd order approximation of a model with a single stochastic shock, e, with a standard error of 0.0348.

Example 2

stoch_simul(linear,irf=60) y k;
performs the simulation of a linear model and displays impulse response functions on 60 periods for variables y and k.