# sshema-cpu/heart-disease-ml architecture

> Architecture diagram of the GitHub repository sshema-cpu/heart-disease-ml, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-28). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/sshema-cpu/heart-disease-ml
- Repository: https://github.com/sshema-cpu/heart-disease-ml

## Overview

This is an educational heart-disease classification project, centered on a notebook that compares three models using 1,025 patient records. The documented workflow loads the CSV, explores it, splits and scales features, trains models, and evaluates them with test metrics, cross-validation, and visualizations. The report and portfolio page are separate project artifacts. The notebook’s source was not sampled, so workflow links reflect the README’s stated methodology; links to artifact internals are omitted.

Main entry points: [`notebooks/heart_disease_prediction.ipynb`](https://github.com/sshema-cpu/heart-disease-ml/blob/main/notebooks/heart_disease_prediction.ipynb) (Split and scale), [`data/heart.csv`](https://github.com/sshema-cpu/heart-disease-ml/blob/main/data/heart.csv) (Heart records), [`report/Sam_Shema_ML_Final_Report.pdf`](https://github.com/sshema-cpu/heart-disease-ml/blob/main/report/Sam_Shema_ML_Final_Report.pdf) (Written report), [`index.html`](https://github.com/sshema-cpu/heart-disease-ml/blob/main/index.html) (Portfolio page)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_data["Dataset"]
  node_dataset[("Heart records<br/>[heart.csv]")]
end

subgraph group_analysis["Notebook Analysis"]
  node_eda["Explore data"]
  node_prep["Split and scale"]
  node_logistic["Logistic regression"]
  node_tree["Decision tree"]
  node_network["Neural network"]
  node_evaluation["Evaluate models"]
end

subgraph group_artifacts["Project Artifacts"]
  node_report["Written report"]
  node_portfolio["Portfolio page<br/>[index.html]"]
end

node_reader(("Project reader"))

node_reader -->|"runs notebook"| node_eda
node_dataset -->|"loads records"| node_eda
node_eda -->|"prepares features"| node_prep
node_prep -->|"trains baseline"| node_logistic
node_prep -->|"trains tree"| node_tree
node_prep -->|"trains network"| node_network
node_logistic -->|"evaluates"| node_evaluation
node_tree -->|"evaluates"| node_evaluation
node_network -->|"evaluates"| node_evaluation
node_reader -->|"reads"| node_report
node_reader -->|"views"| node_portfolio

click node_dataset "https://github.com/sshema-cpu/heart-disease-ml/blob/main/data/heart.csv"
click node_eda "https://github.com/sshema-cpu/heart-disease-ml/blob/main/notebooks/heart_disease_prediction.ipynb"
click node_prep "https://github.com/sshema-cpu/heart-disease-ml/blob/main/notebooks/heart_disease_prediction.ipynb"
click node_logistic "https://github.com/sshema-cpu/heart-disease-ml/blob/main/notebooks/heart_disease_prediction.ipynb"
click node_tree "https://github.com/sshema-cpu/heart-disease-ml/blob/main/notebooks/heart_disease_prediction.ipynb"
click node_network "https://github.com/sshema-cpu/heart-disease-ml/blob/main/notebooks/heart_disease_prediction.ipynb"
click node_evaluation "https://github.com/sshema-cpu/heart-disease-ml/blob/main/notebooks/heart_disease_prediction.ipynb"
click node_report "https://github.com/sshema-cpu/heart-disease-ml/blob/main/report/Sam_Shema_ML_Final_Report.pdf"
click node_portfolio "https://github.com/sshema-cpu/heart-disease-ml/blob/main/index.html"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_dataset toneBlue
class node_eda,node_prep,node_logistic,node_tree,node_network,node_evaluation toneAmber
class node_report,node_portfolio toneMint
class node_reader toneIndigo
```

## Components

### Dataset

- [Heart records](https://github.com/sshema-cpu/heart-disease-ml/blob/main/data/heart.csv): `data/heart.csv`

### Notebook Analysis

- [Explore data](https://github.com/sshema-cpu/heart-disease-ml/blob/main/notebooks/heart_disease_prediction.ipynb): `notebooks/heart_disease_prediction.ipynb`
- [Split and scale](https://github.com/sshema-cpu/heart-disease-ml/blob/main/notebooks/heart_disease_prediction.ipynb): `notebooks/heart_disease_prediction.ipynb`
- [Logistic regression](https://github.com/sshema-cpu/heart-disease-ml/blob/main/notebooks/heart_disease_prediction.ipynb): `notebooks/heart_disease_prediction.ipynb`
- [Decision tree](https://github.com/sshema-cpu/heart-disease-ml/blob/main/notebooks/heart_disease_prediction.ipynb): `notebooks/heart_disease_prediction.ipynb`
- [Neural network](https://github.com/sshema-cpu/heart-disease-ml/blob/main/notebooks/heart_disease_prediction.ipynb): `notebooks/heart_disease_prediction.ipynb`
- [Evaluate models](https://github.com/sshema-cpu/heart-disease-ml/blob/main/notebooks/heart_disease_prediction.ipynb): `notebooks/heart_disease_prediction.ipynb`

### Project Artifacts

- [Written report](https://github.com/sshema-cpu/heart-disease-ml/blob/main/report/Sam_Shema_ML_Final_Report.pdf): `report/Sam_Shema_ML_Final_Report.pdf`
- [Portfolio page](https://github.com/sshema-cpu/heart-disease-ml/blob/main/index.html): `index.html`

### Other components

- **Project reader**

## Connections

- Project reader → Explore data: runs notebook
- Heart records → Explore data: loads records
- Explore data → Split and scale: prepares features
- Split and scale → Logistic regression: trains baseline
- Split and scale → Decision tree: trains tree
- Split and scale → Neural network: trains network
- Logistic regression → Evaluate models: evaluates
- Decision tree → Evaluate models: evaluates
- Neural network → Evaluate models: evaluates
- Project reader → Written report: reads
- Project reader → Portfolio page: views
