Org | |
Package | |
Testing |
OG-PHL is an overlapping-generations (OG) model that allows for dynamic general equilibrium analysis of fiscal policy for the Philippines. OG-PHL is built on the OG-Core framework. 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 at https://pslmodels.github.io/OG-Core and documentation of the specific Philippines calibration of the model will be available soon.
xcode-select —install
conda
package manager is up-to-date: conda update conda
.conda update anaconda
.conda env create -f environment.yml
. The process of creating the ogphl-dev
conda environment should not take more than five minutes.conda activate ogphl-dev
pip install -e .
./examples
python run_og_zaf.py
./examples/run_og_zaf.py
by modifying model parameters specified in the dictionary passed to the p.update_specifications()
calls../examples/OG-PHL_example_plots
./examples/ogphl_example_output.csv
./examples/OG-PHL-Example/OUTPUT_BASELINE/model_params.pkl
ogcore.execute.py
for items in the dictionary object in this pickle file./examples/OG-PHL-Example/OUTPUT_BASELINE/SS/SS_vars.pkl
ogcore.SS.py
for what is in the dictionary object in this pickle file./examples/OG-PHL-Example/OUTPUT_BASELINE/TPI/TPI_vars.pkl
ogcore.TPI.py
for what is in the dictionary object in this pickle file./examples/OUTPUT_REFORM
directory, which represent objects from the simulation of the reform policyNote that, depending on your machine, a full model run (solving for the full time path equilibrium for the baseline and reform policies) can take from 35 minutes to more than two hours of compute time.
If you run into errors running the example script, please open a new issue in the OG-PHL repo with a description of the issue and any relevant tracebacks you receive.
Once the package is installed, one can adjust parameters in the OG-Core Specifications
object using the Calibration
class as follows:
from ogcore.parameters import Specifications
from ogphl.calibrate import Calibration
p = Specifications()
c = Calibration(p)
updated_params = c.get_dict()
p.update_specifications({'initial_debt_ratio': updated_params['initial_debt_ratio']})
The organization of this repository will be changing rapidly, but the OG-PHL/examples/run_og_zaf.py
script will be kept up to date to run with the master branch of this repo.
The core maintainers of the OG-PHL repository are:
OG-PHL (Version #.#.#)[Source code], https://github.com/EAPD-DRB/OG-PHL