Skip to content

adirbella37/RentalPrice-ML-Modeling

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

8 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Tel Aviv Apartments Rent Prediction Project

This project aims to predict apartment rental prices in Tel Aviv using machine learning models. The notebook covers data wrangling, feature engineering, and building predictive models using Elastic Net and Decision Trees. We evaluate the performance of both models and compare their results.

πŸ““ Notebook

πŸ‘‰ Open on nbviewer

βš™οΈ Technologies

  • Python β€” main programming language
  • Pandas β€” for data wrangling and preprocessing
  • Scikit-learn β€” for building and training models (Elastic Net, Decision Trees)
  • Matplotlib & Seaborn β€” for visualizations
  • Pickle β€” to save the trained models

πŸ“‚ Project Structure

File/Folder Description
apartment_rent_prediction.ipynb Main Jupyter Notebook (data wrangling, feature engineering, modeling)
train.csv Training dataset
en_model.pkl Saved Elastic Net trained model
README.md Project documentation

▢️ How to run

You can get this project in two ways:

Option 1 – Using Git

git clone https://github.com/adirbella37/RentalPrice-ML-Modeling.git
cd RentalPrice-ML-Modeling

Option 2 – Download as ZIP

  1. Click the green Code button at the top of this repository
  2. Select Download ZIP
  3. Extract the ZIP file on your computer

πŸ“ˆ Key Insights

  • ElasticNet: Regularization helped handle multicollinearity, but overall performance was weaker compared to tree-based models. Removing redundant features simplified the model without reducing accuracy.
  • XGBoost: Outperformed all tested models (ElasticNet, Random Forest, Decision Tree, Gradient Boosting) with lower RMSE/MAE and higher RΒ². Captured non-linear interactions and leveraged engineered features effectively.
  • Feature importance: Both models ranked apartment area as the most critical feature. ElasticNet emphasized linear predictors like property type and room count, while XGBoost highlighted complex interactions (e.g., area Γ— elevator, parking, AC, neighborhood).
  • Rare categories: Grouping infrequent neighborhoods improved stability in XGBoost, while ElasticNet handled them well using Target Encoding with smoothing.
  • Model choice: XGBoost was selected as the final model due to superior predictive performance and robustness to complex feature interactions.

πŸ“œ License

This project is licensed under the MIT License.

About

A machine learning project to predict apartment rental prices in Tel Aviv using Elastic Net and Decision Trees. It includes data preprocessing, feature engineering, model training, and performance evaluation.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors