# πΉπ³ Tunisian House Rent Price Predictor π
This is a Machine Learning-powered web app that predicts the **monthly rent price of houses in Tunisia**, based on surface area, number of rooms, number of bathrooms, and city.
Built by a Tunisian CS student to explore real-world ML from end to end β from messy data cleaning to model training to web app deployment.
---
## π Live App
π Click here to open the live app
---
## π¦ Features
- π Predicts rent price based on:
- Surface (mΒ²)
- Rooms
- Bathrooms
- City (one-hot encoded)
- π Trained on real scraped data from Tayara.tn
- π― Supports Tunisian cities like Tunis, Sfax, Sousse, etc.
- π Deployed with Streamlit Cloud for public use
---
## π Dataset
The dataset was scraped from tayara.tn and cleaned manually:
- Removed entries with missing or inconsistent values
- Filtered unreasonable outliers (e.g., 0 rooms with 1000 TND)
- Encoded categorical data (cities) using One-Hot Encoding
Final dataset: **~1900 rental houses**
---
## π§ Model
We tested:
- Linear Regression
- Random Forest Regressor
Final performance (after filtering outliers):
- **Linear Regression** (best model β
)
- **MAE**: ~244 TND
- **RMSE**: ~302 TND
Model trained on features:
```python
['surface', 'rooms', 'bathrooms', 'city_Tunis', 'city_Sfax', ...]
```
## π¨βπ» Author
**Mohamed Dhahbi** β CS student & aspiring ML engineer
π§ mohameddhahbi56@gmail.com