Skip to content

Heart failure is a severe condition in which the heart is unable to pump blood effectively. Early prediction of heart failure can significantly improve patient outcomes. This project aims to build a predictive model using machine learning techniques to identify patients at risk of heart failure.

Notifications You must be signed in to change notification settings

harmanveer-2546/Heart-Failure-Prediction

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 

Repository files navigation

Heart Failure Prediction

Welcome to the Heart Failure Prediction project! This repository contains the code and resources for building a machine learning model to predict heart failure based on clinical data.

Table of Contents

Overview

Heart failure is a severe condition in which the heart is unable to pump blood effectively. Early prediction of heart failure can significantly improve patient outcomes. This project aims to build a predictive model using machine learning techniques to identify patients at risk of heart failure.

Dataset

The dataset used for this project contains clinical features of patients, such as age, sex, ejection fraction, serum creatinine levels, and more. The dataset can be found in the data directory. It is crucial to ensure the data is preprocessed correctly before training the model.

Requirements

To run this project, you will need the following packages and libraries:

  • Python 3.7+
  • NumPy
  • Pandas
  • Scikit-learn
  • Matplotlib
  • Seaborn
  • Jupyter Notebook (optional, for interactive development)

Installation

  1. Clone the repository:

    git clone https://github.com/your-username/heart-failure-prediction.git
    cd heart-failure-prediction
  2. Create a virtual environment and activate it:

    python3 -m venv venv
    source venv/bin/activate  # On Windows, use `venv\Scripts\activate`
  3. Install the required packages:

    pip install -r requirements.txt

Usage

  1. Ensure your dataset is in the data directory.

  2. Run the preprocessing script to clean and prepare the data:

    python preprocess.py
  3. Train the model using the prepared data:

    python train.py
  4. Evaluate the model performance:

    python evaluate.py
  5. (Optional) Run the Jupyter Notebook to interactively explore the data and results:

    jupyter notebook Heart_Failure_Prediction.ipynb

Results

The trained model achieves a high accuracy and recall in predicting heart failure. Detailed evaluation metrics and visualizations can be found in the Heart_Failure_Prediction.ipynb file.

Contributing

Contributions are welcome! If you have any ideas, suggestions, or bug fixes, please open an issue or submit a pull request. Ensure your code adheres to the existing style and include relevant tests.

Acknowledgements

We would like to thank the contributors and the community for their valuable input and support. Special thanks to the providers of the dataset for making this project possible.


About

Heart failure is a severe condition in which the heart is unable to pump blood effectively. Early prediction of heart failure can significantly improve patient outcomes. This project aims to build a predictive model using machine learning techniques to identify patients at risk of heart failure.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages