Code

Below are various files containing code I've written. I cannot guarantee the accuracy of these files, but they should be useful examples for those looking to learn.

Python

Medium Scale HANK Model

This file codes up the medium scale New Keynesian model I used in A Systematic Analysis of NGDP Targeting as a heterogeneous agents model. I pull the household block from the sequence-space Jacobian toolbox of Auclert et al. (2021).

Canonical NK Model

This file codes up the canonical three-equation New Keynesian model (see Gali 2015 for example).

Non-Linear RANK Model

This file codes up a non-linear New Keynesian model with an equilibrium level of assets.

Dynare

Canonical NK Model

This file codes up the canonical three-equation New Keynesian model, but in Dynare instead of Python.