Quantitative Economics

by on September 4, 2013 at 6:14 am in Uncategorized | Permalink

Quantitative Economics is a new online text from John Stachurski and Thomas J. Sargent that looks phenomenal.

This website contains a sequence of lectures on economic modeling, focusing on the use of programming and computers for both problem solving and building intuition. The primary programming language used in the lecture series is Python, a general purpose, open source programming language with excellent scientific libraries.

…At this stage, the level of the lectures varies from advanced undergraduate to graduate, although we intend to add more elementary applications in the near future. The lectures are suitable for courses in quantitative methods and computational techniques, and also for self study and independent study groups. To aid self study, all exercises have solutions. Our solutions are not the last word on each exercise — instead they provide one approach that demonstrates good coding practices

If you work through the majority of the course and do the exercises, you will learn

  • how to analyze a number of fundamental economic problems, from job search and neighborhood selection to optimal fiscal policy
  • the core of the Python programming language, including the main scientific libraries
  • good programming style
  • how to work with modern software development tools such as debuggers and version control
  • a number of mathematical topics central to economic modeling, such as
  1. dynamic programming
  2. finite and continuous Markov chains
  3. filtering and state space models
  4. Fourier transforms and spectral analysis

I recommend you take the advanced undergraduate bit with a grain of salt.

Hat tip: Nathan Palmer.

Richard September 4, 2013 at 6:51 am

When you say with a grain of salt, in which direction are you leaning? Is this more graduate level or 101?

dearieme September 4, 2013 at 7:24 am

1. Dynamic programming, 2. finite and continuous Markov chains, 3. filtering and state space models, 4. Fourier transforms and spectral analysis: golly, a reminder of things I once knew about.

Mind you, I learnt useful amounts about (1) and (4) as an undergraduate. But then, long ago, educational standards were higher.

Andrew' September 4, 2013 at 8:40 am

Does “dynamic programming” involve a treadmill desk and a feather boa?

RF September 4, 2013 at 9:15 am

I just graduated and I learned decent amounts of 1, 2, and 4 (and briefly touched on 3) in my undergraduate education (econ/stat).

Vladimir September 4, 2013 at 10:46 am

Most of this is high school material in any decent European country.

Newerspeak September 4, 2013 at 12:00 pm

Yeah, I was doing Fourier analysis before Ptolemy made it cool.

mike September 4, 2013 at 12:39 pm

In South Korea, they teach all this in kindergarten.

Rahul September 5, 2013 at 4:08 am

LOL.

Yeah, I want to go to a high school that teaches Markov chains.

Ryan September 4, 2013 at 8:03 am

There are plenty of econ undergrads who could handle this stuff, e.g., https://economics.byu.edu/Pages/MacroLab/Boot-Camp.aspx

Ronald Coase September 4, 2013 at 8:11 am

meh

An Economist September 6, 2013 at 6:44 pm

RIP

AndrewL September 4, 2013 at 8:43 am

I’d say this “textbook” is closer to graduate level than undergraduate level. You need at least a semester of undergrad vector calc to understand the concepts which are just throw at you with little to no explanation. For example, the Markov chains are presented without much explanation beyond “because theorem”.

CBBB September 4, 2013 at 9:09 am

It’s defintietly a graduate level text – I covered topics like Dynamic Programming, Fourier, and Markov chains in my undergraduate (not the stuff about Kalmen filters though) but even so in this ‘textbook’ the authors just sort of throw things at the reader expecting people to instantly be able to recall/know all the background math. There really isn’t much useful explanation for anything that I can see in this book, if you wanted to read it you would FIRST need to go get a bunch of other textbooks that covered a lot of the background material in more depth – and even then I’m not sure how much value this book adds. I agree with Andrew’ below, this is a vanity project.

Andrew' September 4, 2013 at 10:20 am

I mean something very specific. Impressing your colleagues by incentivizing the production of textbooks whose techniques are needed by 1% of the 1% of 1% and only then to impress your colleagues is what we do. Why do we do that?

RF September 4, 2013 at 11:35 am

You make it sound like these are niche techniques. Dynamic programming is as standard as it gets in macro, Markov chains are incredibly useful in all kinds of different fields, Kalman filters are standard in finance (and again, dozens of other fields), and Fourier transformations/spectral analysis is also standard time series stuff (though I haven’t seen much economics work in the spectral domain).

The niche this textbook seems to try to fill is actually learning how to apply these methods using Python, a skill that I think is increasingly important. It’s not for people who need to learn the math, it’s for people who know the math but don’t know how they might actually implement it computationally.

Andrew' September 4, 2013 at 12:09 pm

“it’s for people who know the math but don’t know how they might actually implement it computationally. ”

To me this says that we are not as far apart as we may think.

FC September 6, 2013 at 1:58 am

Because chicks dig a man with math skills.

RF September 4, 2013 at 9:18 am

To me, “advanced undergrad to graduate” usually means that a fourth (or maybe third) year on an advanced track (often with a PhD as a goal) could handle the class. From a cursory glance that seems about right for the textbook, though you probably need to take a fairly specific curriculum to feel comfortable.

Andrew' September 4, 2013 at 8:47 am

Wonderful. Now we have vanity textbooks.

cw September 4, 2013 at 9:54 am
Andrew' September 4, 2013 at 10:55 am

Yes and no for what I mean. No in that it sounds like that book is helpful. Yes in that how many people are really doing macroeconomics, not to mention are they doing us any good?

Per the comment below, I’m now of the opinion we create different departments so that professors can borrow from outside their discipline to impress those within their discipline. Maybe this is progress. I wish I could quantify how many of the products we use actually depend on this RCH-pecision math, but I don’t have the math skills.

dbeach September 4, 2013 at 4:05 pm

How is that a vanity textbook? That (well, an earlier edition, obviously) was my macro textbook as an undergrad. My understanding is it’s one of the most widely used macro textbooks.

VRN September 4, 2013 at 9:20 am

The material appears to be more Electrical Engineering (Systems) than Econ.

NPW September 4, 2013 at 9:27 am

I was thinking that most of the underlining math was part of my coursework as an undergrad EE.

Mike September 4, 2013 at 11:21 pm

There’s a reason that Physics undergrads make great Econ grad students.

Eric Falkenstein September 4, 2013 at 9:23 am

Economists can model optimal fiscal policy? Don’t keep it a secret, what is it!?

Ricardo September 4, 2013 at 9:32 am

Here is a book that covers similar territory, but at a somewhat easier level. Here is a dissertation that uses Python to model public choice. Python FTW!

tt September 4, 2013 at 11:08 am

so you haven’t been quantitative before ? maybe thats the problem with economics.

cw September 4, 2013 at 3:33 pm

See above:

Ronald Coase September 4, 2013 at 8:11 am
meh

AngryAnalyst September 4, 2013 at 11:27 am

I glanced at it, it strikes that the most of it should be comprehensible to undergrads with strong math backgrounds.

John Voorheis September 4, 2013 at 2:41 pm

Starchurski has had most of these lectures on his website since 2009, as an appendix to his Macro/Computational textbook (which is good!) I’m not sure what Sargent is adding to this, but if it gets more macro people using Python, I’m for it.

John H September 4, 2013 at 3:50 pm

They should cut out the python and scientific libraries introductions and put that out as a separate document. That part of it looks very well done, though it might be even better if they added some more advanced python stuff, like parallel processing or incorporating C code or other ways to speed things up.

Hein September 5, 2013 at 1:00 am

They do recommend installing a Python package, specifically Anaconda. Anaconda comes with many modules, and Cython is one of them. I (obviously) have only glanced at the introduction of this text (having read about it today), but they did reference early on Python’s processing limitations and there is a section in “About Python” that is entitled “interfacing with C and Fortran” to speed up your code in cases when necessary.

As a side note, because this is a comment discussing a programming language on an economics blog, I highly recommend the video entitled “The economy of programming languages” on Coursera’s Compilers course.

Found here:

https://class.coursera.org/compilers/lecture/index

Hein September 5, 2013 at 1:09 am

I have only read the introductory chapters, but they do recommend installing a Python package, Anaconda, which includes Cython (for incorporating C). Also in “About Python” there is a section entitled “Interfacing with C or Fortran”. Maybe there is more to come in the text, but regardless, they point out this is something important to learn.

Rahul September 5, 2013 at 4:10 am

Isn’t parallel processing out of place? What fraction of even professional Economists use parallel processing?!

Finch September 5, 2013 at 2:44 pm

A pretty small fraction since so many are stuck using old-fashioned tools like SAS that make it very hard to do. Since much of the “professional” economics being done involves pulling 10,000 samples of something and regressions or simulations, it would be helped a great deal by modern tools.

But I think the really big win would come from modern version control and debuggers.

Comments on this entry are closed.

Previous post:

Next post: