SMART ANALYTICS: MACHINE LEARNING TECHNIQUES FOR ASSESSING
USED CAR PRICES
a
P. Annamalai, bE. Bharanidharan, cJ. V. Balaji
1
Dr.V. Ramesh Babu, 2Dr.R. Shoba Rani, 3Dr.M. Manikandan
a,b,c
Students, 1,2,3Professor
a,b,c,1,2,3
Department of Computer Science and Engineering,
a,b,c,1,2,3
Dr. M.G.R Educational and Research Institute, Chennai, India
Email: [Link].675@[Link], e.bharanidharan2003@[Link], jayanthibalaji777@[Link]
[Link]@[Link], [Link]@[Link], manikandan2602@[Link]
Abstract— Machine learning has been a revolutionary agent in the used-car industry, facilitating data-informed pricing. The
present study suggests an ensemble tri-model solution—Gamma, Poisson, and Random Forest regressors—to optimize used car
price estimation accuracy. Tested on a complete dataset of more than 10,000 samples for 5 years, the models produced a
minimum MAE of 984.27 and an R² of 0.938 using the Random Forest regressor. This ensemble solution provides consistent,
scalable, and interpretable solutions for buyers and dealerships to get accurate valuation under fluctuating market conditions.
Keywords— machine learning, second-hand car prices, predictive modeling, regression analysis, Predictive Maintenance and
Diagnostics, Process, predictive modelling, feature engineering, economic indicators, Optimization and Automation, Smart
Energy Management, market dynamics, feature engineering, data preprocessing, economic indicators.
I. INTRODUCTION
The pricing of used passenger vehicles has traditionally been based on heuristic estimates, dealer consensus, and sparse feature-
based approximations. Recent leaps in machine learning (ML) have enabled the creation of data-driven pricing models that
analyze a broad array of attributes, including make, model, year, mileage, fuel type, and dominant market trends. These models
reflect a considerable improvement over rule-based or manual pricing, minimizing pricing inaccuracies and fairness in the market.
This paper presents an ensemble of three regression models—Gamma, Poisson, and Random Forest—selected for their ability to
work with a variety of data distributions typical of vehicle pricing. The ensemble method transcends non-linear depreciation
behavior and asymmetrical price distributions. Existing work in this field, e.g., by Kagalwala et al. (2020) and Ribeiro et al.
(2021), has established the potential of ML in modeling car prices. Yet, such models tend to lack robustness for deployment or are
ineffective in capturing heterogeneous variance over diverse vehicle segments. Our method overcomes this drawback through
rigorous feature engineering, distributional modeling, and integration into real-world systems.
II. LITERATURE REVIEW
The application of machine learning methods to forecast used car prices has elicited significant interest based on their ability to
analyze high-dimensional, non-linear relationships common in automobile data sets. Hankar et al. (2022) applied a range of
regression models—namely decision trees and gradient boosting—to forecast resale prices based on parameters such as mileage,
fuel type, and make-model characteristics. The authors demonstrated the enhanced performance of the gradient boosting regressor
by its R-squared statistic and RMSE, thereby establishing the viability of ensemble learning techniques in unstable pricing
regimes.
Li et al. (2022) then built on this by comparing Random Forest and LightGBM regressors. Quantitative performance was found to
be competitive between the models, with Random Forest producing an MSE of 0.0373 and an R² of 0.936, followed by
LightGBM beating MAE by a small margin. This indicated that various ensemble methods may produce precision and
interpretability trade-offs in terms of feature importance and variance sensitivity. Both models struggled with skewed
distributional patterns in prices, particularly for outlier groups such as luxury cars.
Another methodological solution is offered by Balcioglu and Sezen (2024), who stressed preprocessing stringentness and model
ensemble. Following the evaluation of single-classifier solutions like Random Forest, SVM, and ANN, they developed a hybrid
model integrating best-performing features across algorithms. The ensemble methodology strongly improved predictive
performance on realistic, real-world data. Their results supported the necessity of multi-model setups but did not have statistical
support for model selection, especially regarding distribution fitting.
Abishek (2022) primarily dealt with the real-world applications of machine learning models within the field of market fairness. He
compared the linear regression, multiple regression, and Random Forest models to provide guidance to novice buyers and sellers
regarding the risks of market manipulation. While the scope of the research was wide, it was limited by its adoption of
conventional models that assume homoscedasticity and symmetric price variation—restrictions that can compromise accuracy for
expensive or rare cars.
In the same vein, Mudarakola et al. (2024) developed a predictive model using both linear and ensemble regressors on an
enormous dataset of brand, year, mileage, and fuel type. Their study demonstrated the power of ML to reveal inherent pricing
regimes, but failed to correct for possible sampling bias and geographic data skew. Their methodology also did not include formal
treatment of target variance heterogeneity, which is the most critical factor when predicting car prices on significantly diverse
segments.
Bukvić et al. (2022) put forward an empirical data-driven model for a Croatian market, based on listings that were obtained from
an online portal. Their comprehensive preprocessing and feature selection enabled better model training and higher prediction
accuracy. However, their study was mainly focused on data cleaning and traditional regression methods, and not sophisticated
statistical models aimed at non-normal price distributions. Despite extensive research in the past on large scales, there remain
considerable methodological flaws. The majority of the models assume normality over pricing distributions and fail to consider
heteroskedasticity, thus losing efficiency against sparse or skewed data. Furthermore, deployment-related factors such as real-time
integration and user interface are not typically taken into account. Our work, however, introduces a tri-model ensemble that
combines Gamma, Poisson, and Random Forest regressors, each of which is selected due to their statistical robustness to various
data distributions. We combine this with systematic data preprocessing, performance evaluation, and end-to-end deployment, thus
overcoming both technical and practical flaws in the field.
III. DEVELOPMENT PROCESS
Data Gathering
Data Pre-Processing
Choose model
Train model
Test model
Tune model
Prediction
Fig 1: Process of dataflow diagram
3.1 Data Pipeline
The first part of the process is assembling a clean dataset and representative of the used passenger car pricing behavior. This data
is assembled from numerous sources such as car resale websites, certified dealer inventories, and auction records, thus offering a
diverse mix of high- and low-end types of cars. Each record includes variables such as brand, model, year produced, mileage,
engine size, fuel type, number of previous owners, transmission type, city of registration, and asking price.
Preprocessing operations are:
Null Handling: Mode fills in blank categorical values (e.g., fuel type); numerical fields (e.g., mileage) are replaced with
the median.
Data Normalization: Min-max scaling normalizes continuous variables like mileage and engine capacity for sensitive
feature magnitude models.
Categorical Encoding: High-cardinality categorical features like model and brand are handled by one-hot or frequency
encoding based on sparsity.
Derived Features: Certain additional variables like vehicle age, annual mileage, and depreciation index are used to be
calculated for enriching the learning domain.
Outlier Filtering: Outliers are eliminated through interquartile range analysis against mileage and price; top/bottom 1% of
values are removed.
Temporal and Geographic Stratification: For minimizing sampling bias, we stratify the dataset to have balanced
representation over time (2018–2023) and geographic clusters (metro vs non-metro).
The last dataset contains more than 10,000 samples that can provide strong generalization among various types of vehicles, prices,
and user needs.
5.2 Model Training and Validation
To study various patterns of depreciation and price variation across various vehicles, three models were chosen as they were
appropriate for heterogeneous data distributions:
Gamma Regressor: Used for predicting prices of luxury vehicles as it can handle continuous positive data with
asymmetric distribution and multiplicative variance.
Poisson Regressor: Applicable to count-based variables such as car age and frequency of listings; optimal for lower-end
segments with steep price volatility in earlier years.
Random Forest Regressor is a flexible non-linear model that serves as the base estimator, able to identify intricate
interactions among categorical and numeric features.
The training process included:
Feature reduction was conducted using Recursive Feature Elimination (RFE) and feature importance scores derived from
Random Forest to remove non-contributing variables.
Model Verification: A 70-15-15 train-validation-test stratified split guarantees that market segment pricing patterns are
kept intact.
Hyperparameter Tuning:
For Poisson and Gamma: alpha, link function, and L1 penalty parameters were tuned using Grid Search.
For Random Forest: max features, tree depth, and number of trees were tuned using Randomized Search.
Each model was subjected to:
MAE (Mean Absolute Error)
Root Mean Square Error (RMSE)
R² (Coefficient of Determination)
The model was tested using 5-fold cross-validation, and the measures of performance were computed in 95% confidence intervals
to render them trustworthy.
5.3 System Deployment
Having achieved satisfactory performance figures for the model, the ensemble was integrated into an interactive, production-level
web application, built using modern software paradigms. System design has a modular architecture:
5.3.1 Application Stack
Frontend: HTML5/CSS, Bootstrap, JavaScript for UI responsiveness and user form validation.
Backend: Flask (Python) microservices-based architecture, and model prediction APIs.
Database: SQLite to store sessions, user details, and search history.
Model Serving: Pickled trained regressor versions deployed into Flask endpoints via joblib.
5.3.2 User Interaction Flow
Secure Login: Login is through username/password; sessions are stored securely through Flask-Login.
Dynamic Form Input: The customers enter car data such as a brand, year, mileage, fuel type, etc. using dropdowns and
form fields.
Real-time Prediction: Input submissions are routed to the tri-model ensemble. According to known segmentation criteria
(e.g., vehicle class or vehicle age), corresponding predictions from Gamma, Poisson, or Random Forest models are
returned.
5.3.3 Usability Features
Prediction History: Predictions for each user are saved and displayed on a history dashboard. Market Trend Panel: Displays the
current price trends in the user's city or region compared to similar models.
IV. ALGORITHM AND TECHNIQUES
Accurate second-hand car price estimation is a complexity challenge that involves the representation of non-linear interaction,
asymmetric distribution, and depreciation patterns specific to each segment. To represent them adequately, we employ a tri-
model ensemble of the Poisson Regressor, Gamma Regressor, and Random Forest Regressor. Each algorithm has its unique
representation strengths for capturing the rich statistical behaviors inherent in car price data.
4.1 Poisson Regressor: the Poisson Regressor is suitable for log-linear or count-based relationships typical of mileage- or age-
based price plans. It predicts the target variable y as:
E[y∣x]=exp(x⊤β)
This condition is that the price's expected value is positive and grows (falls) exponentially with the characteristics. The Poisson
model is most suitable for lower-priced vehicles, where price decline follows a smooth curve and moderate numerical shifts in
mileage or age result in drastic price [Link] addition, the variance of the Poisson distribution being equal to its mean renders
it a good fit for markets where homoscedasticity is impossible, e.g., mid-range or compact cars. Regularization (e.g., L2 penalty)
was employed to prevent overfitting and improve generalization to new data.
4.2. Random Forest: Random Forest (RF) is a strong ensemble technique based on decision trees. It operates by creating a
number of trees from bootstrap samples and taking the average of their predictions to reduce variance and overfitting. The
algorithm is not parametric and does not require data distribution, and thus it is best suited to datasets with:
Mixed data types (numerical + categorical)
Non-linear interactions (e.g., location × fuel type)
Missing values and outliers
In our Context, RF is great at teasing out hidden interactions between features—i.e., how the resale value of a diesel engine
would change by region or model. It also includes feature importance, enabling identification of such drivers as mileage, age, and
brand in determining [Link] that, RF serves as a baseline for our comparative analysis of the performance of our
statistically driven Poisson and Gamma regressors.
4.3. Gamma Regressor: Used-car price data—especially in luxury and high-end segments—often exhibits positive skewness
and heteroskedastic variance, where the variability increases with the value of the car. The Gamma Regressor addresses this by
assuming that:
y∼Gamma(κ,θ),withE[y∣x]= κ/θ=μ
A log-link function is typically used to accommodate the relationship between features and the mean μ, which also makes the
model effective for multiplicative error structures. This is especially relevant in terms of forecasting prices of high-value cars,
where tolerance to error grows with value and relative rather than absolute accuracy is more important. Gamma Regressor assists
in resolving bias in quantiles with more expensive values and improves system stability for different kinds of cars with
distribution-skewed values.
V. RESULT
In assessing the predictive model of second-hand car prices, the findings affirm that machine learning algorithms, such as
Random Forest and Gradient Boosting, offer consistent accuracy with regard to various important factors. Based on previous
sales and certain vehicle characteristics, the model successfully picked out strong predictors such as mileage, vehicle age,
brand, and model, which impacted price predictions. Random Forest performed better than other techniques with balanced
accuracy, whereas Gradient Boosting identified subtle variable interactions, which improved overall model accuracy. These
findings indicate that a data-driven strategy is useful for price estimation, which can assist consumers and sellers in making
better decisions.
Fig 2: UI Design
Fig 3: Prediction outcome - A visual graph displaying the predicted car price.
Fig 4: Result History - A summary view of past prediction records.
VI. DISCUSSION
The outcome of this research is that machine learning algorithms—particularly those designed specifically under distributional
assumptions—can be capable of delivering highly accurate and stable valuations of used vehicles. The stellar performance of
the Random Forest Regressor across different segments reflects the significance of non-linear, ensemble-driven methods in
identifying complex interactions between variables like mileage, make, and age. In addition, the application of a mixture of
Gamma and Poisson regressors improves the system's ability to identify heterogeneous price trends that are often lost to
standard symmetric models.
The tri-model method is particularly beneficial in real-world environments with asymmetrical price distributions and hybrid
data quality. For example, Poisson regression is particularly effective in forecasting the depreciation patterns of economy
vehicles, which see sharp initial drops in value, while Gamma regression provides more steady forecasts for luxury vehicles,
where price volatility increases with greater size. This implies that the use of distribution-conscious models is not only
methodologically justified but also practically indispensable when dealing with split datasets with high variance.
With regards to market alignment, such findings are directly symptomatic of the recent upheaval in the global automotive
ecosystem. The semiconductor shortage of 2021 and 2022 had a profound effect on increasing new-vehicle prices, which had
secondary effects in the used-car market. Our model, when trained on data that spans 2021 and 2022, was found to be adaptive
and could identify price anomalies such as these. Furthermore, the post-pandemic surge in used car demand, fueled by supply
chain disruptions and shifts in consumer behavior, further highlights the necessity of dynamic, data-driven valuation models.
SHAP and permutation-based feature importance models' outputs are useful in some ways. The outputs could be used as
roadmaps for dealers' price negotiations, and online marketplaces could use them to provide price decompositions that are
transparent to buyers. Moreover, transparency about feature effects helps to build trust in AI systems, which is necessary for
their uptake by customers who are not technically savvy.
In envisioning future applications, the model architecture developed within this paper holds strong promise for integration
with Internet of Things (IoT) sensors. New vehicles are increasingly being fitted with telematics modules that track real-time
data on mileage, fuel efficiency, engine health, and geographic location. Coupled with our trained ensemble, such real-time
data feeds can support live car valuations—enabling insurance premium pricing, trade-in estimates, or auto-resale auctioning
sites. This aligns with emerging trends in predictive electronics, in which edge analytics and cloud machine learning combine
to enable smart services.
In short, by implementing the ensemble model within a web-based prediction system, we show that advances in scholarly
machine learning are able to make the leap to consumer-level software. The system allows for immediate predictions,
monitoring of user history, and localized analysis of trend markets—making it scalable and accessible. This move completes
the loop from data collection through decision-making support, bringing to fruition the greater vision of applied machine
intelligence in transportation.
VII. CONCLUSION
Within the context of forecasting second-hand car prices based on machine learning algorithms, the findings indicate the
power of different algorithms in identifying the intricate relationships between car features and their market price. By
implementing regression algorithms like Linear Regression, Decision Trees, and Ensemble Algorithms like Random Forests
and Gradient Boosting, it was shown in this study that machine learning is capable of predicting car prices with great accuracy
based on parameters like age, mileage, brand, model, and condition. These algorithms are able to learn from past data to make
educated predictions, and provide good insights into the pricing pattern and decision drivers In general, machine learning
methods present a sound platform for analyzing and predicting second-hand vehicle prices, eventually assisting buyers and
sellers in making more adequate decisions in the automobile market.
VIII. REFERENCES
[1] M. Hankar, M. Birjali, and A. Beni-Hssane, "Used Car Price Prediction using Machine Learning: A Case Study," in 2022
11th International Symposium on Signal, Image, Video and Communications (ISIVC), El Jadida, Morocco, 2022.
[2] Y. Li, Y. Li, and Y. Liu, "Research on Used Car Price Prediction based on Random Forest and LightGBM," in 2022 IEEE
2nd International Conference on Data Science and Computer Application (ICDSCA), Dalian, China, 2022.
[3] Y. Balcioglu and B. Sezen, "Car Price Prediction Using Machine Learning Techniques," Zenodo, 2024,
doi:10.5281/zenodo.10893330.
[4] R. Abishek, "Car Price Prediction Using Machine Learning Techniques," 2022.
[5] L. P. Mudarakola, D. S. Prakash, K. L. N. Shashidhar, and D. Yaswanth, "Car Price Prediction Using Machine Learning,"
International Journal of Recent Advanced Scientific and Engineering Technology, 2024, doi:10.22214/ijraset.2024.61441.
[6] L. Bukvić, J. Pašagić Škrinjar, T. Fratrović, and B. Abramović, "Price Prediction and Classification of Used-Vehicles
Using Supervised Machine Learning," 2022.