This project analyzes electric vehicle population size history data by county to track EV adoption trends, regional differences, and relationship patterns between different vehicle categories. The analysis provides insights into the growth and distribution of electric vehicles across different counties and states.
- Python 3.x - Core programming language
- Pandas - Data manipulation and analysis
- Matplotlib - Data visualization
- Seaborn - Enhanced data visualization
- NumPy - Numerical operations
The analysis uses the "Electric_Vehicle_Population_Size_History_By_County.csv" dataset, which contains historical data on electric vehicle populations across different counties and states. The dataset includes information on:
- Battery Electric Vehicles (BEVs)
- Plug-In Hybrid Electric Vehicles (PHEVs)
- Total Electric Vehicles
- Non-Electric Vehicles
- Total Vehicles
- Electric Vehicle Percentage
- Geographic information (County, State)
- Date information
- Vehicle primary use types
The project includes comprehensive data preprocessing steps:
- Data Exploration - Initial examination of data structure, statistics, and unique values
- Missing Value Handling - Removing records with missing critical information (County, State, Date)
- Data Integrity Checks - Verifying mathematical relationships (EV Total = BEVs + PHEVs, etc.)
- Data Standardization - Normalizing categorical values (state names, county names)
- Duplicate Removal - Identifying and removing duplicate records
- Outlier Detection - Using IQR method to identify potential outliers in numeric columns
The project investigates six key objectives:
- EV Growth Over Time - Tracking the trend of electric vehicle adoption over time
- EV Adoption by Region - Analyzing which counties and states have the highest EV adoption rates
- Correlation Analysis - Examining relationships between BEVs, PHEVs, and total EV counts
- Outlier Distribution - Visualizing outliers in electric vehicle percentage
- 100% EV Counties - Identifying regions with complete EV adoption
- Vehicle Use Analysis - Investigating the relationship between vehicle total and EV percentage by usage type
The project produces several insightful visualizations:
-
Bar Charts - Top counties and states by average EV percentage
-
Correlation Heatmap - Relationship strength between BEV, PHEV, and total EV counts
-
Scatter Plot - Relationship between total vehicles and EV percentage by primary use type
The analysis reveals:
- Temporal trends in EV adoption across the dataset period
- Geographic hotspots for electric vehicle adoption
- Strong correlations between different EV categories
- Outlier regions with unusually high or low EV percentages
- Counties with complete EV adoption
- Relationships between vehicle fleet size and electrification percentage by usage type
- Clone this repository - git clone https://github.com/Asmit03/Python-Project---ElectroTrend.git
- Ensure you have all required libraries installed:
pip install pandas seaborn matplotlib numpy
- Place the "Electric_Vehicle_Population_Size_History_By_County.csv" file in the "Same" directory
- Run the project.py script:
python project.py
- Implement predictive modeling to forecast future EV adoption rates
- Create interactive dashboards for more dynamic exploration
- Incorporate additional datasets for deeper analysis (e.g., charging infrastructure, economic indicators)
- Perform geographic clustering analysis to identify regional patterns
Contributions, issues, and feature requests are welcome. Feel free to check the issues page if you want to contribute.