Flash forward sampling
Slowly but surely, I’ve managed to think a bit more about the elections model. Here, I’ve described how I included some prior information in my model to try and “discount” the evidence provided by the polls, to obtain estimates that may be more reasonable and less affected by the short-term shocks that may (over)influence people’s opinions.
However, I wasn’t entirely happy with the strategy I had used
So, first off, I think I’ve refined my priors and I did so by running the model simply through “forward sampling”
The red dots represent the “historical” averages over the past 3 general elections, which I used as a reference point. You could fiddle a bit more with the parameters of the distributions for
Interestingly, I can map these results and propagate the uncertainty to estimate the distribution of seats in Parliament (still with no data from the polls included), to produce the following graph.
Again, I think this picture is even more convincing than the analysis of the probabilities and I feel relatively confident with this. (But of course, one could replicate the whole analysis and try different specifications, which I have to some degree).
So it’s now time to include the data that are pouring in from the polls. In particular, I now have information collected over the past two weeks or so and I think in a fast-moving election such as this where opinions may be changed by a large number of “facts” and stories, it’s useful to “discount” the older data. There are many ways of doing this, more or less formally
Each observed poll gets rescaled as
With a discount rate
So, Conservatives with a median estimated number of seats of 379 (and a 95% interval estimate of 369-391, way above the line of 325 seats that are needed for a majority), Labour with 175 (163-185), Lib Dems with 25 (17-31), SNP with 49 (46-54), Green with 1 and Plaid Cymru with 3 (0-4).
I think this analysis is interesting because it is fairly easy to assess the uncertainty propagated through the model up to the actual quantity of interest (the seats won). Other pundits are being a lot less favourable to the Lib Dems, but I’m kind of happy of how my model works, especially after considering the prior analysis.
Plenty more fun to come