A Colorado Board of Elections employee has given you the following tasks to complete the election audit of a recent local congressional election.
- Calculate the total number of votes cast.
- Get a complete list of candidates who received votes.
- Calculate the total number of votes each candidate received.
- Calculate the percentage of votes each candidate won.
-Data Source: election_results.csv -Software: Python 3.6.1, Visual Studio Code, 1.38.1
The analysis of the election show that:
- There were 369,711 votes cast in the election.
- The candidates were:
- Charles Casper Stockham
- Diana DeGette
- Raymon Anthony Doane
- The candidate results were:
- Charles Casper Stockham received 23.0% of the vote and 85,213 total votes.
- Diana DeGette received 73.8% of the vote and 272,892 total votes.
- Raymon Anthony Doane received 3.1% of the vote and 11,606 total votes.
- The winner of the election was:
- Diana DeGette, who received 73.8% of the vote and 272,892 total votes.
Additionally, the Colorado Board of Elections would like more information on voter turnout by county.
- Calculate the total number of votes cast.
- Get a complete list of counties where ballots were cast.
- Calculate the total number of votes cast in each county.
- Calculate the percentage of votes cast by each county.
The analysis of the election show that:
- There were 369,711 votes cast in the election.
- The counties were:
- Jefferson
- Denver
- Arapahoe
- The county results were:
- Jefferson cast 10.5% of the votes and 38,855 total votes.
- Denver cast 82.8% of the votes and 306,055 total votes.
- Arapahoe cast 6.7% of the votes and 24,801 total votes.
- The county with the largest voter turnout is:
- Denver which cast 82.8% of the votes and 306,055 total votes.