Yesterday marked day 2 of dashboard week, and given it was Melbourne Cup day, it was hardly surprising to find out that our task was to create a Melbourne Cup themed dashboard. We were given the option to scrape our data from various websites that contained information about the race. I chose to use Sportsbet, because it provided the most detailed information about each horse and their history.

Prepping The Data

This wasn’t a simple webscraping exercise in Alteryx, because not all of the data was available to us via the download tool. To get around this issue, we had to use a Python script, which was provided to us by Alekh from DSAU2. Once I got this far, it became a RegEx exercise. The main thing to note from this was making sure the output method was set to tokenize and split to rows. I repeated this process several times to get the fields that I wanted, and then joined it all together using record position, because the data always came through in the same order. I also scraped data from Wikipedia, which contained details about past winners of the race. Here is my workflow:

Building The Dashboard

When it came to building my dashboard, I wanted to incorporate this year’s race data with the past winners data. As such, I decided my dashboard would be based around past trends and how all the horses compare in those metrics. The first part of my view compares the win odds of all the horses, and I have added a parameter to give the user the ability to sort by either win odds, barrier number or win %. There is also a parameter which allows you to choose how the horses are coloured (either by past winner, past placer or past runner). The right-hand side of my view looks at past winners based on barrier number and win odds. I have used bins in both cases – the sizes of which can be adjusted via a parameter – to aid clarity. Here is an image of my dashboard, which you can click to view it in Tableau Public with full interactivity.

What I Learned

I learned a lot of technical skills in Alteryx, the most important one being how to use the tokenize output method in RegEx. In the past, I have predominantly used the parse output method, so it was nice to broaden my RegEx repertoire. On a more granular level, I discovered the power of the ‘?’ function in RegEx. It looks for the first case of a given pattern, and will undoubtedly save me time in the future. Finally, I also added some new tools to my arsenal, including Make Columns and Tile. Thanks to Alekh once again for sharing all these tips!

Come back tomorrow to see my next dashboard, and click here to see what I created on day 1.