| solve_dsge | R Documentation |
Computes the state-space solution of a DSGE model using the
Klein (2000) method. Accepts both linear models (dsge_model) and
nonlinear models (dsgenl_model). For nonlinear models, the steady
state is computed and the model is linearized automatically.
solve_dsge(model, params = NULL, shock_sd = NULL, tol = 1e-06, order = 1L)
model |
A |
params |
Named numeric vector of parameter values. If |
shock_sd |
Named numeric vector of shock standard deviations.
If |
tol |
Tolerance for classifying eigenvalues as stable (|lambda| < 1 + tol). Default is 1e-6. |
order |
Integer. Approximation order: 1 (default), 2 for second-order,
or 3 for third-order perturbation. Orders 2 and 3 require a
|
The stable solution is computed by cyclic reduction (as Dynare's
cycle_reduction option); if that fails, for example with unit roots
or a singular lead matrix, the stable deflating subspace of the model's
matrix pencil is found with the inverse-free spectral divide of Bai,
Demmel and Gu (1997), which needs no QZ decomposition; an
undetermined-coefficients iteration is the last resort. As in Dynare,
eigenvalues with modulus up to 1 + 1e-6 count as stable, so unit roots
are allowed. Saddle-path stability requires that all eigenvalues of H
have modulus below 1 + tol.
For nonlinear models, the solver first computes the deterministic steady state, then linearizes the model via first-order Taylor expansion, and finally solves the resulting linear system.
An object of class "dsge_solution" containing:
Policy matrix (n_controls x n_states).
State transition matrix (n_states x n_states).
Shock coefficient matrix (n_states x n_shocks).
Observation selection matrix.
Complex vector of eigenvalues.
Logical: is the system saddle-path stable?
Number of stable eigenvalues.
The parameter values used.
Reference to the model object.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.