This repository contains the code and analysis for evaluating a dataset related to the purchase and sale of used vehicles. The analysis includes calculating profit margins, evaluating inventory times, assessing market demand, and understanding buyer profiles. The goal is to derive actionable insights to aid in business decision-making.
The repository is structured into several directories, each corresponding to a specific objective of the analysis:
.
├── objective_analysis_1
│ ├── data
│ │ └── profit_by_brand_model.csv
│ ├── results
│ │ ├── profit_margin_by_brand_and_model_bar_chart.png
│ │ └── profit_by_brand_and_model_table.png
│ ├── scripts
│ │ ├── profit_and_profit_margin.py
│ │ └── profit_and_profit_margin_table.py
│ └── README.md
├── objective_analysis_2
│ ├── data
│ │ └── inventory_time_by_brand_model.csv
│ ├── results
│ │ ├── inventory_time_by_brand_and_model_bar_chart.png
│ │ └── inventory_time_by_brand_and_model_table.png
│ ├── scripts
│ │ ├── inventory_time_analysis.py
│ │ └── create_inventory_time_table.py
│ └── README.md
├── report.pdf
├── reporte.pdf
└── README.md
Goal: Calculate the average profit margin for each vehicle.
Methodology:
- Calculate the profit for each transaction by subtracting the purchase price from the sale price.
- Calculate the profit margin for each transaction.
- Calculate the average profit margin across all transactions.
- Identify brands and models with the highest profit margins.
Goal: Determine which vehicles have the shortest and longest average inventory times.
Methodology:
- Calculate the average inventory time for each brand and model.
- Identify which vehicles sell the fastest and which take the longest to sell.
-
Clone the repository:
git clone https://github.com/your-username/used-vehicle-sales-analysis.git
-
Create a Python virtual environment with the following Prerequisites:
- Python 3.12.0
- Pandas
- Matplotlib