Skip to content

A tutorial on creating animations using your Strava data.

Notifications You must be signed in to change notification settings

beckigreen/strava-animations

Repository files navigation

Creating Strava animations using rStrava and gganimate 🏊 🚲 🏃

If you want to explore more of the functionalities within the rStrava package, I recommend referring to the comprehensive rStrava documentation and this handy blog by one of the creators.

This project uses functions within the rStrava package and gganimate/ggplot2 to animate rides sequentially, and incorporates some design features using ggtext and ggimage.

Getting started


There are a couple of set up steps, which take ~30-60 minutes:

1. Strava account and API application - this allows you to generate an authentication token and pull your data from Strava.

  • If you do not have an account already, set up a Strava account and record some activities
  • Navigate to profile settings ➡ 'My API Application' ➡ 'Create an application'
  • Note your application name, client id, and client secret as you will need these when running the script
  • You will also need to know your athlete id, located at the end of your Strava URL.

2. Google API key in Maps Elevation API - this allows you to generate longitude and latitude data, download maps for ggmap, and calculate elevation data if needed.

  • To create a project, click on the following link ➡ 'Credentials' ➡ 'Create project'
  • After the project is created, click on 'Create Credentials' ➡ 'API key'
  • Note your API key as you will need this when running the script
  • Next, navigate to 'Library' in the left hand tab, and search for 'Maps Elevation API' in the API Library.
  • Click 'Enable'.

Kudos 👍

About

A tutorial on creating animations using your Strava data.

Topics

Resources

Stars

Watchers

Forks

Languages