Tom MacWright


Washington, DC has a startling number of bus stops - in the view of the WMATA API, we have 11,316.

Daily Bus Supply

Anywhere from zero to four hundred buses are on the road at any moment. Gaps are mostly due to the wmataapiapi instance starting to sleep, but the falloff at midnight I think is WMATA shutting off tracking.

Buses flowing through the system.

Speed over time for the length of all routes.

x:routes / y:stops


I started to hack away at the problem by building wmataapiapi and hosting a testing instance on Heroku: a simple layer that tries to do a v2 API on top of what exists now: it’s faster, supports CORS, has no user limits, and transmutes some XML-encoded responses into JSON for simple client-side parsing.

Like other problems, I see this as having a small, blocking core. In this case, the official API isn’t very good, and that limits what you can do with it and more importantly imagine doing with it.

For a week and a half, I added and activated a history mode that dumped minutely bus positions to Amazon S3. The intent is to provide data for research, testing, and visualization. You can download this data to run similar analyses.

This is a bit of a diversion for me, an excuse to crack open another encapsulated complexity in life. Brandon Martin-Anderson, Erica Fischer, and David Alpert know more and think more about this kind of thing. Axis Maps also made a beautiful visualization in this vein.