Skip to content

abdulla971/Election_Analysis

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Election_Analysis

Project Overview

In this project an election audit for the Colorado Board of Elections was provided. The following tasks were performed:

  1. Calculate the total number of votes casted.
  2. Get a complete list of candidates who received votes.
  3. Get the county who had the highest voter turnout.
  4. Calculate the total number of votes each candidate received.
  5. Calculate the percentage of votes each candidate won.
  6. Determine the winner of the election based on popular vote.

Resources

Data Source: election_results.csv Software: Python 3.8.8, Visual Studio Code 1.56.2

Results

The election analysis shows:

  • A total of 379,111 votes were casted in the election.

    • The candidates in the election were:
    • Charles Casper Stockham
    • Diana DeGette
    • Raymon Anthony Doane
  • The candidate results were:

    • 23.0% of total votes went to Charles Casper Stockham with 85,213 votes.
    • 73.8% of total votes went to Diana DeGette with 272,892 votes
    • 3.1% of total votes went to Raymon Anthony Doane with 11,606 votes
    • Thus, a total of 369,711 votes.
  • The winner of the election was:

    • Based on the number of votes received Charles Casper Stockham was the winner of the election with 73.8% of total votes which equates to 272,892 votes.
  • The counties results:

    • 10.5% of the total votes went to Jefferson county with 38,855 votes.
    • 82.8% of total votes went to Denver county with 306,055 votes.
    • 6.7% of the total votes went to Arapahoe county with 24,801 votes.
    • Again, total votes equal 369,711.
  • We observe that the largest county with the most votes was Denver county with 306,055 votes.

Here is an image of the results:

Challenge Summary

This challenge provided deep understanding of the use of python and studied the case of casting votes for elections. The script can be used in the future by campaign manager for instance for a candidate. For example we might be interested in looking and applying this to cities rather than just counties thus increasing the data we have and accuracy. In this example, we could look at which major cities have more influence on the election result and based on that the candidates could focus primarily on those cities. This could be possible, first we would need to gather more data and input it into our election_results.csv file to be able to work on it. Furthermore we could possibly study the demographics of the candidates things such as their age and ethnicity as this allows us to target the proper group and secure more votes. These examples show how we can use the scrip in this module challenge to be able to have a better chance at winning the elections!

About

No description or website provided.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Languages