Post-Covid interest rate analysis with Dynare

Hey,

I write my Bachelor Thesis about the interest rate after Covid (only ECB) and want to simulate the “best” interest rate according to my own model. Therefore I want to take the IS-Curve, the Philipps Curve and the Taylor rule. In addition I want to add two shocks (demand shock in 2020 and supply shock in 2022 because of the energy crisis).

I tried some simulations the last couple days on Dynare and I am slowly feeling comfortable with the program.
My question is: Can you give me some access to information material, a similar model or some hints how to simulate this? I had a lot of errors due to instability of the model (at least ChatGPT says that :slight_smile: ).

Thanks a lot in advance

Without a lot more details it is impossible to know what you are trying to achieve. Various resources are at Resources | Dynare

Hi jpfeifer,

I want to achieve a simulation of the optimal interest rate of the ECB between 2020 and 2024. Therefore I want to set up an easy New Keynesian Model with IS-Curve, Philipps-Curve, Taylor-Rule und Zero Lower Bound. In addition I want to simulate some exogenous shocks with realistic parameters (demand shock after covid-19 and supply shock because of the energy crisis).

I hope this helps to understand what I want to achieve.
Thanks in advance,
Lukas

One more thing to add. In the end, it would be nice to state something about how a different interest rate policy could have led to a different development of Inflation but also output.

A starting point then would be an NK model with OccBin:

/*
 * This file implements a New Keynesian model subject to the ELB on interest rates
 * and solves it using OccBin.
 */

%-------------------------------------------------------
% Variable declarations
%----------------------------------------------------------------
var 
    pie     ${\pi}$                 (long_name = 'Quarterly inflation rate')
    y       ${y}$                   (long_name = 'Output gap')
    inom    ${i}$                   (long_name = 'Observed nom. interest rate')
    inomnot ${i^{not}}$             (long_name = 'Notional nom. interest rate')
    zeps_a  ${\varepsilon_a}$       (long_name = 'Cost-push shock process')
    zeps_i  ${\varepsilon_i}$       (long_name = 'Monetary policy shock process')
    zeps_c  ${\varepsilon_c}$       (long_name = 'Demand shock process')   
    ;     

varexo 
    u_a   ${u_a}$   (long_name='Cost-push shock')
    u_i   ${u_i}$   (long_name='Monetary policy shock')
    u_c   ${u_c}$   (long_name='Demand shock')
    ;

parameters 
    betta   ${\beta}$       (long_name='Discount factor')
    eta     ${\eta}$        (long_name='Labour supply elasticity')
    ilb     ${i^{lb}}$      (long_name='ELB')
    sig     ${\sigma}$      (long_name='IES')
    theta   ${\theta}$      (long_name='Calvo parameter')
    phi_pi  ${\phi_{\pi}}$  (long_name='Inflation feedback Taylor Rule')
    phi_y   ${\phi_{y}}$    (long_name='Output feedback Taylor Rule')
    rho_a   ${\rho_a}$      (long_name='Autocorrelation cost-push shock')
    rho_c   ${\rho_c}$      (long_name='Autocorrelation demand shock')
    rho_i   ${\rho_{i}}$    (long_name='Autocorrelation monetary policy shock')
    rhoinom ${\rho_{inom}}$ (long_name='Interest-rate smoothing')
    ;   
%----------------------------------------------------------------
% Parametrization, some from p. 52 in Gali ch 3
%----------------------------------------------------------------
betta   = 0.995;
eta     = 1;
ilb     = -0.0055;
phi_pi  = 1.5;
phi_y   = 0.5/4;
rho_a   = 0.8;
rho_c   = 0.9;
rho_i   = 0.5;
rhoinom = 0.8;
sig     = 1;
theta   = 0.78;

model_local_variable kappa ${\kappa}$;

%----------------------------------------------------------------
% Model declaration
%----------------------------------------------------------------
model(linear);
 
#kappa = (sig+eta)*(1-theta)*(1-betta*theta)/theta;

[name='Phillips Curve']   
pie=betta*pie(+1)+kappa*y+zeps_a;

[name='IS curve']
y=y(+1)-1/sig*(inom-pie(+1))+zeps_c;

[name='Notional rate Taylor rule']
inomnot=rhoinom*inomnot(-1)+(1-rhoinom)*(phi_pi*pie+phi_y*y)+zeps_i;   

[name = 'Observed interest rate',relax='zlb']
inom = inomnot;

[name = 'Observed interest rate',bind='zlb']
inom = ilb;

[name='Law of motion for cost-push shocks']
zeps_a=rho_a*zeps_a(-1)+u_a;

[name='Law of motion for demand shocks']
zeps_c=rho_c*zeps_c(-1)+u_c;

[name='Law of motion for interest-rate shocks']
zeps_i=rho_i*zeps_i(-1)+u_i;

end;
 
%----------------------------------------------------------------
%  steady states: all 0 due to linear model (except obs)
%---------------------------------------------------------------
options_.TeX=1;

steady;
check;

%----------------------------------------------------------------
% Run Simulations
%----------------------------------------------------------------

occbin_constraints;
name 'zlb'; bind inomnot<=ilb; 
end;   


shockssequence = -0.01;

shocks(surprise);
    var u_c;
    periods 1;
    values(shockssequence);
end;

occbin_setup;

occbin_solver(simul_periods=20,simul_check_ahead_periods=50);
occbin_graph y inom inomnot pie;
occbin_write_regimes;
occbin.plot_regimes(oo_.occbin.simul.regime_history,M_,options_)