Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Register
  • Sign in
  • dynare dynare
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 117
    • Issues 117
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 4
    • Merge requests 4
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Container Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • DynareDynare
  • dynaredynare
  • Issues
  • #35
Closed
Open
Issue created Feb 21, 2013 by Sébastien Villemot@sebastienOwner

Putting "shocks" before "endval" leads to wrong results

In a deterministic setup with both temporary and permanent shocks, the order of the shocks and endval blocks matter. Actually, putting shocks before endval leads to wrong results.

shocks uses set_shocks.m, which fills in oo_.exo_simul; the point is that, if endval has not been used, this structure is empty, so set_shocks fills it, at date of shocks, for ''all'' the exogenous, and using the ''initial'' steady state value.

When simul is finally called, it completes oo_.exo_simul with the ''final'' exogenous steady state, but only for those periods which have no temporary shocks. So at the dates with temporary shocks, the value of exogenous which are permanently shocked is wrong.

A quick fix is to forbid the use of shocks before endval.

A cleaner fix is to modify set_shocks.m so that it only sets values for the exogenous which are temporarily shocked, and leaves NaN for other exogenous. It would be simul's job to fill in the holes.

Assignee
Assign to
Time tracking