Featured image

Creating Isochrones Using Alteryx & Tableau (Part 1)

by Chris Hutchinson on Jun 9, 2020

Isochrones are a way of visualising areas that are reachable within a certain journey time. Instead of a distance radius (i.e a circle), isochrones show areas that can actually be reached using the available transport network (e.g roads, paths, train lines etc.).

Here at TravelTime we’ve developed a macro in Alteryx that can generate these isochrones for any method of transport, including driving, public transport, walking, and cycling.

In Part 1 of this blog we’ll show you how to use Alteryx to get the data. In Part 2, we’ll then show how you can visualise these shapes using Tableau.

How to create your isochrones…

Download the TravelTime macros here, and then open up Alteryx.

The suite of TravelTime macros cover a range of different geospatial functionalities, but here we are just going to use two – the Geocoder macro and the Isochrones macro.

First we need the addresses for the two locations we want to create an isochrone around. We will then convert them into lat-long coordinates using the Geocoder macro so that they can be displayed on a map.

The Geocoder macro can run off either a file or a text input. In this case we want to connect to a file that contains these two addresses, like this:

We then use the Input Data tool to bring this file into Alteryx:

alteryx-traveltime-input data

We now need to turn these addresses into lat-long coordinates, so we connect the Geocoder macro from the TravelTime tab:

alteryx-traveltime-lat-long

The TravelTime macros work by connecting to an API, and so require an API key to run. If you have a TravelTime key, enter the details in the Credentials tab of the Geocoder macro. If you don’t have one, you can download a free test key here.

In the Configuration tab we select Office Postcode as the field in our data file that we want to convert to a lat-long, in the Basic tab we specify that the addresses are in the UK:

alteryx-traveltime-geocoder

alteryx-traveltime-configuration

We can add a Browse tool to each output anchor and run the workflow, just to check the results before we continue:

alteryx-traveltime-browse-tool

The score of 1 in both of the output rows indicates that each address has been located exactly, and we can see them displayed correctly on the map, so now we’re ready to create the isochrones.

We drag the Isochrones macro from the TravelTime tab onto the canvas, and again enter our API key details in the Credentials tab:

alteryx-traveltime-api-key-input

In the Configuration tab we match up the Longitude and Latitude fields, and set the Search Method to ‘Departing at’, as we want to calculate the area that is reachable within a certain time, leaving each office at 9am. We then enter 15 and 30 minutes as the Isochrone Time.

In the Basic tab we select just public transport, and an arrival time of 9am GMT today.

For now we leave the fields in the Advanced tab at their default values.

alteryx-traveltime-isochrone-config

We add another Browse tool to each output anchor and run the workflow.

The successful output browse tool now shows four isochrones, representing the reachable area for 15 minutes and 30 minutes by public transport, around each of the two offices respectively.

We can add a base map to ensure everything looks as expected. By selecting a particular row in the output table, we can highlight individual isochrones on the map.

alteryx-traveltime-basemap

In order to use these isochrones in other platforms such as Tableau, we need to export them as an ESRI Shapefile (.shp). To do this we add an Output Data tool to the workflow, select ESRI Shapefile as the file type, and select the Isochrone field as the Spatial Object Field.

alteryx-traveltime-export

Now when we run the workflow our isochrones will be saved as a shapefile for us to import into any other platform we might want to use.

To learn how you can visualise these isochrones in Tableau, please continue reading Part 2.

Geocoding and creating Isochrones are just two of the functionalities of the TravelTime macros for Alteryx. They can also be used for calculating large journey time matrices, A to B routing, and more.

To find out more about how these macros can help you make better business decisions with your data, please get in touch here.

Topics:
Tutorials Alteryx