top of page

Strava Heatmap

A data visualisation exercise using R

Screenshot 2023-02-14 at 16.41.00.png
York Void.png

Since 2014 I have been gathering data on myself in the form of Strava activities, mostly cycling and running GPS data. Strava offers a feature to it’s subscribers at the end of each year where they can see a ‘heatmap’ of their activities, showing how your activities are spread across your local area, your most commonly used routes or perhaps your favourite place to stop for a coffee. Not content with the nice interactive version Strava offers, I requested Strava send me a copy of all the GPS data I had uploaded to see if I could make my own version.

 

The data comes as individual .gpx files containing timestamped latitude, longitude and elevation data for the duration of each activity. The first challenge here was to extract the necessary data points from the .gpx file and convert it to a .csv file that can be read into R. Since I used this project to teach myself to use R, it took a fair amount of trial and error to select a good method to do this. I settled on using xpaths to extract the relevant data points and place them in a data frame before exporting each activity as a .csv file.

 

Once the data was in the correct format it was a case of using the ggplot toolkit to plot each activity, overlaid on the same axes. I deliberately chose a sparse theme for the visualisation rather than add any features that may help the viewer identify the map itself. Since I haven’t run down every street in York (yet), there are gaps in the map that you wouldn’t usually see and roads or paths strongly featured that wouldn’t usually be highlighted, making this a very personal map of where I live.

 

Data visualisation like this turns personal information in an abstract format, into readable and accessible knowledge. Strava is only one entity that collects data from its users on a daily basis, data that is (or should be) always available to users to access. Through this exercise I have found myself more and more interested in the idea that we have a whole wealth of information about ourselves that we aren’t always able to understand. The process of visualising this helps to transform information into knowledge. 

© 2023 by Sasha Blake. Proudly created with Wix.com

bottom of page