Forecasting Elections Using Compartmental Models of Infection
Abstract
Keywords
MSC codes
Formats available
You can view the full content in the following formats:
Supplementary Material
Index of Supplementary Materials
Title of paper: Forecasting Elections using Compartmental Models of Infection
Authors: A. Volkening, D. F. Linder, M. A. Porter, and G. A. Rempala
File: SupplementaryText.pdf
Type: PDF
Contents: In section SM1 of the supplementary text, we include our original forecasts of the 2018 midterms that we posted on arXiv on 5 November 2018, prior to the elections. As noted in the main manuscript, after the election rush, we were able to use a smaller time step for our simulations. We also found a few data-handling errors in our original forecasts and we corrected these errors in the forecasts that we include in the main manuscript (importantly, our original forecasts and those in the main manuscript project the same candidates to win each race). We also provide a table (Table SM1) that summarizes our model treatment of each state race by election and year. In section SM2 of the supplementary text, we discuss alternative methods for judging forecast accuracy. In section SM3 of the supplementary text, we provide illustrations of our transmission and recovery parameters for the 2018 Senate election as examples; we also provide captions summarizing the code and data files that we include as supplementary materials.
File: datafile_Code_and_Demos.zip
Type: compressed file
Contents: This zipped folder contains all of the code that we developed to fit model parameters and simulate the model, as well as instructions for reproducing all of the quantitative measurements that we presented in the figures and tables in the main manuscript. In the zipped folder, the file readme.txt provides further details and instructions. In particular, the folder has 13 Excel documents with polling data that we collected for 2012, 2016, and 2018 from HuffPost Pollster (through the HuffPost Pollster API v2) and RealClearPolitics, as well as the demographic data from the U.S. Census Bureau and 247WallSt.com that we used to correlate state outcomes in our 2018 forecasts. We provide 3 main code files: (1) formattingPollData.m formats the poll data (averaging polls by month and combining state data into superstate data when appropriate); (2) parameterFitting.R fits parameters using the formatted poll data; and (3) electionModel.m simulates our models. For reproducibility, we also include code (reproduceTablesFigures.m) that produces all of the quantitative measurements in the manuscript and a text file (reproduceDataFiguresTables.txt) with instructions on how to use this code. Lastly, demo.txt and the subfolder DemoFiles provide details on how to run short code demonstrations and verify the output.
File: datafile_ModelParameters.xlsx
Type: Excel document
Contents: This is an Excel file with the the model parameters that we use in our final forecasts for the 2012, 2016, and 2018 races. We fit the parameters to polling data that we obtained from HuffPost Pollster (through the HuffPost Pollster API v2) and RealClearPolitics. Each page in the Excel worksheet has the parameters for a different election forecast. The pages appear in the following order: 2012 governor, 2012 Senate, 2012 president, 2016 governor, 2016 Senate, 2016 president, 2018 governor, and 2018 Senate. On a given page, each column has the transmission and turnover (i.e., loss) parameters for the indicated state. In all cases, the column first gives the parameters for Republican transmission, then gives the parameters for Democrat transmission, and finally gives the Republican and Democrat turnover parameters.
References
Information & Authors
Information
Published In

Copyright
History
Keywords
MSC codes
Authors
Funding Information
Funding Information
Metrics & Citations
Metrics
Citations
If you have the appropriate software installed, you can download article citation data to the citation manager of your choice. Simply select your manager software from the list below and click Download.
Cited By
There are no citations for this item