๐ Click here to view the live dashboard
This project analyzes health-related data to predict the risk of lifestyle diseases based on an individual's health parameters. Users input basic health information such as blood pressure, heart rate, smoking status, BMI, and other lifestyle indicators, and the system analyzes this data to estimate potential disease risks.
The project also generates visual insights through a dashboard to help users better understand their health patterns and risk factors.
The goal of this project is to demonstrate how data analysis and predictive modeling can assist in early detection of lifestyle diseases and promote preventive healthcare.
- Analyze healthcare datasets to identify patterns related to lifestyle diseases.
- Predict disease risk based on user-provided health parameters.
- Provide data-driven health insights through visualization dashboards.
- Help users understand how their lifestyle factors affect their health.
โ Health data preprocessing and cleaning โ Lifestyle disease risk prediction using data analysis techniques โ User input system for personal health parameters โ Risk evaluation based on dataset insights โ Interactive health insights dashboard โ Data visualization for better understanding of health patterns
The backend trains and compares 6 machine learning models on the NHANES dataset (5,735 participants):
| Model | Accuracy | F1 Score | AUC-ROC |
|---|---|---|---|
| Logistic Regression | 95.12% | 0.9712 | 0.9777 |
| Decision Tree | 99.91% | 0.9995 | 0.9973 |
| Random Forest | 99.74% | 0.9984 | 1.0000 |
| Gradient Boosting โ | 99.91% | 0.9995 | 1.0000 |
| SVM | 97.04% | 0.9825 | 0.9943 |
| KNN | 96.34% | 0.9783 | 0.9881 |
Best Model: Gradient Boosting (AUC = 1.0000)
- Dataset: NHANES (National Health and Nutrition Examination Survey)
- Samples: 5,735 participants
- Features: 17 (including 5 engineered features)
- Train/Test Split: 80% / 20% stratified
- Cross-Validation: 5-Fold Stratified KFold
The system analyzes the following user inputs:
- Blood Pressure (Systolic & Diastolic)
- Heart Rate
- BMI
- Smoking Status
- Age
- Waist Circumference
- Physical Activity Level
- Other lifestyle-related indicators (based on dataset features)
Using these parameters, the system estimates the risk probability of lifestyle-related diseases.
The system provides:
- Disease risk estimation
- Health insights based on dataset trends
- Visual dashboard displaying:
- Health indicators
- Risk distribution
- Lifestyle impact on disease probability
- Python 3
- Pandas โ Data preprocessing and analysis
- NumPy โ Numerical operations
- Matplotlib / Seaborn โ Data visualization
- Scikit-learn โ Machine learning models
- SciPy โ Statistical analysis
- React โ Frontend framework
- Vite โ Build tool
- Recharts โ Interactive charts
- Vercel โ Deployment
git clone https://github.com/sam-coolshrestha/Health-Monitoring-System.git
cd Health-Monitoring-Systempip install pandas numpy matplotlib seaborn scikit-learn scipypython lifestyle_risk_model.pyThis will print all model results and generate 4 plots in an outputs/ folder.
cd dashboard
npm install
npm run devOpen http://localhost:5173 in your browser.
1๏ธโฃ Data Collection 2๏ธโฃ Data Preprocessing 3๏ธโฃ Exploratory Data Analysis (EDA) 4๏ธโฃ Feature Engineering 5๏ธโฃ Model Training & Evaluation 6๏ธโฃ Dashboard Visualization 7๏ธโฃ User Health Input System (Risk Calculator)
The NHANES dataset contains multiple health and lifestyle parameters analyzed to identify correlations between lifestyle habits and disease risks.
Key findings:
- 59.4% of participants are smokers โ largest single risk factor
- 71.2% are overweight or obese (BMI โฅ 25)
- Hypertension rate jumps from 13% (age 18โ30) to 59% (age 60+)
- BMI and waist circumference are nearly perfectly correlated (r = 0.91)
A future version aims to integrate OpenCV-based rehabilitation exercise monitoring, where:
- Patients perform rehabilitation exercises
- The system detects body posture using computer vision
- It provides feedback on whether exercises are performed correctly
This feature is currently proposed as a future enhancement and has not yet been implemented.
- Train deep learning models (Neural Networks)
- Improve accuracy of disease risk prediction
Integration with wearable devices for real-time health data.
Build a REST API so the dashboard can call the ML model directly in real time.
This project is open source and available under the MIT License.