A Colorado Board of Elections requested an audit for the local congressional election. The audit read the election data to organize and separate information into a readable format. This created two sections, candidates and counties. The election audit read the votes per category, the percentage out of all the votes, and the winners of both categories.
- Data Source: election_results.csv
- Software: Python 3.6.1, Visual Studio Code, 1.38.1
The analysis of the election shows there were 369,711 votes cast in the election.
The candidate results were: * Charles Casper Stockham received 23.0% of the votes and 85,213 votes * Diana DeGette received 73.8% of the votes and 272,892 votes * Raymon Anthony Doane received 3.1% of the votes and 11,606 votes
The County results were: * Jefferson received 38,855 votes. This is a total of 10.5% of all votes for the county. * Denver received 306,055 votes. This is a total of 82.8% of all votes for the county. * Arapahoe received 24,801 votes. This is a total of 6.7% of all votes for the county. * Denver has the largest number of votes.
Creating a text file with the processed information.
The output from the VS-Code terminal.
This script to be used for all upcoming elections. The code that is already set up can be easily modified for the use of all election data as it is designed to loop through and calculate the highest numbers or the most votes. It can be used as an easy summary of how an election went for safekeeping or even for analysis to be used in upcoming elections. The code is set up using a specific location, so it would be really simple to use it for any type of election.