Models RMSE MAE R-squared
Linear Regression $10,643 $8,121 0.188
CART $9,872 $7,333 0.301
Neural Network $10,124 $7,527 0.265
Random Forest $8,652 $6,134 0.431
XGBoost $4,463 $3,208 0.857
Models RMSE MAE R-squared
Linear Regression $10,643 $8,121 0.188
CART $9,872 $7,333 0.301
Neural Network $10,124 $7,527 0.265
Random Forest $8,652 $6,134 0.431
XGBoost $4,463 $3,208 0.857
Does population matter? Should you go to bigger cities to buy a car?
Based on my analysis, population does have some effect on car prices, but it's not the biggest factor. In the XGBoost model, population was the second most important variable (after mileage), and areas with higher populations tended to have slightly lower car prices, likely due to more competition and larger supply.
So yes, bigger cities may offer better prices, especially because there are more listings to choose from. However, it's still more important to look at things like mileage and condition of the car. A car with low mileage will usually be a better deal, no matter where it's sold