Skip to content

Latest commit

 

History

2 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

House Price Prediction Using Machine Learning

A Machine Learning project that predicts house prices using regression techniques trained on the Ames Housing Dataset. The trained model is integrated into a Streamlit web application for real-time house price prediction.

Project Overview

This project covers the complete Machine Learning workflow, including:

  • Data preprocessing
  • Exploratory Data Analysis (EDA)
  • Feature selection
  • Regression model training
  • Model evaluation and comparison
  • Trained model saving using Joblib
  • Streamlit application development
  • Real-time house price prediction

Features

  • Real-time house price prediction
  • Multiple Machine Learning regression models
  • Exploratory Data Analysis
  • Data preprocessing
  • Trained Scikit-learn model
  • Interactive Streamlit interface
  • Saved model using Joblib
  • Ready for Streamlit Cloud deployment
  • No separate backend API required

Machine Learning Models

The project explores the following regression techniques:

  • Simple Linear Regression
  • Multiple Linear Regression
  • Polynomial Regression

After model comparison, the selected trained model is saved as:

final_model.pkl

Input Features

The Streamlit application uses important house features such as:

Feature Description
OverallQual Overall quality of the house
GrLivArea Above-ground living area
GarageCars Garage capacity
GarageArea Garage area
TotalBsmtSF Total basement area
1stFlrSF First floor area
FullBath Number of full bathrooms
TotRmsAbvGrd Total rooms above ground
YearBuilt Year the house was built
YearRemodAdd Year of remodeling

Project Structure

House-Price-Prediction-ML/
│
├── frontend/
│   ├── app.py
│   ├── final_model.pkl
│   └── requirements.txt
│
├── notebook/
│   └── House_Price_Prediction.ipynb
│
├── train.csv
├── train (1).csv
├── ML_Project.docx
└── README.md

Technologies Used

  • Python
  • Pandas
  • NumPy
  • Matplotlib
  • Seaborn
  • Scikit-learn
  • Joblib
  • Streamlit
  • Jupyter Notebook

Dataset

The project uses the Ames Housing Dataset.

Main dataset:

train.csv

The dataset contains different property features that are used to train regression models for house price prediction.

Installation

Clone the repository:

git clone https://github.com/WardaAhad/House-Price-Prediction-ML.git

Move into the project directory:

cd House-Price-Prediction-ML

Install the required dependencies:

pip install -r frontend/requirements.txt

Run the Streamlit App

Run the application using:

streamlit run frontend/app.py

The application will open in your browser at:

http://localhost:8501

How It Works

House Features
      ↓
User Input in Streamlit
      ↓
Data Processing
      ↓
Trained ML Model
      ↓
House Price Prediction
      ↓
Predicted Price Displayed

Example

The user enters information such as:

  • Overall house quality
  • Living area
  • Garage size
  • Basement area
  • Number of bathrooms
  • Number of rooms
  • Construction year
  • Remodeling year

The trained Machine Learning model processes these features and returns the predicted house price.

Model Training

The complete model development process is available in:

notebook/House_Price_Prediction.ipynb

The notebook includes data analysis, preprocessing, model training, evaluation, and model comparison.

Deployment

The Streamlit application can be deployed using Streamlit Community Cloud.

Future Improvements

  • Hyperparameter tuning
  • Improved feature engineering
  • Advanced regression models
  • Model performance optimization
  • Enhanced Streamlit UI
  • Cloud deployment improvements
  • Additional house features

Project Goal

The goal of this project is to demonstrate an end-to-end Machine Learning workflow, from dataset analysis and regression modeling to building an interactive web application for real-time house price prediction.

About

A Machine Learning project that predicts house prices using Regression models with FastAPI backend and Streamlit frontend.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Contributors

Languages