Higher order IRFs and comparing models

Hello everyone,

I have some questions related to IRF.

Q1: The first question regards IRFs of order>1. I found some posts indicating that if the order is higher than 1, what stoch_simul returns is a GIRF. The majority of them refer to an archived link about how IRFs are computed in dynare (here). However, I could only access a snapshot of this page from the beginning of 2024. Is this still the case? I searched the wiki on GitLab and did not find a respective page.

Q2: I want to compare the GIRFs of different models. Assuming that the answer for Q1 is yes, is relative_irf enough to make the GIRF comparables? In other words, the GIRF are expressing the same information (say, the effect of shock x is the % change in variable y in contrast with a contrafactual without shock)?

Thank you in advance for your help

  1. Yes, at higher order Dynare still generates generalized IRFs. We haven’t yet had the time to fully migrate the old wiki.
  2. What exactly to you want to compare? Usually, you don’t need relative_irf for comparisons across models. It’s more about making IRFs for shocks with different standard deviations within a model comparable.

Hi @jpfeifer I’ve tried searching the forums if there’s a way to implement the GIRFs you have in NKM.mod,

% GIRFs given states in 42 and shocks in 43
t0=42;
options_.occbin.irf.exo_names=M_.exo_names;
options_.occbin.irf.t0=t0;
% OccBin will plot IRFs in response to positive and negative realisations of shocks
oo_.occbin.irfs = occbin.irf(M_,oo_,options_);

var_list_ = {'c','n','y','pigap','inom','inomnot'};

% if you want to scale:
% options_occbin_.plot_irf.endo_scaling_factor = vars_irf(:,3);
options_.occbin.plot_irf.simulname = ['t0_' int2str(t0)];
options_.irf=40;
occbin.plot_irfs(M_,oo_.occbin.irfs,options_,var_list_);

but for non-OccBin estimation/smoother model files.

Is there an example .mod file for this?

You mean like DSGE_mod/RBC_state_dependent_GIRF/RBC_state_dependent_GIRF.mod at master · JohannesPfeifer/DSGE_mod · GitHub ?

Sort of. I want to generate GIRFs after model estimation (without OccBin). So something similar to the occbin.irf(); function just without the occbin call.