PSLmodels / OG-Core

An overlapping generations model framework for evaluating fiscal policies.
https://pslmodels.github.io/OG-Core/
Creative Commons Zero v1.0 Universal
66 stars 114 forks source link
demographics fiscal-policy macroeconomic-model overlapping-generations psl-cataloged

OG-Core

Org PSL cataloged OS License: CCO-1.0 Jupyter Book Badge
Package Python 3.9 Python 3.10 Python 3.11 PyPI Latest Release PyPI Downloads Code style: black
Testing example event parameter example event parameter example event parameter Codecov

OG-Core is an overlapping-generations (OG) model core theory, logic, and solution method algorithms that allow for dynamic general equilibrium analysis of fiscal policy. OG-Core provides a general framework and is a dependency of several country-specific OG models, such as OG-USA and OG-UK. The model output includes changes in macroeconomic aggregates (GDP, investment, consumption), wages, interest rates, and the stream of tax revenues over time. Regularly updated documentation of the model theory--its output, and solution method--and the Python API is available here.

Disclaimer

The model is constantly under development, and model components could change significantly. The package will have released versions, which will be checked against existing code prior to release. Stay tuned for an upcoming release!

Using/contributing to OG-Core

There are two primary methods for installing and running OG-Core on your computer locally. The first and simplest method is to download the most recent ogcore Python package from the Python Package Index ([PyPI.org]()). A second option is to fork and clone the most recent version of OG-Core from its GitHub repository and create the conda environment for the ogcore package. We detail both of these methods below.

Installing and Running OG-Core from Python Package Index (PyPI.org)

Note that, depending on your machine, a full model run (solving for the full time path equilibrium for the baseline and reform policies) can take more than two hours of compute time.

If you run into errors running the example script, please open a new issue in the OG-Core repo with a description of the issue and any relevant tracebacks you receive.

The CSV output file ./ogcore_example_output.csv can be compared to the ./run_examples/expected_ogcore_example_output.csv file in the OG-Core repository to confirm that you are generating the expected output. The easiest way to do this is to copy the example-diffs and example-diffs.bat files from the OG-Core repository and use the sh example-diffs command (or example-diffs on Windows) from the run_examples directory. If you run into errors running the example script, please open a new issue in the OG-Core repo with a description of the issue and any relevant tracebacks you receive.

Installing and Running OG-Core from GitHub repository

Note that, depending on your machine, a full model run (solving for the full time path equilibrium for the baseline and reform policies) can take more than two hours of compute time.

If you run into errors running the example script, please open a new issue in the OG-Core repo with a description of the issue and any relevant tracebacks you receive.

The CSV output file ./run_examples/ogcore_example_output.csv can be compared to the ./run_examples/expected_ogcore_example_output.csv file that is checked into the repository to confirm that you are generating the expected output. The easiest way to do this is to use the sh example-diffs command (or example-diffs on Windows) from the run_examples directory. If you run into errors running the example script, please open a new issue in the OG-Core repo with a description of the issue and any relevant tracebacks you receive.

Core Maintainers

The core maintainers of the OG-Core repository are:

Citing OG-Core

OG-Core (Version #.#.#)[Source code], https://github.com/PSLmodels/OG-Core