I spent a few hours last week working with the riding-by-riding data from the last Canadian election. I found lots I could write about. In fact, for a relatively small dataset (essentially 338 rows of 5 numbers each), it seemed like almost every angle I took on this data told me something I hadn’t known before. Sometimes this was putting a surprising number to well-known phenomenon (like Conservative dominance in Alberta), but other times it was an entirely new fact I hadn’t guessed. I’ve laid out just a few simple results below.

About half the effort of this was first finding the right data in the maze of Elections Canada’s website, and then converting it to a format that was simple to use. I have no idea why they had to make it so difficult, so I’ve left the data in this github repo along with all the code used to generate these results and visualizations in this post.