Tuesday, December 2, 2014

Position Change Charts

Inspired by an old Joe Saward post on lap charts I had a quick doodle around the notion of position change charts that plot the names of drivers against laps on just the laps where their position at the end of the lap was different to the position on the previous lap.
This chart shows just the position changes for each driver over the course of the race; the leftmost labels correspond to grid positions. The trick to reading this chart is to look left from a driver label to the previous occurrence if the same label: this position gives the position from which the change too place. The intervening gap is the length of time that driver held the position to the left. Emphasising pit stop laps though the use of italics, for example, would add further richness to this chart.

For a complete description of how to generate this chart using data from the ergast API, see the Wrangling F1 Data With R book.


  1. I think the thing that might be confusing is when the drivers switch which side of the line they're on (which I know is for space/clarity and for that I think it works). For example, Kobyashi at lap 42. The previous instance of his name is at ~ lap 38. And I presume he and Raikkonen switched positions. It's just hard to tell what's happened to Rosberg in the meantime because at lap 38 it's not clear whether he or Raikkonen is ahead of the other one.

  2. Agreed - you have to look left to see where the previous position was. I could draw a horizontal line from a label to the lap before the position change, essentially showing the number of laps a driver retained a particular position. But that goes back to being close to a tradition lapchart.

    What I intended to do - inspired by JS' lapcharts, was to cross lines to show position changes. So eg a line for KOB going (41,10) to (42,9) or whatever it is and one for RAI going (41,9) to (42,10). I need to wrangle the data a bit to be able to plot that though... so it'll have to wait for another day...;-)


There seem to be a few issues with posting comments. I think you need to preview your comment before you can submit it... Any problems, send me a message on twitter: @psychemedia