Skip to content

Repository files navigation

📊 VECTA: E-Commerce Customer Analytics & Sales Forecasting System

A full-stack Django web application that transforms raw e-commerce transaction data into actionable business insights through customer segmentation, market basket analysis, interactive dashboards, and AI-powered sales forecasting.

Python Django SQLite Bootstrap JavaScript


📌 Overview

This project is an AI-powered e-commerce analytics platform developed using Django and Python.

The system enables businesses to analyze customer purchasing behavior, identify valuable customer segments, discover frequently purchased product combinations, and forecast future sales using statistical time-series modeling.

The application combines traditional web development with data science techniques to support business decision-making through interactive dashboards and visual analytics.


🚀 Key Features

📈 Customer Analytics (RFM Analysis)

  • Customer segmentation using Recency, Frequency and Monetary (RFM) Analysis
  • Automatic customer classification
    • Champions
    • Loyal Customers
    • At Risk
    • Can't Lose Them
    • Needs Attention
    • Lost Customers
    • Recent Customers
  • Interactive charts and visualizations
  • Customer segment distribution
  • RFM Matrix visualization
  • Revenue insights

🛒 Order Analytics Dashboard

  • Total Orders
  • Total Revenue
  • Units Sold
  • Average Order Value
  • Top Selling Products
  • Revenue by Category
  • Revenue by Country
  • Order Status Distribution
  • Interactive charts

🛍️ Market Basket Analysis

Implemented the Apriori Algorithm from scratch without relying on built-in association rule libraries.

Features include:

  • Frequent Itemset Generation
  • Association Rule Mining
  • Support
  • Confidence
  • Lift
  • Configurable Minimum Support
  • Configurable Minimum Confidence
  • Rule Filtering

Used to discover products frequently purchased together for product recommendations and cross-selling.


📉 AI Sales Forecasting

Implemented an ARIMA-based forecasting engine for predicting future sales.

Features:

  • Automatic Stationarity Testing (ADF Test)
  • ARIMA Grid Search
  • Automatic Model Selection
  • Lowest AIC Selection
  • Historical vs Forecast Visualization
  • 95% Confidence Interval
  • Performance Evaluation

Evaluation Metrics

  • RMSE
  • MAPE
  • Forecast Accuracy
  • AIC

Current Model Performance

  • Forecast Accuracy: ~85%
  • ARIMA Order: (3,1,3)

💻 Technologies Used

Backend

  • Python
  • Django
  • Django ORM

Frontend

  • HTML5
  • CSS3
  • Bootstrap
  • JavaScript
  • Chart.js

Database

  • SQLite

Data Science & Machine Learning

  • Pandas
  • NumPy
  • Matplotlib
  • Statsmodels
  • mlxtend
  • Scikit-learn

Algorithms

  • RFM Analysis
  • Apriori Algorithm
  • Association Rule Mining
  • ARIMA Forecasting
  • Augmented Dickey-Fuller (ADF) Test
  • Grid Search Optimization

📸 Project Screenshots

Customer Analytics Dashboard

Customer Analytics


Order Analytics Dashboard

Order Analytics


Market Basket Analysis

Market Basket


ARIMA Sales Forecasting

Forecasting


📂 Project Structure

ecommerce_analytics/
│
├── analytics/
├── customers/
├── forecasting/
├── products/
├── reports/
├── sales/
├── static/
├── templates/
├── screenshots/
├── manage.py
├── requirements.txt
└── README.md

⚙ Installation

Clone the repository

git clone https://github.com/Paras51Kus/ecommerce-analytics.git

Move into the project

cd ecommerce-analytics

Create virtual environment

python -m venv myenv

Activate virtual environment

Windows

myenv\Scripts\activate

Install dependencies

pip install -r requirements.txt

Run migrations

python manage.py migrate

Start development server

python manage.py runserver

Open

http://127.0.0.1:8000/

📊 Dashboard Modules

✔ Customer Analytics

✔ Order Analytics

✔ Market Basket Analysis

✔ Sales Forecasting

✔ Interactive Charts

✔ Customer Segmentation

✔ Product Association Rules

✔ Forecast Performance Metrics


🎯 Business Benefits

  • Identify high-value customers
  • Improve customer retention strategies
  • Discover product associations
  • Increase cross-selling opportunities
  • Forecast future sales
  • Support inventory planning
  • Improve business decision making through analytics

🔮 Future Enhancements

  • Prophet Forecasting Model
  • LSTM Deep Learning Forecasting
  • Product Recommendation System
  • Real-time Analytics
  • Customer Lifetime Value Prediction
  • Sales Anomaly Detection
  • Power BI Integration
  • PostgreSQL Deployment
  • REST API Support

👨‍💻 Author

Paras Kumar Kushwaha

📧 Email: paraskushwaha891@gmail.com

💼 LinkedIn: https://www.linkedin.com/in/paras-kr-kushwaha-362131314/

🌐 GitHub: https://github.com/Paras51Kus


⭐ Support

If you found this project useful, consider giving it a ⭐ Star on GitHub.

About

A full-stack analytics platform that turns raw e-commerce transaction data into actionable business insights

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages