All Projects → NumEconCopenhagen → ConsumptionSavingNotebooks

NumEconCopenhagen / ConsumptionSavingNotebooks

Licence: MIT License
Jupyter Notebook examples of the ConSav package

Programming Languages

Jupyter Notebook
11667 projects
python
139335 projects - #7 most used programming language
TeX
3793 projects
C++
36643 projects - #6 most used programming language

Contains Jupyter Notebooks showcasing the ConSav package.

Getting Started

The main tool in the ConSav package is the ModelClass class with predefined methods for e.g. saving and loading. The main selling point is that it provides an easy interface to calling Python functions jit compilled with Numba, and C++ functions. Each concrete model inherits these methods and then adds methods for e.g. solving and simulating. To get started there are three options:

  1. The 00. DynamicProgramming/ folder contains a simple introduction to both dynamic programming and the ConSav package. In particular, the Your First Consumption-Saving Model notebook showcases the fundamentals of the ConSav package.
  2. The simplest full example is the canonical buffer-stock consumption model, see the BufferStockModel notebook.
  3. The DurableConsumptioModel notebook contains more advanced examples. Specifically, it implements the solution methods proposed in A Guide On Solving Non-Convex Consumption-Saving Models.

If you are new to Python then try out this online course, Introduction to programming and numerical analysis.

To get started:

  1. Install the EconModel package: pip install EconModel
  2. Install the ConSav package: pip install ConSav
  3. Clone or download this repository
  4. Open your notebook of choice

We recommend running the notebooks in JupyerLab. A set of guides on how to install Python and JupyterLab is available here.

Overview

The main folder are:

The repository EconModelNotebooks contains a number of examples on using the underlying model class.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].