The objective is to predict whether a patient has or will develop heart disease based on several medical attributes.
| Variable | Description |
|---|---|
| age | Age of the patient |
| sex | Gender of the patient (0: Female, 1: Male) |
| BP | Blood pressure of the patient |
| cholestrol | Cholesterol level of the patient |
| heart disease | Target variable indicating presence of heart disease (0: No, 1: Yes) |
Decision Tree and Random Forest algorithms were utilized for building the predictive models.
The models provided insights into the significant factors influencing heart disease prediction. Age was identified as the most important feature, indicating its strong influence on the presence of heart disease.
GridSearchCV was employed for hyperparameter tuning to optimize model performance.
Graphviz was utilized to visualize decision trees for better interpretation of the models.
- pandas
- numpy
- scikit-learn
- matplotlib
- seaborn
- graphviz
- Ipython
- six
- pydotplus