User:Ralbegen/Opinion poll code

For the graph of UK general election opinion polls I maintain:



I have a csv of general election results called gen2019.csv that looks like this:

And a csv of polls called pollsafter2019.csv organised like this:

(The full csv as of time of writing, which should work with the end date in the below code, is at the bottom of this page)

The R code goes like this:

Please feel free to adapt the code for your own purposes! Just please note I'm not likely to be much help if you need technical assistance with it.

The full csv is here: