About gEcon

gEcon is a framework for developing and solving large scale dynamic (stochastic) & static general equilibrium models. It consists of model description language and an interface with a set of solvers in R.

Publicly available toolboxes used in RBC/DSGE modelling require users to derive the first order conditions (FOCs) and linearisation equations by pen & paper (e.g. Uhlig’s tool-kit) or at least require manual derivation of the FOCs (e.g. Dynare). Derivation of FOCs is also required by GAMS and GEMPACK — probably the two most popular frameworks used in CGE modelling. Owing to the development of an algorithm for automatic derivation of first order conditions and implementation of a comprehensive symbolic computations library, gEcon allows users to describe their models in terms of optimisation problems of agents. To authors' best knowledge there is no other publicly available framework for writing and solving DSGE & CGE models in this natural way. Writing models in terms of optimisation problems instead of the FOCs is far more natural to an economist, takes off the burden of tedious differentiation, and reduces the risk of making a mistake. gEcon allows users to focus on economic aspects of the model and makes it possible to design large-scale (100+ variables) models. To this end, gEcon provides template mechanism (similar to those found in CGE modelling packages), which allows to declare similar agents (differentiated by parameters only) in a single block. Additionally, gEcon can automatically produce a draft of LaTeX documentation for a model.

The model description language is simple and intuitive. Given optimisation problems, constraints and identities, computer derives the FOCs, steady state equations, and linearisation matrices automatically. Numerical solvers can be then employed to determine the steady state and approximate equilibrium laws of motion around it.

gEcon was initially developed (2012–2015) at the Department for Strategic Analyses at the Chancellery of the Prime Minister of the Republic of Poland as a part of a project aiming at construction of large scale DSGE & CGE models of the Polish economy. Since March 1, 2015 gEcon is no longer developed and maintained at the Chancellery of the Prime Minister, but it is still maintained and developed by its original authors.

About current release

Version 1.2.2

gEcon 1.2.2 was released on July 10, 2023. This is a patch that fixes the issues spotted in the release 1.2.1 and makes the package compatible with R 4.3.0.

gEcon 1.2.0 was released on September 8, 2019. It came with the following functionalities:

Please note that gEcon is NOT DISTRIBUTED THROUGH CRAN. You have to download the package file appropriate for your system, save it on your disk, and install gEcon package from this file.

Note on using gEcon in R(>=3.4.0)

From R version 3.4.0 on, JIT compilation of functions is enabled. This means that functions determining steady state/equilibrium and perturbation matrices are compiled by R before being invoked. For larger models, the compilation may take some time or can even make R freeze. If you encounter any problems running larger models, enable the option output R Rcpp. See the note in Language section of the Users' guide about the performance of JIT and C++ compilers and their outputs.

gEcon extensions

Two packages extending gEcon functionality (CGE calibration and DSGE model estimation) can be found under the gEcon.iosam and gEcon.estimation tabs.

Development team

gEcon is developed by Karol Podemski and Kaja Retkiewicz-Wijtiwiak.

Grzegorz Klima was the originator and lead developer of gEcon in years 2012–2018.

Contact

Please send bugs, comments, suggestions to: gEcon<DOT>maintenance<AT>gmail<DOT>com.

Please note that we are developing and maintaining gEcon in our spare time, so before asking any questions, please read the Users' guide (which can be found under the documentation tab).


The link to gEcon users forum was added in the links section.