In this assignment, i have used the concepts of Python for analyzing analyze the financial records and vote counting process .
Both tasks present a real-world situation where the newly developed Python scripting skills come in handy. For this project i have created a main folder called Python-analysis and inside that there is two sub folders called PyBank and PyPoll and inside each folders i have created three subcategories a file called main.py, This will be the main script to run for each analysis. A Resources folder that contains the CSV files used. An Analysis folder that contains your text file that has the results from the analysis.
PyBank
In this, a Python script is used to analyze the financial records of the company's financial dataset called budget_data.csv. The dataset is composed of two columns: "Date" and "Profit/Losses".
A Python script is used to analyzes the records to calculate each of the following values:
The total number of months included in the dataset
The net total amount of "Profit/Losses" over the entire period
The changes in "Profit/Losses" over the entire period, and then the average of those changes
The greatest increase in profits (date and amount) over the entire period
The greatest decrease in profits (date and amount) over the entire period
THe output of the analysis is as follows:
PyPoll
In this, helping a small, rural town modernize its vote-counting process.
The data set given is the poll data called election_data.csv. The dataset is composed of three columns: "Voter ID", "County", and "Candidate". A Python script is ueds to analyzes the votes and calculates each of the following values:
The total number of votes cast
A complete list of candidates who received votes
The percentage of votes each candidate won
The total number of votes each candidate won
The winner of the election based on popular vote
The Output of the analysis is