Skip to content

Prediction of car prices with Python and k-nearest neighbours algorithm

Notifications You must be signed in to change notification settings

tfreyd/predict_car_prices

Repository files navigation

Predict Car Prices

The model is trained on data from Ebay car sales data and can predict the car price with an approximation as low as 1814$. This value was obtained by applying a multivariate K nearest neighbors regression with 5 features and a k value of 16. image

Best features for univariate K nearest neighbors regression

By sampling a few k values on all the numeric features found in the dataset, the 5 that gave the lowest RMSE were:

  • highway_mpg
  • curb_weigh
  • eng_size
  • city_mpg
  • width

image

Optimal settings for multivariate K nearest neighbors regression (number of features and k value)

Based on the first graph different combination of the best features were tested for a range of parameters. The couple of setting that gave the lowest RMSE was with 5 features and a k value of 16. image

About

Prediction of car prices with Python and k-nearest neighbours algorithm

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published