-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathREADME.txt
More file actions
55 lines (42 loc) · 3.15 KB
/
README.txt
File metadata and controls
55 lines (42 loc) · 3.15 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
# python-challenge
**Repository Name:** python-challenge
**Description:**
The Python Challenge repository contains solutions to two ('Module 3 Challenge') Python challenges: PyBank and PyPoll. Both challenges simulate real-world scenarios where Python scripting skills are crucial for data analysis and automation tasks.
**Project Structure:**
- **PyBank:**
- **main.py:** Python script for analyzing financial data.
- **Resources:** Folder containing the financial dataset (`budget_data.csv`).
- **Analysis:** Folder containing the analysis results text file (`budget_analysis.txt`).
- **PyPoll:**
- **main.py:** Python script for analyzing poll data.
- **Resources:** Folder containing the poll dataset (`election_data.csv`).
- **Analysis:** Folder containing the analysis results text file (`election_analysis.txt`).
**Instructions:**
Before running the scripts, follow these steps:
1. **Clone Repository:** Clone this repository to your local machine using `git clone`.
2. **Navigate to Repository:** Open your terminal and navigate to the cloned repository directory.
3. **Run Scripts:** Run each script separately by executing `python main.py` within the respective project directories (`PyBank` and `PyPoll`).
4. **Verify Results:** Check the analysis results in the corresponding `Analysis` folders.
**Project Overview:**
- **PyBank:**
- Analyzes financial data to calculate total months, net total profit/loss, average change, and identifies the greatest increase and decrease in profits.
- Utilizes Python's `csv` module for reading CSV files and handles data using variables, lists, and dictionaries.
- **PyPoll:**
- Modernizes a small, rural town's vote-counting process by analyzing poll data.
- Calculates total votes cast, lists of candidates who received votes, percentages of votes each candidate won, and determines the winner of the election based on popular vote.
- Utilizes Python's file handling capabilities and data structures like lists and dictionaries.
**Considerations:**
- Use the `csv` module to handle CSV files effectively.
- Employ variables, lists, and dictionaries to store and manipulate data.
- Break down tasks into smaller objectives for efficient problem-solving.
- Debug code as needed to identify and fix errors.
- Ensure correct file paths for loading datasets and outputting analysis results.
**Backup and Version Control:**
- Regularly commit your work to maintain version history and back it up by pushing changes to GitHub.
**Additional Notes:**
- Each script operates independently, analyzing its respective dataset.
- Remember to review the `README.md` file within each project folder for specific instructions and details.
**Code Source:** The Python script development process heavily utilized the Xpert Learning Assistant platform, leveraging its vast knowledge base and interactive capabilities. Additionally, some cross-comparisons were made with ' ChatGPT to address specific challenges encountered during script development.
**Contact Information:**
If you have any questions, suggestions, or encounter issues, feel free to reach out to me via email at ngalakevin@gmail.com.
Thank you for exploring my Python Challenge repository!