Solve nonlinear perfect foresight models with heterogeneous agents
Project description
Solve nonlinear heterogeneous agent models using automatic differentiation
Econpizza is a framework to solve and simulate fully nonlinear perfect foresight models, with or without heterogeneous agents. The package implements the solution method proposed in Robust Nonlinear Transition Dynamics in HANK (Gregor Boehl, 2023). It allows to specify and solve nonlinear macroeconomic models quickly in a simple, high-level fashion. Generic and robust routines for steady state search are provided.
The package can solve nonlinear models with heterogeneous agents, such as HANK models with one or two assets and portfolio choice. Steady state and nonlinear impulse responses (including, e.g., the ELB) can typically be found within a few seconds. The method extends the Sequence-Space Jacobian method (Auclert et al., 2022, ECMA) to fully nonlinear heterogeneous agent models models by iteratively using Jacobian-vector producs to approximate the solution to the linear system of equations associated with each Newton iteration. This not only allows to study the dynamics of aggregate variables, but also the complete nonlinear transition dynamics of the cross-sectional distribution of assets and disaggregated objects.
To solve models with representative agents a shooting methods similar to Laffargue (1990), Boucekkine (1995) and Juillard (1996) is implemented. It is faster and more reliable than the extended path method in dynare due to the use of automatic differentiation for the efficient jacobian decompositions during each Newton-step. Nonlinear perfect-foresight transition dynamics can - even for large-scale nonlinear models with several occassionally binding constraints - be computed in less than a second.
The package builds heavily on automatic differentiation via JAX.
Documentation
Guides and tutorials are provided on ReadTheDocs:
Citation
@Misc{boehl2022pizza,
title = {Robust Nonlinear Transition Dynamics in HANK},
author = {Boehl, Gregor},
howpublished = {\url{https://gregorboehl.com/live/hank_speed_boehl.pdf}},
year = {2023}
}
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file econpizza-0.5.3.tar.gz
.
File metadata
- Download URL: econpizza-0.5.3.tar.gz
- Upload date:
- Size: 942.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.10.10
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3a4c0d49c7f05a6870d74b8b4977dc2583be3a8af9fa00662b66d1c154726157 |
|
MD5 | 25152cccd3e7ceb0b9f00d78eddb469e |
|
BLAKE2b-256 | 495eccedf1eebbca13f8ff4697a4755f645d82c6974195fffcfd7901e988e571 |
Provenance
File details
Details for the file econpizza-0.5.3-py3-none-any.whl
.
File metadata
- Download URL: econpizza-0.5.3-py3-none-any.whl
- Upload date:
- Size: 74.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.10.10
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | d2165958f858969baff58839a64a7622e28048112accfc95dbd1725ca5a5db39 |
|
MD5 | 6fb6c9f25d80872aa93f6c545e8ce028 |
|
BLAKE2b-256 | 4b1b4a2bc5c68299e9693dc298150fcd786455d9cd6c2ea4b1c4d42e1f78679d |