# Formula E Standings – MakeoverMonday

This week dataset for #makeovermonday was about Formula E races. As a fan of Formula 1, and fan of Formula 1 broadcasting, I’ve loved the opportunity to play with data and give my view on how the data should be visualized for both fans and drivers.

And for that I had to do some nice work to calculate all the information I believe are relevant for these audiences.

1 – The total of points: Formula 1 or Formula E are mostly competition of Drivers. Each Driver has fans; each driver is a soccer team, analogically speaking. So I focused on bringing what matter the most, the total points of each driver in the competition. For that I had to create a calculations for Points per Race, Points per Pole and Points for the Fastest Lap.

a) Points per Race: each position at end of a race give drivers a specific amount of points. The 10 first drivers get points and the calculated field is pretty straight forward:

IF [Rank] =1 AND [Results type] = “Race Results” THEN 25
ELSEIF [Rank] = 2 AND [Results type] = “Race Results” THEN 18
ELSEIF [Rank] = 3 AND [Results type] = “Race Results” THEN 15
ELSEIF [Rank] = 4 AND [Results type] = “Race Results” THEN 12
ELSEIF [Rank] = 5 AND [Results type] = “Race Results” THEN 10
ELSEIF [Rank] = 6 AND [Results type] = “Race Results” THEN 8
ELSEIF [Rank] = 7 AND [Results type] = “Race Results” THEN 6
ELSEIF [Rank] = 8 AND [Results type] = “Race Results” THEN 4
ELSEIF [Rank] = 9 AND [Results type] = “Race Results” THEN 2
ELSEIF [Rank] = 10 AND [Results type] = “Race Results” THEN 1
ELSE 0
END

Translation to humans: Hey Tableau, check the rank for these values, and check if these are race results rankings, and convert them to these value or points. Thanks mate!

b) Points per Pole: in Formula E the Super Pole winner also gets points (3). So here is the calculation:

IF [Rank] = 1 AND [Results type] = “Super Pole Results” THEN 3
ELSE 0
END

Translation to humans: Hey Tableau, this time only get the winners (rank 1) for the super pole and give them 3 points, ok?

c) Points per Fast Lap: well this is NOT that straight forward at all to calculate. First I had to calculate the duration of the Best Time field (which is in minutes:seconds format) so here is what I had to do:

• Split the Best time field to get the minutes and the seconds in separate fields
• Convert 1 minute to 60 seconds, 2 minutes to 120 seconds
• Sum up these seconds with the seconds from the original split
• Result: duration of each lap in seconds
• Then Mark Bradbourne mastery helped me with this LOD calculation to get the MIN value for each driver, for each race of each season and compare with the MIN of the each race of each season (ufff) :

IF
{FIXED [Season],[Round],[Driver] : MIN([Lap Duration])}
=
{FIXED [Season],[Round] : MIN ([Lap Duration])} THEN 1
ELSE 0
END

Translation to humans: Tableau pay attention, compare the minimum time for each driver, for each season and for each race, against the minimum time of the each race for each season, whenever you find that these values are the same, give that driver 1 point, please!

d) Summing all the points: The easiest calculated field ever:

[Race Points]+[Pole Points]+[Fast Lap Points]

e) Points per race: As I also wanted the total of points per each race I had to build a LOD calculations to get this level of detail that I wanted in the view:

{FIXED [Driver],[Season] : SUM([Total Points])}

Translate to humans: Tableau… budy… bring me the total of points for each driver in each season.

Once I got all these calculations together building the viz was straight forward. Just a sparkline where each point is a driver/race combination. Drivers are sorted to show the Champion at the top. And all in only one sheet!

Note: At the last moment I also added a red dot point to the timeline to clearly mark who won each race. Fans and Drivers only care about race winners, champions. So these really need an extra highlight on the viz.

Note 2: I designed the Tooltip inspired by the pitwall information board that teams give to drivers every lap.

Note 3: Andy, I feel you would like the dataset a bit more if you just imagine drivers as marathons runners 😉 That would make more sense for you I think.