Skip to content

dhmodh/diabetes-prediction

Repository files navigation

Diabetes Prediction Capstone

Predict diabetes using classic ML models on the Pima Indians Diabetes dataset (or a compatible healthcare CSV).

Project Structure

.
├─ README.md
├─ requirements.txt
├─ app.py                      # Streamlit app for inference
├─ .gitignore
├─ LICENSE
├─ diabetes_capstone.ipynb
├─ diabetes_best_model.joblib  # created after running notebook
└─ data/
   └─ README.md               # how to obtain/place datasets

Dataset

Target column should be one of: Outcome, target, diabetes, or class. Adjust in the notebook if different.

Quickstart

  1. Create environment and install dependencies
python3 -m venv .venv
source .venv/bin/activate
pip install --upgrade pip
pip install -r requirements.txt
  1. Launch the notebook
jupyter notebook diabetes_capstone.ipynb
  1. Run all cells
  • Performs EDA, preprocessing, trains Logistic Regression / RandomForest / SVM / GradientBoosting
  • Compares metrics and saves best model as diabetes_best_model.joblib
  1. Export to PDF (for submission)
  • From the notebook UI: File → Print Preview → Print to PDF
  • Or via CLI:
jupyter nbconvert --to pdf diabetes_capstone.ipynb

Reproducibility

  • All steps are captured in the notebook.
  • requirements.txt pins core packages for consistent runs.

License

MIT License — see LICENSE.

Streamlit App

Run locally:

pip install -r requirements.txt
streamlit run app.py

Usage:

  • Option 1: Upload a CSV with the same feature columns used during training.
  • Option 2: Use the manual input form (typical numeric features from Pima dataset).

Deployment (optional):

  • Push this repo to GitHub. On Streamlit Cloud (or similar), create a new app pointing to app.py.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published