Issues with code 2 shocks

izzzzy.mod (1.2 KB)


I am having issues with my codes. I am modelling a RBC model with 2 shocks - TFP and revenue shocks. However, dynare is producing the IRFs for TFP shock only.
My questions are as follows;

  1. How do I resolve the issue and get dynare to produce IRFs for both shocks?
  2. How do I instruct dynare to simulate second moments for TPF shock, revenue shock and both shocks?
    Please could you advise me on how to resolve this?

Dynare is already producing IRFs for both shocks as you can see - for A and R. The issue is that from this equation gc+Ig+gt=tau_c*c+tau_k*r*k+tau_h*w*h+R, R does not significantly affect any of the variables. For example, if you write the equation as follows gc=tau_c*c+tau_k*r*k+tau_h*w*h+R-(+Ig+gt), R does not significantly affect gc because there is a feedback from (+Ig+gt) which cancels that effect. Dynare do not show the IRFs for revenue shocks because they are almost zero. If you want to see the almost-zero IRFs for revenue shocks, you can plot them manually. They are in the oo_ folder. So it is a feature of your model, depending on the parameters you have, not a dynare problem.

You can also set irf_plot_threshold = 0

Hello Kofiemma,

Thank you for your kind response and intuition.

How do I instruct Dynare to simulate second moments for TPF shock only, revenue shock only and both shocks? What command I mean?

Is it “stoch_simul” (order=1,irf=40, hp_filter=100, second moment)?
Please correct me if I am wrong.


Hello Prof.

When you say “set irf_plot_threshold = 0” can you explain further please?


  1. If you want conditional moments, you need to simulate the model with one shock at a time. See e.g. DSGE_mod/Gali_2015_chapter_4.mod at master · JohannesPfeifer/DSGE_mod · GitHub
  2. See the Dynare manual om irf_plot_threshold`` . It's an option of stoch_simul`.