EconPapers    
Economics at your fingertips  
 

Matlab, Python, Julia: What to Choose in Economics?

Chase Coleman (), Spencer Lyon (), Lilia Maliar () and Serguei Maliar
Additional contact information
Chase Coleman: New York University
Spencer Lyon: New York University
Lilia Maliar: CUNY Graduate Center and CEPR

Computational Economics, 2021, vol. 58, issue 4, No 13, 1263-1288

Abstract: Abstract We perform a comparison of Matlab, Python and Julia as programming languages to be used for implementing global nonlinear solution techniques. We consider two popular applications: a neoclassical growth model and a new Keynesian model. The goal of our analysis is twofold: First, it is aimed at helping researchers in economics choose the programming language that is best suited to their applications and, if needed, help them transit from one programming language to another. Second, our collections of routines can be viewed as a toolbox with a special emphasis on techniques for dealing with high dimensional economic problems. We provide the routines in the three languages for constructing random and quasi-random grids, low-cost monomial integration, various global solution methods, routines for checking the accuracy of the solutions as well as examples of parallelization. Our global solution methods are not only accurate but also fast. Solving a new Keynesian model with eight state variables only takes a few seconds, even in the presence of an active zero lower bound on nominal interest rates. This speed is important because it allows the model to be solved repeatedly as would be required for estimation.

Keywords: Toolkit; Dynamic model; New Keynesian model; Global nonlinear; Low discrepancy; Quasi Monte Carlo (search for similar items in EconPapers)
JEL-codes: C6 C61 C63 C68 E31 E52 (search for similar items in EconPapers)
Date: 2021
References: View references in EconPapers View complete reference list from CitEc
Citations: View citations in EconPapers (2)

Downloads: (external link)
http://link.springer.com/10.1007/s10614-020-09983-3 Abstract (text/html)
Access to the full text of the articles in this series is restricted.

Related works:
Working Paper: Matlab, Python, Julia: What to Choose in Economics? (2018) Downloads
This item may be available elsewhere in EconPapers: Search for items with the same title.

Export reference: BibTeX RIS (EndNote, ProCite, RefMan) HTML/Text

Persistent link: https://EconPapers.repec.org/RePEc:kap:compec:v:58:y:2021:i:4:d:10.1007_s10614-020-09983-3

Ordering information: This journal article can be ordered from
http://www.springer. ... ry/journal/10614/PS2

DOI: 10.1007/s10614-020-09983-3

Access Statistics for this article

Computational Economics is currently edited by Hans Amman

More articles in Computational Economics from Springer, Society for Computational Economics Contact information at EDIRC.
Bibliographic data for series maintained by Sonal Shukla () and Springer Nature Abstracting and Indexing ().

 
Page updated 2025-03-19
Handle: RePEc:kap:compec:v:58:y:2021:i:4:d:10.1007_s10614-020-09983-3