Empty Pipes

Isochrone Maps of Europe 20 May 2015

|

maps

javascript

d3.js

leaflet

|



Edit: Any time you see ‘train’ below, it should technically be public transport. The vast vast majority of the travel used to make these maps is by train, but a very small percentage may involve ferries or buses.



Below is a map showing how long one would expect to travel to any point in Europe starting in Vienna, using only trains and walking at a brisk rate of 5 min / kilometer.



Other Cities



Errata / Disclaimer

Everything is an estimate. Rounding errors abound. Don’t use this for anything but entertainment and curiosity. But you already know that.



Some data may be missing. There may be faster connections. If you find issues, please let me know and I’ll do my best to fix them. Thanks to cuicuit on reddit and @yorksranter for pointing out missing data for Paris and London! This data has been added.



Travel times to areas close to the coasts are prone to large errors. This is because travel times are calculated and interpolated on a grid. Points in the water are heavily penalized so if a city lies between points sampled on land and water, the interpolated time may be extraordinarily large. Thanks to @ChristianTanner for pointing this out for the very stark example of Dublin, where it appears that it takes 14 hours to travel from Dublin to Dublin.



Ireland and parts of Spain are not well represented due to missing data.



How it’s made, technically



I used the Swiss public transport API to get travel times to most other small-medium sized cities in Europe. Then I created a rectangle enclosing most of Europe (the borders of which can be seen in the maps for Stockholm, Helsinki and some of the Baltic countries), and divided it into a grid (200 x 200 points). For each point in this grid, I calculated the fastest way to get to it assuming that the distance between the any train station and that point can be walked at a rate of 5 minutes / kilometer. Any points on water were assigned a swimming rate of 100 minutes / kilometer in order to create dense contours at the coasts.

This grid was used as an input to conrec.js which created a set of contour lines. These lines were then plotted as a paths using d3.js on top of a leaflet.js layer using the Stamen maps tiles. These tiles were chosen because they provide tile sets containing the borders and labels which can be overlayed on top of the colored contour plot.

The legend is its own div positioned directly below the map. The color map is cubehelix, which provides a nice range from dark to light tones while providing intermediate colors to distinguish the different contours.

Background Information and Motivation

While browsing twitter, I recently came across this wonderful isochrone map of the travel times by train from Vienna to the surrounding region at the turn of the century. As happy resident of Vienna, an avowed admirer of trains, and an ardent afficionado of maps, that map strikes a strong chord with me not only for its historic cachet but for its clean design and aesthetic appeal. It conjured images of steam trains (were the trains in 1900 still running on steam?) chugging along between the imperial centers of Vienna and Budapest. It made me wonder about how people commuted from the train station to their final destination. It made me question my conception of how long it took to get from place to place. Most of all, however, it made me wonder what such a map would look like today.

Having toyed with the idea of plotting travel times by train in a previous post, the map at Alternative Transport, along with Beau Gunderson’s route times in Seattle, made me realize that contour lines are a much better way of presenting the information. Relying on shades of a color makes it difficult to distinguish difference between disparate points on the map as well as to convert to an absolute value. Questions such as “how much darker is point A than point B?” and “what actual time does a particular shade correspond to?” are resolved using the interactive maps (i.e. Vienna, Paris, London, Berlin), but these fail to provide the information at a mere glance. A map containing contour lines corresponding to the locations which can be reached in a particular amount of time provides a clear and concise comparison between the travel times to various locations as well as a concrete reference to the absolute time required to reach a particular point. An example of such a map, called an isochrone map, is provided for Vienna above.