Giter VIP home page Giter VIP logo

pandemic's Introduction

Pandemic-ConsumptionResponse

This repository represents a complete software archive for the paper "Modeling the Consumption Response to the CARES Act" by Carroll, Crawley, Slacalek, and White (2020). This README file provides instructions for running our code on your own computer, as well as adjusting the para- meters of the model to produce alternate versions of the figures in the paper.

REPRODUCTION INSTRUCTIONS

  1. All of the code for the project is written in Python 3, and is intended to be run in an iPython graphical environment. Running the main script outside of iPython may cause unintended consequences when figures are created.

  2. The easiest way to get iPython running on your computer is to use the Anaconda distribution of Python, available for download at https://www.anaconda.com/distribution/

  3. The code for this project uses the Heterogeneous Agents Resources and toolKit (HARK) to solve and simulate our model. To install HARK, open a console (on Windows, use the Anaconda Prompt) and run pip install econ-ark. This will put HARK and all of its dependencies in your Python package library.

  4. All code files are in the ./Python subdirectory of this repository. If you've installed Anaconda, our code can be run in a graphical iPython environment by opening up the Spyder IDE.

  5. The main script for this project is GiveItAwayNowMAIN.py. You can run this file by clicking the green arrow "run" button in Spyder's toolbar. Text will print to screen as it completes various computational tasks. Most of these take about 1-2 minutes to run on a modern desktop. All figures are produced after running all counterfactual scenarios.

  6. All figures will be saved to the ./Figures subdirectory.

  7. All parameters can be adjusted in ./Python/Parameters.py, and are described below. Each parameter should have an in-line description to give you a pretty good sense of what it does.

STRUCTURAL PARAMETERS

  1. The parameters for the project are defined near the top of Parameters.py; they are divided into several blocks or types of parameters.

  2. The distribution of the intertemporal discount factor (beta) is defined by the parameters in the first block. For each education level, we specify the center of a uniform distribution; the half-width of the distribution is the same for all education levels (DiscFacSpread).

  3. The second block of parameters is the largest, concerning what happens when the pandemic strikes. This includes the marginal utility scaling factor during the "lockdown", the real and perceived duration of deep unemployment spells and the "lockdown", and coefficients for the logit probabilities of employment and deep employment (see paper appendix). It also includes a boolean to indicate whether the lifting of the lockdown should be simulated as an idiosyncratic event (as in the paper, to synthesize an average consumption path) or as a common event shared across all agents (to see what happens with a particular timing of the return to normalcy).

  4. The third parameter block specifies the terms of the fiscal stimulus package (CARES Act), in- cluding the timing of the stimulus checks relative to announcement, the size of the stimulus checks, the term of the income-based means testing, the size of additional unemployment benefits, and the proportion of the population who notices and reacts to the announement of the stimulus before the checks actually arrive in their bank account. Note that all values are specified in thousands of dollars, and the model is quarterly.

  5. The fourth parameter block includes basic model parameters like the population growth rate, aggregate productivity growth rate, and a description of "normal" unemployment (and benefits).

  6. The fifth parameter block specifies the initial distribution of permanent income for each edu- cation level and the share of the education levels in the population.

  7. The remaining parameters specify the density of the grid that the problem is solved on and the discretization of the income shocks (for computing expectations).

  8. Most parameters below the line of pound signs should not be adjusted, as they concern objects constructed from the primitive parameters defined above or basic features of the lifecycle (such as the number of periods in the problem). The number of periods simulated in the counterfactuals and the total number of simulated households can be safely changed.

pandemic's People

Contributors

llorracc avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.