Purchase Prediction
—
04 / Methodology
How the Prediction Works
Customer Data
Age, Education, Income and Vehicle Ownership are collected using the same encoding as the original training dataset.
Logistic Regression Model
A binary classifier — trained with scikit-learn's LogisticRegression — computes a weighted score and converts it to a purchase probability.
Purchase Prediction
The customer is classified as a Potential Buyer or Not Immediate Buyer based on the model's decision threshold.
The model analyzes Age, Education, Income and Vehicle Ownership to classify customers into two groups: Potential Buyer or Not Immediate Buyer. Logistic Regression is used here specifically as a binary classification model — it does not output a raw quantity, it outputs the probability of belonging to the "purchase" class.
INPUT VARIABLES
- Age
- Education
- Income
- Vehicle Ownership
OUTPUT
- Potential Buyer
- Not Immediate Buyer
05 / Application
Business Use Cases
Targeted Marketing
Identify potential customers for targeted hybrid vehicle campaigns.
Customer Segmentation
Segment customers according to predicted purchase intent.
Sales Prioritization
Help sales teams prioritize customers classified as potential buyers.
Campaign Optimization
Use prediction results to improve marketing outreach.
06 / Model Information
Trained Model Details
Coefficients (Age: 0.7986, Education: 0.4508, Income: 0.7236, Vehicle Ownership: 1.0570, Intercept: −11.1288) and the 89.26% training accuracy shown above were computed by fitting scikit-learn's LogisticRegression on the actual uploaded training dataset (475 records) — no metric on this page is fabricated. Age and Education are collected as real-world values (age range, qualification) and converted to the dataset's coded bands (Age 1–5, Education 1–4) before scoring; Income is entered directly in Lacs, matching the scale the model was trained on. This demo evaluates the fitted equation directly in the browser; the same coefficients can be served from a persisted model file (joblib/pickle) behind a POST /predict FastAPI endpoint in production, as outlined in the README.