age
int64 | sex
int64 | cp
int64 | trestbps
int64 | chol
int64 | fbs
int64 | restecg
int64 | thalach
int64 | exang
int64 | oldpeak
float64 | slope
int64 | ca
int64 | thal
int64 | target
int64 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
52
| 1
| 0
| 125
| 212
| 0
| 1
| 168
| 0
| 1
| 2
| 2
| 3
| 0
|
53
| 1
| 0
| 140
| 203
| 1
| 0
| 155
| 1
| 3.1
| 0
| 0
| 3
| 0
|
70
| 1
| 0
| 145
| 174
| 0
| 1
| 125
| 1
| 2.6
| 0
| 0
| 3
| 0
|
61
| 1
| 0
| 148
| 203
| 0
| 1
| 161
| 0
| 0
| 2
| 1
| 3
| 0
|
62
| 0
| 0
| 138
| 294
| 1
| 1
| 106
| 0
| 1.9
| 1
| 3
| 2
| 0
|
58
| 0
| 0
| 100
| 248
| 0
| 0
| 122
| 0
| 1
| 1
| 0
| 2
| 1
|
58
| 1
| 0
| 114
| 318
| 0
| 2
| 140
| 0
| 4.4
| 0
| 3
| 1
| 0
|
55
| 1
| 0
| 160
| 289
| 0
| 0
| 145
| 1
| 0.8
| 1
| 1
| 3
| 0
|
46
| 1
| 0
| 120
| 249
| 0
| 0
| 144
| 0
| 0.8
| 2
| 0
| 3
| 0
|
54
| 1
| 0
| 122
| 286
| 0
| 0
| 116
| 1
| 3.2
| 1
| 2
| 2
| 0
|
71
| 0
| 0
| 112
| 149
| 0
| 1
| 125
| 0
| 1.6
| 1
| 0
| 2
| 1
|
43
| 0
| 0
| 132
| 341
| 1
| 0
| 136
| 1
| 3
| 1
| 0
| 3
| 0
|
34
| 0
| 1
| 118
| 210
| 0
| 1
| 192
| 0
| 0.7
| 2
| 0
| 2
| 1
|
51
| 1
| 0
| 140
| 298
| 0
| 1
| 122
| 1
| 4.2
| 1
| 3
| 3
| 0
|
52
| 1
| 0
| 128
| 204
| 1
| 1
| 156
| 1
| 1
| 1
| 0
| 0
| 0
|
34
| 0
| 1
| 118
| 210
| 0
| 1
| 192
| 0
| 0.7
| 2
| 0
| 2
| 1
|
51
| 0
| 2
| 140
| 308
| 0
| 0
| 142
| 0
| 1.5
| 2
| 1
| 2
| 1
|
54
| 1
| 0
| 124
| 266
| 0
| 0
| 109
| 1
| 2.2
| 1
| 1
| 3
| 0
|
50
| 0
| 1
| 120
| 244
| 0
| 1
| 162
| 0
| 1.1
| 2
| 0
| 2
| 1
|
58
| 1
| 2
| 140
| 211
| 1
| 0
| 165
| 0
| 0
| 2
| 0
| 2
| 1
|
60
| 1
| 2
| 140
| 185
| 0
| 0
| 155
| 0
| 3
| 1
| 0
| 2
| 0
|
67
| 0
| 0
| 106
| 223
| 0
| 1
| 142
| 0
| 0.3
| 2
| 2
| 2
| 1
|
45
| 1
| 0
| 104
| 208
| 0
| 0
| 148
| 1
| 3
| 1
| 0
| 2
| 1
|
63
| 0
| 2
| 135
| 252
| 0
| 0
| 172
| 0
| 0
| 2
| 0
| 2
| 1
|
42
| 0
| 2
| 120
| 209
| 0
| 1
| 173
| 0
| 0
| 1
| 0
| 2
| 1
|
61
| 0
| 0
| 145
| 307
| 0
| 0
| 146
| 1
| 1
| 1
| 0
| 3
| 0
|
44
| 1
| 2
| 130
| 233
| 0
| 1
| 179
| 1
| 0.4
| 2
| 0
| 2
| 1
|
58
| 0
| 1
| 136
| 319
| 1
| 0
| 152
| 0
| 0
| 2
| 2
| 2
| 0
|
56
| 1
| 2
| 130
| 256
| 1
| 0
| 142
| 1
| 0.6
| 1
| 1
| 1
| 0
|
55
| 0
| 0
| 180
| 327
| 0
| 2
| 117
| 1
| 3.4
| 1
| 0
| 2
| 0
|
44
| 1
| 0
| 120
| 169
| 0
| 1
| 144
| 1
| 2.8
| 0
| 0
| 1
| 0
|
50
| 0
| 1
| 120
| 244
| 0
| 1
| 162
| 0
| 1.1
| 2
| 0
| 2
| 1
|
57
| 1
| 0
| 130
| 131
| 0
| 1
| 115
| 1
| 1.2
| 1
| 1
| 3
| 0
|
70
| 1
| 2
| 160
| 269
| 0
| 1
| 112
| 1
| 2.9
| 1
| 1
| 3
| 0
|
50
| 1
| 2
| 129
| 196
| 0
| 1
| 163
| 0
| 0
| 2
| 0
| 2
| 1
|
46
| 1
| 2
| 150
| 231
| 0
| 1
| 147
| 0
| 3.6
| 1
| 0
| 2
| 0
|
51
| 1
| 3
| 125
| 213
| 0
| 0
| 125
| 1
| 1.4
| 2
| 1
| 2
| 1
|
59
| 1
| 0
| 138
| 271
| 0
| 0
| 182
| 0
| 0
| 2
| 0
| 2
| 1
|
64
| 1
| 0
| 128
| 263
| 0
| 1
| 105
| 1
| 0.2
| 1
| 1
| 3
| 1
|
57
| 1
| 2
| 128
| 229
| 0
| 0
| 150
| 0
| 0.4
| 1
| 1
| 3
| 0
|
65
| 0
| 2
| 160
| 360
| 0
| 0
| 151
| 0
| 0.8
| 2
| 0
| 2
| 1
|
54
| 1
| 2
| 120
| 258
| 0
| 0
| 147
| 0
| 0.4
| 1
| 0
| 3
| 1
|
61
| 0
| 0
| 130
| 330
| 0
| 0
| 169
| 0
| 0
| 2
| 0
| 2
| 0
|
46
| 1
| 0
| 120
| 249
| 0
| 0
| 144
| 0
| 0.8
| 2
| 0
| 3
| 0
|
55
| 0
| 1
| 132
| 342
| 0
| 1
| 166
| 0
| 1.2
| 2
| 0
| 2
| 1
|
42
| 1
| 0
| 140
| 226
| 0
| 1
| 178
| 0
| 0
| 2
| 0
| 2
| 1
|
41
| 1
| 1
| 135
| 203
| 0
| 1
| 132
| 0
| 0
| 1
| 0
| 1
| 1
|
66
| 0
| 0
| 178
| 228
| 1
| 1
| 165
| 1
| 1
| 1
| 2
| 3
| 0
|
66
| 0
| 2
| 146
| 278
| 0
| 0
| 152
| 0
| 0
| 1
| 1
| 2
| 1
|
60
| 1
| 0
| 117
| 230
| 1
| 1
| 160
| 1
| 1.4
| 2
| 2
| 3
| 0
|
58
| 0
| 3
| 150
| 283
| 1
| 0
| 162
| 0
| 1
| 2
| 0
| 2
| 1
|
57
| 0
| 0
| 140
| 241
| 0
| 1
| 123
| 1
| 0.2
| 1
| 0
| 3
| 0
|
38
| 1
| 2
| 138
| 175
| 0
| 1
| 173
| 0
| 0
| 2
| 4
| 2
| 1
|
49
| 1
| 2
| 120
| 188
| 0
| 1
| 139
| 0
| 2
| 1
| 3
| 3
| 0
|
55
| 1
| 0
| 140
| 217
| 0
| 1
| 111
| 1
| 5.6
| 0
| 0
| 3
| 0
|
55
| 1
| 0
| 140
| 217
| 0
| 1
| 111
| 1
| 5.6
| 0
| 0
| 3
| 0
|
56
| 1
| 3
| 120
| 193
| 0
| 0
| 162
| 0
| 1.9
| 1
| 0
| 3
| 1
|
48
| 1
| 1
| 130
| 245
| 0
| 0
| 180
| 0
| 0.2
| 1
| 0
| 2
| 1
|
67
| 1
| 2
| 152
| 212
| 0
| 0
| 150
| 0
| 0.8
| 1
| 0
| 3
| 0
|
57
| 1
| 1
| 154
| 232
| 0
| 0
| 164
| 0
| 0
| 2
| 1
| 2
| 0
|
29
| 1
| 1
| 130
| 204
| 0
| 0
| 202
| 0
| 0
| 2
| 0
| 2
| 1
|
66
| 0
| 2
| 146
| 278
| 0
| 0
| 152
| 0
| 0
| 1
| 1
| 2
| 1
|
67
| 1
| 0
| 100
| 299
| 0
| 0
| 125
| 1
| 0.9
| 1
| 2
| 2
| 0
|
59
| 1
| 2
| 150
| 212
| 1
| 1
| 157
| 0
| 1.6
| 2
| 0
| 2
| 1
|
29
| 1
| 1
| 130
| 204
| 0
| 0
| 202
| 0
| 0
| 2
| 0
| 2
| 1
|
59
| 1
| 3
| 170
| 288
| 0
| 0
| 159
| 0
| 0.2
| 1
| 0
| 3
| 0
|
53
| 1
| 2
| 130
| 197
| 1
| 0
| 152
| 0
| 1.2
| 0
| 0
| 2
| 1
|
42
| 1
| 0
| 136
| 315
| 0
| 1
| 125
| 1
| 1.8
| 1
| 0
| 1
| 0
|
37
| 0
| 2
| 120
| 215
| 0
| 1
| 170
| 0
| 0
| 2
| 0
| 2
| 1
|
62
| 0
| 0
| 160
| 164
| 0
| 0
| 145
| 0
| 6.2
| 0
| 3
| 3
| 0
|
59
| 1
| 0
| 170
| 326
| 0
| 0
| 140
| 1
| 3.4
| 0
| 0
| 3
| 0
|
61
| 1
| 0
| 140
| 207
| 0
| 0
| 138
| 1
| 1.9
| 2
| 1
| 3
| 0
|
56
| 1
| 0
| 125
| 249
| 1
| 0
| 144
| 1
| 1.2
| 1
| 1
| 2
| 0
|
59
| 1
| 0
| 140
| 177
| 0
| 1
| 162
| 1
| 0
| 2
| 1
| 3
| 0
|
48
| 1
| 0
| 130
| 256
| 1
| 0
| 150
| 1
| 0
| 2
| 2
| 3
| 0
|
47
| 1
| 2
| 138
| 257
| 0
| 0
| 156
| 0
| 0
| 2
| 0
| 2
| 1
|
48
| 1
| 2
| 124
| 255
| 1
| 1
| 175
| 0
| 0
| 2
| 2
| 2
| 1
|
63
| 1
| 0
| 140
| 187
| 0
| 0
| 144
| 1
| 4
| 2
| 2
| 3
| 0
|
52
| 1
| 1
| 134
| 201
| 0
| 1
| 158
| 0
| 0.8
| 2
| 1
| 2
| 1
|
52
| 1
| 1
| 134
| 201
| 0
| 1
| 158
| 0
| 0.8
| 2
| 1
| 2
| 1
|
50
| 1
| 2
| 140
| 233
| 0
| 1
| 163
| 0
| 0.6
| 1
| 1
| 3
| 0
|
49
| 1
| 2
| 118
| 149
| 0
| 0
| 126
| 0
| 0.8
| 2
| 3
| 2
| 0
|
46
| 1
| 2
| 150
| 231
| 0
| 1
| 147
| 0
| 3.6
| 1
| 0
| 2
| 0
|
38
| 1
| 2
| 138
| 175
| 0
| 1
| 173
| 0
| 0
| 2
| 4
| 2
| 1
|
37
| 0
| 2
| 120
| 215
| 0
| 1
| 170
| 0
| 0
| 2
| 0
| 2
| 1
|
44
| 1
| 1
| 120
| 220
| 0
| 1
| 170
| 0
| 0
| 2
| 0
| 2
| 1
|
58
| 1
| 2
| 140
| 211
| 1
| 0
| 165
| 0
| 0
| 2
| 0
| 2
| 1
|
59
| 0
| 0
| 174
| 249
| 0
| 1
| 143
| 1
| 0
| 1
| 0
| 2
| 0
|
62
| 0
| 0
| 140
| 268
| 0
| 0
| 160
| 0
| 3.6
| 0
| 2
| 2
| 0
|
68
| 1
| 0
| 144
| 193
| 1
| 1
| 141
| 0
| 3.4
| 1
| 2
| 3
| 0
|
54
| 0
| 2
| 108
| 267
| 0
| 0
| 167
| 0
| 0
| 2
| 0
| 2
| 1
|
62
| 0
| 0
| 124
| 209
| 0
| 1
| 163
| 0
| 0
| 2
| 0
| 2
| 1
|
63
| 1
| 0
| 140
| 187
| 0
| 0
| 144
| 1
| 4
| 2
| 2
| 3
| 0
|
44
| 1
| 0
| 120
| 169
| 0
| 1
| 144
| 1
| 2.8
| 0
| 0
| 1
| 0
|
62
| 1
| 1
| 128
| 208
| 1
| 0
| 140
| 0
| 0
| 2
| 0
| 2
| 1
|
45
| 0
| 0
| 138
| 236
| 0
| 0
| 152
| 1
| 0.2
| 1
| 0
| 2
| 1
|
57
| 0
| 0
| 128
| 303
| 0
| 0
| 159
| 0
| 0
| 2
| 1
| 2
| 1
|
53
| 1
| 0
| 123
| 282
| 0
| 1
| 95
| 1
| 2
| 1
| 2
| 3
| 0
|
65
| 1
| 0
| 110
| 248
| 0
| 0
| 158
| 0
| 0.6
| 2
| 2
| 1
| 0
|
76
| 0
| 2
| 140
| 197
| 0
| 2
| 116
| 0
| 1.1
| 1
| 0
| 2
| 1
|
❤️ Heart Disease — Exploratory Data Analysis
👤 Author
Oded Fuchs
🎯 Project Goal
The goal of this project is to explore which factors are most strongly related to heart disease,
using statistical analysis and data visualization.
🔍 Research Question
Which factors have the strongest impact on the likelihood of heart disease?
📦 Dataset
- Source: Kaggle
- Format: CSV
- ~302 samples
- Contains various clinical features
Target
target
- 1 = Heart disease
- 0 = No heart disease
🏷 Feature Overview
| Feature | Description |
|---|---|
| age | Age |
| sex | 0 = female, 1 = male |
| cp | Chest pain type |
| trestbps | Resting blood pressure |
| chol | Cholesterol |
| fbs | Fasting blood sugar |
| restecg | Resting ECG results |
| thalach | Maximum heart rate |
| exang | Exercise-induced angina |
| oldpeak | ST depression |
| slope | Slope of ST |
| ca | Number of major vessels |
| thal | Thallium test result |
| target | Heart disease indicator |
🔧 Data Preparation
✅ Cleaning Steps
- Checked for missing values — none found
- Checked for duplicate records
- Verified valid ranges
- Adjusted and simplified column names
📊 Exploratory Data Analysis (EDA)
Target Distribution
✅ Key Features & Insights
1) Age
Patients with heart disease are slightly younger on average.
2) Chest Pain (cp)
One of the strongest predictors:
Higher chest pain type is strongly linked to heart disease.
3) Max Heart Rate (thalach)
Patients with heart disease tend to have a higher maximum heart rate.
4) ST Depression (oldpeak)
Lower oldpeak values are more common among heart-disease patients.
5) Exercise-Induced Angina (exang)
Most patients do not experience chest pain during exercise.
6) Thal
Moderate difference between groups, still noticeable.
📑 Summary Table
| Feature | No Disease (0) | Disease (1) | Insight |
|---|---|---|---|
| cp | 0.48 | 1.38 | Strong relationship |
| thalach | 139 | 159 | Higher among disease |
| oldpeak | 1.60 | 0.57 | Lower among disease |
| exang | 0.55 | 0.14 | Less common in disease |
| age | 56.6 | 52.4 | Slightly younger |
| chol | 251 | 241 | Small difference |
| ca | 1.16 | 0.37 | ⚠️ Opposite trend |
| trestbps | 134 | 129 | Weak effect |
| thal | 2.54 | 2.12 | Moderate effect |
✅ Main Insights
📌 Strong indicators of heart disease:
- Chest Pain (cp)
- Max Heart Rate (thalach)
- ST Depression (oldpeak)
- Exercise-Induced Angina (exang)
📌 Additional observations:
- Exercise-induced angina (exang) is less common among patients with heart disease
- Cholesterol and blood pressure show weaker relationships
cashows an unexpected pattern → may indicate data/coding issues
✅ Conclusions
Several clinical measurements appear strongly connected to heart disease, including chest pain type, maximum heart rate, and ST-related metrics.
Other features, such as cholesterol and resting blood pressure, show weaker influence.
🎬 Video Presentation
🔗 https://www.loom.com/share/d5891c3d0c20490ba79884fc701f4bc7
🧾 Files Included
| File | Description |
|---|---|
| Assignment_1_oded_fuchs.ipynb | Analysis & visuals |
| README.md | Project summary |
| heart.csv | Original dataset |
- Downloads last month
- 34






