a-b-15/heart-attack-analysis
0
Heart Attack Risk Prediction
A machine learning application that predicts the risk of heart attack based on patient medical data.
Features
- Interactive Web Interface: User-friendly form to input patient details
- Real-time Predictions: Instant risk assessment with probability scores
- High Accuracy: Trained on heart attack dataset with ~87% accuracy using SVM
- Multiple Models Evaluated: Logistic Regression, Random Forest, SVM, and Neural Networks
Dataset
The model is trained on a comprehensive heart attack dataset with 305 patient records containing 14 features:
- Age, Sex, Chest Pain Type
- Resting Blood Pressure, Cholesterol
- Fasting Blood Sugar, Resting ECG
- Maximum Heart Rate, Exercise Induced Angina
- ST Depression (Oldpeak), Slope
- Number of Major Vessels, Thalassemia
- Target (Heart Attack Risk)
Model Performance
- Best Model: Support Vector Machine (SVM)
- Accuracy: 86.89%
- Precision: 87%
- Recall: 87%
Usage
Simply input the patient's medical parameters in the web form and click "Predict Risk" to get an instant assessment.
Technology Stack
- Backend: Flask (Python)
- ML Libraries: scikit-learn, pandas, numpy
- Frontend: HTML, Bootstrap 5
- Deployment: Docker on Hugging Face Spaces
