Allen Tran

Twitter
LinkedIn
GitHub

Traffic Speeds by Zipcode

Dec 15, 2014

Finding a dataset of traffic speeds by zip code is a surprisingly hard thing to do. When I was working at the Census RDC at UCLA, I had plenty of time to spare while waiting out time on the cluster so I created my own. Time + many asynchronous requests + many rotating proxy servers.

The map below shows average travel speeds from all 32,000+ zip code tabulation areas. The average travel speed was calculated as the mean speed from trips to the nearest neighbors. All up, this used data from slightly less than 5 million trips.

I found nearest neighbors via grouping zip codes by geohash. Look up geohashing if this is unfamiliar, it'll save you from many Haversine calculations.