Our predictions for the 2019 Federal race in Toronto were generated by our agent-based model that uses demographic characteristics and results from previous elections. Now that the final results are available, we can see how our predictions performed at the Electoral District level.
For this analysis, we restrict the comparison to just the major parties, as they were the only parties for which we estimated vote share. We also only compare the actual results to the predictions of our base scenario. In the future, our work will focus much more on scenario planning to explain political campaigns.
We start by plotting the difference between the actual votes and the predicted votes at the party and district level.
Distribution of the difference between the predicted and actual proportion of votes for all parties
The mean absolute value of differences from the actual results is 5.3%. In addition, the median value of the differences is 1.28%, which means that we slightly overestimated support for parties. However, as the histogram shows, there is significant variation in this difference across districts. Our highest overestimation was 15.6% and lowest underestimation was -18.5%.
To better understand this variation, we can look at a plot of the geographical distribution of the differences. In this figure, we show each party separately to illuminate the geographical structure of the differences.
Geographical distribution of the difference between the predicted and actual proportion of votes by Electoral District and party
The overall distribution of differences doesnβt have a clear geographical bias. In some sense, this is good, as it shows our agent-based model isnβt systematically biased to any particular Electoral District.
However, our model does appear to generally overestimate NDP support while underestimating Liberal support. These slight biases are important indicators for us in recalibrating the model.
Overall, weβre very happy with an error distribution of around 5%. As described earlier, our primary objective is to explain political campaigns. Having accurate predictions is useful to this objective, but isnβt the primary concern. Rather, weβre much more interested in using the model that weβve built for exploring different scenarios and helping to design political campaigns.
I donβt remember being so organized on Wednesday πβ
Happy birthday to my favourite son!
Photosynthesis is a pretty elaborate game with more strategy than you might expect from trees βοΈπ²
There’s sure to be a good caper behind this busted safe in the middle of the woods
Happy birthday to my favourite daughter!
Lucy couldn’t quite manage the last burpee challenge in today’s One Academy Collision class
My favourite gym has a charity event on Saturday supporting Nellie’s Shelter for women & children. If you’re new to One Academy, your first class if free! So, a great chance to get a good workout & support an important cause
Iβm really enjoying these Biggest Ideas in the Universe videos from Sean Carroll. Sufficiently nerdy to be interesting without getting too detailed.
I’m neither an epidemiologist nor a medical doctor. So, no one wants to see my amateur disease modelling.
That said, I’ve complained in the past about Ontario’s open data practices. So, I was very impressed with the usefulness of the data the Province is providing for COVID: a straightforward csv file that is regularly updated from a stable URL.
Using the data is easy. Here’s an example of creating a table of daily counts and cumulative totals:
From there we can make some simple plots to get a sense of how the case load is changing.
And, I’ll leave it at that, at least for public posting π€
Appleβs Mobility Trends tool is intriguing. Curious to see that transit declines early, quickly, and the most. Makes sense, I suppose, given that transit users are in close proximity.
What is Real by Adam Becker is a great book on the measurement problem in quantum physics. Becker writes very clearly about the actual physics of the problem and the fascinating history. Such a clear example of how science is a human endeavour with politics and personalities ππ
Since I’m mostly stuck inside these days, I find I’m drinking more tea than usual. So, as a modification of my brew coffee shortcut, I’ve created a brew tea shortcut.
This one is slightly more complicated, since I want to do different things depending on if the tea is caffeinated or not.
We start by making this choice:
Then, if we choose caffeine, we log this to the Health app:
Uncaffeinated tea counts as water (at least for me):
And, then, regardless of the type of tea, we set a timer for 7 minutes:
Running this one requires more interactions with Siri, since she’ll ask which type we want. We can either reply by voice or by pressing the option we want on the screen.
A small change to my quarantine home office with large ergonomic impacts: I’ve added a Lamicall iPad stand. Much better and more flexible positioning of the iPad with this simple device.
I hadnβt expected to see gas below $1/L ever again π
I’ve been tracking my time at work for a while now, with the help of Toggl and Timery. Now that I’m working from home, work and home life are blending together, making it even more useful to track what I’m doing.
Physical exercise is essential to my sanity. So, I wanted to integrate my Apple Watch workouts into my time tracking. I thought I’d be able to leverage integration with the Health app through Shortcuts to add in workout times. Turns out you can’t access this kind of information and I had to take a more indirect route using the Automation features in Shortcuts.
I’ve setup two automations: one for when I start an Apple Watch workout and the other for when I stop the workout:
The starting automation just starts an entry in Timery:
The stopping automation, unsurprisingly, stops the running entry:
As with most of my Shortcuts, this is a simple one. Developing a portfolio of these simple automations is really helpful for optimizing my processes and freeing up time for my priorities.