http://localhost:8501


πŸ“ Project Architecture

staywell/
β”‚
β”œβ”€β”€ app.py                          # Main Streamlit application
β”œβ”€β”€ config.py                       # Model configuration & weights
β”œβ”€β”€ requirements.txt                # Python dependencies
β”‚
β”œβ”€β”€ core/                           # Statistical Engine
β”‚   β”œβ”€β”€ validation.py              # Input validation & constraints
β”‚   β”œβ”€β”€ scoring_engine.py          # Burnout score calculation
β”‚   β”œβ”€β”€ peer_engine.py             # Peer comparison statistics
β”‚   └── statistical_analysis.py    # Statistical analysis functions
β”‚
β”œβ”€β”€ explainability/                 # Explainability Modules
β”‚   β”œβ”€β”€ contribution.py            # Factor contribution analysis
β”‚   └── what_if.py                 # Scenario simulation engine
β”‚
β”œβ”€β”€ ui/                            # User Interface
β”‚   β”œβ”€β”€ dashboard.py               # Visualization components
β”‚   └── theme.py                   # UI theme configuration
β”‚
└── data/                          # Data Files
    β”œβ”€β”€ sample_students.csv        # Sample dataset
    └── test_invalid.csv           # Validation test data

πŸ“Š Data Format

CSV Structure

name,sleep_hours,study_hours,screen_time,stress_level,attendance
Alice Johnson,7.0,6.0,4.0,3,90
Bob Smith,8.0,5.0,3.0,2,95
Charlie Brown,6.0,7.0,5.0,4,82

Column Specifications

ColumnTypeRangeDescriptionnameString-Student identifier (optional)sleep_hoursFloat0-24Average daily sleep durationstudy_hoursFloat0-24Average daily study timescreen_timeFloat0-24Average daily recreational screen timestress_levelInteger1-5Self-reported stress (1=Low, 5=High)attendanceInteger0-100Class attendance percentage

⚠️ Important Constraint

24-Hour Rule: sleep_hours + study_hours + screen_time ≀ 24

Records violating this constraint are automatically filtered with notification.


🎯 Use Cases

For Educators

For Counselors

For Administrators

For Researchers


πŸ”’ Ethical Framework

Core Principles

  1. Transparency: All calculations are fully explainable

  2. Privacy: Confidential data handling required

  3. Support-Focused: Results guide help, not punishment

  4. Human Oversight: Professional judgment essential

  5. Not Diagnostic: Early warning only, not clinical diagnosis

Responsible Use


πŸ› οΈ Customization

Adjust Risk Weights

Edit config.py:

WEIGHTS = {
    "sleep": 0.30,      # Sleep deficit weight
    "stress": 0.20,     # Stress level weight
    "screen": 0.20,     # Screen time weight
    "study": 0.15,      # Study hours weight
    "attendance": 0.15  # Attendance weight
}

Modify Risk Thresholds

Edit core/scoring_engine.py:

def risk_label(score):
    if score < 0.3:     # Low risk threshold
        return "🟒 Low Risk"
    elif score < 0.6:   # Moderate risk threshold
        return "🟑 Moderate Risk"
    return "πŸ”΄ Elevated Risk"

Customize Visualizations

Edit ui/dashboard.py to modify charts, colors, and layouts.


πŸ“ˆ Domain-2 Compliance

βœ… Pure Statistical Modeling - No machine learning black boxes
βœ… Descriptive Analysis - Comprehensive statistical summaries
βœ… Correlation Analysis - Factor relationship identification
βœ… Regression-Based Scoring - Weighted linear model
βœ… Clear Risk Thresholds - Statistically justified classifications
βœ… Full Documentation - Complete methodology report
βœ… Explainable Results - Transparent calculations
βœ… Source Code Provided - Open and auditable


πŸ§ͺ Testing

Test with Invalid Data

# Upload data/test_invalid.csv to see validation in action
# Contains records that violate 24-hour constraint

Manual Entry Testing

  1. Select "Manual Entry" mode

  2. Adjust time values to exceed 24 hours

  3. Observe real-time validation feedback

  4. Correct values to see risk assessment


πŸ“š Documentation


🀝 Contributing

This project is developed for educational purposes. Suggestions for improvements:

  1. Additional risk factors

  2. Enhanced visualizations

  3. Export functionality

  4. Multi-language support

  5. Mobile responsiveness


πŸ“„ License

Educational project developed for Domain 2: Data & Statistical Modelling.


πŸ™ Acknowledgments


πŸ“ž Support

For questions, issues, or suggestions:


⚠️ Disclaimer

STAYWELL is an early warning system, not a diagnostic tool.

Always involve qualified mental health professionals for student support. This system provides statistical guidance to complement, not replace, professional judgment.


Built with ❀️ for Student Wellness

Empowering Early Intervention Through Statistical Intelligence

" /> http://localhost:8501


πŸ“ Project Architecture

staywell/
β”‚
β”œβ”€β”€ app.py                          # Main Streamlit application
β”œβ”€β”€ config.py                       # Model configuration & weights
β”œβ”€β”€ requirements.txt                # Python dependencies
β”‚
β”œβ”€β”€ core/                           # Statistical Engine
β”‚   β”œβ”€β”€ validation.py              # Input validation & constraints
β”‚   β”œβ”€β”€ scoring_engine.py          # Burnout score calculation
β”‚   β”œβ”€β”€ peer_engine.py             # Peer comparison statistics
β”‚   └── statistical_analysis.py    # Statistical analysis functions
β”‚
β”œβ”€β”€ explainability/                 # Explainability Modules
β”‚   β”œβ”€β”€ contribution.py            # Factor contribution analysis
β”‚   └── what_if.py                 # Scenario simulation engine
β”‚
β”œβ”€β”€ ui/                            # User Interface
β”‚   β”œβ”€β”€ dashboard.py               # Visualization components
β”‚   └── theme.py                   # UI theme configuration
β”‚
└── data/                          # Data Files
    β”œβ”€β”€ sample_students.csv        # Sample dataset
    └── test_invalid.csv           # Validation test data

πŸ“Š Data Format

CSV Structure

name,sleep_hours,study_hours,screen_time,stress_level,attendance
Alice Johnson,7.0,6.0,4.0,3,90
Bob Smith,8.0,5.0,3.0,2,95
Charlie Brown,6.0,7.0,5.0,4,82

Column Specifications

ColumnTypeRangeDescriptionnameString-Student identifier (optional)sleep_hoursFloat0-24Average daily sleep durationstudy_hoursFloat0-24Average daily study timescreen_timeFloat0-24Average daily recreational screen timestress_levelInteger1-5Self-reported stress (1=Low, 5=High)attendanceInteger0-100Class attendance percentage

⚠️ Important Constraint

24-Hour Rule: sleep_hours + study_hours + screen_time ≀ 24

Records violating this constraint are automatically filtered with notification.


🎯 Use Cases

For Educators

For Counselors

For Administrators

For Researchers


πŸ”’ Ethical Framework

Core Principles

  1. Transparency: All calculations are fully explainable

  2. Privacy: Confidential data handling required

  3. Support-Focused: Results guide help, not punishment

  4. Human Oversight: Professional judgment essential

  5. Not Diagnostic: Early warning only, not clinical diagnosis

Responsible Use


πŸ› οΈ Customization

Adjust Risk Weights

Edit config.py:

WEIGHTS = {
    "sleep": 0.30,      # Sleep deficit weight
    "stress": 0.20,     # Stress level weight
    "screen": 0.20,     # Screen time weight
    "study": 0.15,      # Study hours weight
    "attendance": 0.15  # Attendance weight
}

Modify Risk Thresholds

Edit core/scoring_engine.py:

def risk_label(score):
    if score < 0.3:     # Low risk threshold
        return "🟒 Low Risk"
    elif score < 0.6:   # Moderate risk threshold
        return "🟑 Moderate Risk"
    return "πŸ”΄ Elevated Risk"

Customize Visualizations

Edit ui/dashboard.py to modify charts, colors, and layouts.


πŸ“ˆ Domain-2 Compliance

βœ… Pure Statistical Modeling - No machine learning black boxes
βœ… Descriptive Analysis - Comprehensive statistical summaries
βœ… Correlation Analysis - Factor relationship identification
βœ… Regression-Based Scoring - Weighted linear model
βœ… Clear Risk Thresholds - Statistically justified classifications
βœ… Full Documentation - Complete methodology report
βœ… Explainable Results - Transparent calculations
βœ… Source Code Provided - Open and auditable


πŸ§ͺ Testing

Test with Invalid Data

# Upload data/test_invalid.csv to see validation in action
# Contains records that violate 24-hour constraint

Manual Entry Testing

  1. Select "Manual Entry" mode

  2. Adjust time values to exceed 24 hours

  3. Observe real-time validation feedback

  4. Correct values to see risk assessment


πŸ“š Documentation


🀝 Contributing

This project is developed for educational purposes. Suggestions for improvements:

  1. Additional risk factors

  2. Enhanced visualizations

  3. Export functionality

  4. Multi-language support

  5. Mobile responsiveness


πŸ“„ License

Educational project developed for Domain 2: Data & Statistical Modelling.


πŸ™ Acknowledgments


πŸ“ž Support

For questions, issues, or suggestions:


⚠️ Disclaimer

STAYWELL is an early warning system, not a diagnostic tool.

Always involve qualified mental health professionals for student support. This system provides statistical guidance to complement, not replace, professional judgment.


Built with ❀️ for Student Wellness

Empowering Early Intervention Through Statistical Intelligence

" /> http://localhost:8501


πŸ“ Project Architecture

staywell/
β”‚
β”œβ”€β”€ app.py                          # Main Streamlit application
β”œβ”€β”€ config.py                       # Model configuration & weights
β”œβ”€β”€ requirements.txt                # Python dependencies
β”‚
β”œβ”€β”€ core/                           # Statistical Engine
β”‚   β”œβ”€β”€ validation.py              # Input validation & constraints
β”‚   β”œβ”€β”€ scoring_engine.py          # Burnout score calculation
β”‚   β”œβ”€β”€ peer_engine.py             # Peer comparison statistics
β”‚   └── statistical_analysis.py    # Statistical analysis functions
β”‚
β”œβ”€β”€ explainability/                 # Explainability Modules
β”‚   β”œβ”€β”€ contribution.py            # Factor contribution analysis
β”‚   └── what_if.py                 # Scenario simulation engine
β”‚
β”œβ”€β”€ ui/                            # User Interface
β”‚   β”œβ”€β”€ dashboard.py               # Visualization components
β”‚   └── theme.py                   # UI theme configuration
β”‚
└── data/                          # Data Files
    β”œβ”€β”€ sample_students.csv        # Sample dataset
    └── test_invalid.csv           # Validation test data

πŸ“Š Data Format

CSV Structure

name,sleep_hours,study_hours,screen_time,stress_level,attendance
Alice Johnson,7.0,6.0,4.0,3,90
Bob Smith,8.0,5.0,3.0,2,95
Charlie Brown,6.0,7.0,5.0,4,82

Column Specifications

ColumnTypeRangeDescriptionnameString-Student identifier (optional)sleep_hoursFloat0-24Average daily sleep durationstudy_hoursFloat0-24Average daily study timescreen_timeFloat0-24Average daily recreational screen timestress_levelInteger1-5Self-reported stress (1=Low, 5=High)attendanceInteger0-100Class attendance percentage

⚠️ Important Constraint

24-Hour Rule: sleep_hours + study_hours + screen_time ≀ 24

Records violating this constraint are automatically filtered with notification.


🎯 Use Cases

For Educators

For Counselors

For Administrators

For Researchers


πŸ”’ Ethical Framework

Core Principles

  1. Transparency: All calculations are fully explainable

  2. Privacy: Confidential data handling required

  3. Support-Focused: Results guide help, not punishment

  4. Human Oversight: Professional judgment essential

  5. Not Diagnostic: Early warning only, not clinical diagnosis

Responsible Use


πŸ› οΈ Customization

Adjust Risk Weights

Edit config.py:

WEIGHTS = {
    "sleep": 0.30,      # Sleep deficit weight
    "stress": 0.20,     # Stress level weight
    "screen": 0.20,     # Screen time weight
    "study": 0.15,      # Study hours weight
    "attendance": 0.15  # Attendance weight
}

Modify Risk Thresholds

Edit core/scoring_engine.py:

def risk_label(score):
    if score < 0.3:     # Low risk threshold
        return "🟒 Low Risk"
    elif score < 0.6:   # Moderate risk threshold
        return "🟑 Moderate Risk"
    return "πŸ”΄ Elevated Risk"

Customize Visualizations

Edit ui/dashboard.py to modify charts, colors, and layouts.


πŸ“ˆ Domain-2 Compliance

βœ… Pure Statistical Modeling - No machine learning black boxes
βœ… Descriptive Analysis - Comprehensive statistical summaries
βœ… Correlation Analysis - Factor relationship identification
βœ… Regression-Based Scoring - Weighted linear model
βœ… Clear Risk Thresholds - Statistically justified classifications
βœ… Full Documentation - Complete methodology report
βœ… Explainable Results - Transparent calculations
βœ… Source Code Provided - Open and auditable


πŸ§ͺ Testing

Test with Invalid Data

# Upload data/test_invalid.csv to see validation in action
# Contains records that violate 24-hour constraint

Manual Entry Testing

  1. Select "Manual Entry" mode

  2. Adjust time values to exceed 24 hours

  3. Observe real-time validation feedback

  4. Correct values to see risk assessment


πŸ“š Documentation


🀝 Contributing

This project is developed for educational purposes. Suggestions for improvements:

  1. Additional risk factors

  2. Enhanced visualizations

  3. Export functionality

  4. Multi-language support

  5. Mobile responsiveness


πŸ“„ License

Educational project developed for Domain 2: Data & Statistical Modelling.


πŸ™ Acknowledgments


πŸ“ž Support

For questions, issues, or suggestions:


⚠️ Disclaimer

STAYWELL is an early warning system, not a diagnostic tool.

Always involve qualified mental health professionals for student support. This system provides statistical guidance to complement, not replace, professional judgment.


Built with ❀️ for Student Wellness

Empowering Early Intervention Through Statistical Intelligence

" /> StayWell Skip to Main Content

StayWell

Early Detection of Academic Burnout Through Statistical Analysis

Description

🌱 STAYWELL

Early Detection of Academic Burnout Through Statistical Analysis

A Statistical Risk Assessment Platform Powered by Pure Mathematical Modeling

🎯 Overview

STAYWELL is an evidence-based early warning system designed to identify academic burnout risk among students using transparent statistical analysis. Unlike black-box machine learning approaches, our system employs pure mathematical modeling with full explainability and ethical compliance.

The Problem

Academic burnout affects student mental health, performance, and well-being. Early detection enables timely intervention and support.

Our Solution

A statistical risk assessment platform that analyzes measurable lifestyle indicators:

  • πŸ›οΈ Sleep patterns

  • πŸ“š Study load

  • πŸ“± Screen time

  • 😰 Stress levels

  • πŸ“Š Academic engagement


✨ Key Features

πŸ“₯ Multiple Input Methods

  • CSV Upload: Batch analysis for entire cohorts

  • Manual Entry: Individual student assessment with real-time validation

  • Sample Data: Pre-loaded demonstration dataset

πŸ“Š Comprehensive Analytics

  • Risk Overview: Distribution analysis and summary statistics

  • Statistical Analysis: Correlations, distributions, descriptive statistics

  • Individual Assessment: Per-student risk breakdown with factor contributions

  • Scenario Simulation: What-if analysis for intervention planning

  • Full Transparency: Complete methodology documentation

🎨 Visual Intelligence

  • Risk distribution bar charts

  • Time allocation visualizations

  • Factor contribution breakdowns

  • Correlation heatmaps

  • Distribution histograms

  • Color-coded risk indicators

πŸ” Explainability First

  • Transparent calculations

  • Factor contribution analysis

  • Statistical justifications

  • Clear risk thresholds

  • No black-box models


πŸ”¬ Statistical Methodology

Burnout Score Model

Weighted Linear Regression:

Burnout Score = Ξ£ (Weight_i Γ— Normalized_Factor_i)

Risk Factors & Weights

FactorWeightRationaleSleep Deficit30%Most critical for mental health and cognitive functionStress Level20%Direct indicator of psychological strainScreen Time20%Proxy for digital fatigue and time managementStudy Hours15%Excessive studying can lead to burnoutAttendance15%Low attendance indicates disengagement

Normalization Techniques

  1. Sleep Deficit: max(0, (7 - sleep_hours) / 7)

  2. Stress Level: stress_level / 5

  3. Screen Time: screen_time / 10

  4. Study Hours: study_hours / 10

  5. Attendance: (100 - attendance) / 100

Risk Classification

  • 🟒 Low Risk: Score < 0.30

  • 🟑 Moderate Risk: 0.30 ≀ Score < 0.60

  • πŸ”΄ Elevated Risk: Score β‰₯ 0.60

Statistical Techniques

  1. Descriptive Statistics: Mean, median, standard deviation, variance

  2. Correlation Analysis: Pearson correlation coefficients

  3. Percentile Analysis: Peer comparison using empirical distribution

  4. Sensitivity Analysis: What-if scenario testing

  5. Factor Decomposition: Proportional risk contribution


πŸš€ Quick Start

Prerequisites

Python 3.8+
pip package manager

Installation

# Clone the repository
git clone <repository-url>
cd staywell

# Install dependencies
pip install -r requirements.txt

Run Application

streamlit run app.py

Access at: http://localhost:8501


πŸ“ Project Architecture

staywell/
β”‚
β”œβ”€β”€ app.py                          # Main Streamlit application
β”œβ”€β”€ config.py                       # Model configuration & weights
β”œβ”€β”€ requirements.txt                # Python dependencies
β”‚
β”œβ”€β”€ core/                           # Statistical Engine
β”‚   β”œβ”€β”€ validation.py              # Input validation & constraints
β”‚   β”œβ”€β”€ scoring_engine.py          # Burnout score calculation
β”‚   β”œβ”€β”€ peer_engine.py             # Peer comparison statistics
β”‚   └── statistical_analysis.py    # Statistical analysis functions
β”‚
β”œβ”€β”€ explainability/                 # Explainability Modules
β”‚   β”œβ”€β”€ contribution.py            # Factor contribution analysis
β”‚   └── what_if.py                 # Scenario simulation engine
β”‚
β”œβ”€β”€ ui/                            # User Interface
β”‚   β”œβ”€β”€ dashboard.py               # Visualization components
β”‚   └── theme.py                   # UI theme configuration
β”‚
└── data/                          # Data Files
    β”œβ”€β”€ sample_students.csv        # Sample dataset
    └── test_invalid.csv           # Validation test data

πŸ“Š Data Format

CSV Structure

name,sleep_hours,study_hours,screen_time,stress_level,attendance
Alice Johnson,7.0,6.0,4.0,3,90
Bob Smith,8.0,5.0,3.0,2,95
Charlie Brown,6.0,7.0,5.0,4,82

Column Specifications

ColumnTypeRangeDescriptionnameString-Student identifier (optional)sleep_hoursFloat0-24Average daily sleep durationstudy_hoursFloat0-24Average daily study timescreen_timeFloat0-24Average daily recreational screen timestress_levelInteger1-5Self-reported stress (1=Low, 5=High)attendanceInteger0-100Class attendance percentage

⚠️ Important Constraint

24-Hour Rule: sleep_hours + study_hours + screen_time ≀ 24

Records violating this constraint are automatically filtered with notification.


🎯 Use Cases

For Educators

  • Monitor cohort mental health trends

  • Identify at-risk students early

  • Plan targeted interventions

  • Track effectiveness of support programs

For Counselors

  • Prioritize student outreach

  • Understand risk factor patterns

  • Simulate intervention impacts

  • Support evidence-based counseling

For Administrators

  • Assess institutional wellness

  • Allocate support resources

  • Evaluate policy effectiveness

  • Generate statistical reports

For Researchers

  • Analyze burnout patterns

  • Study factor correlations

  • Test intervention strategies

  • Validate statistical models


πŸ”’ Ethical Framework

Core Principles

  1. Transparency: All calculations are fully explainable

  2. Privacy: Confidential data handling required

  3. Support-Focused: Results guide help, not punishment

  4. Human Oversight: Professional judgment essential

  5. Not Diagnostic: Early warning only, not clinical diagnosis

Responsible Use

  • βœ… Use for early identification and support

  • βœ… Combine with professional counseling

  • βœ… Maintain student privacy

  • βœ… Focus on intervention, not labeling

  • ❌ Do not use as sole diagnostic tool

  • ❌ Do not stigmatize high-risk students

  • ❌ Do not share results without consent


πŸ› οΈ Customization

Adjust Risk Weights

Edit config.py:

WEIGHTS = {
    "sleep": 0.30,      # Sleep deficit weight
    "stress": 0.20,     # Stress level weight
    "screen": 0.20,     # Screen time weight
    "study": 0.15,      # Study hours weight
    "attendance": 0.15  # Attendance weight
}

Modify Risk Thresholds

Edit core/scoring_engine.py:

def risk_label(score):
    if score < 0.3:     # Low risk threshold
        return "🟒 Low Risk"
    elif score < 0.6:   # Moderate risk threshold
        return "🟑 Moderate Risk"
    return "πŸ”΄ Elevated Risk"

Customize Visualizations

Edit ui/dashboard.py to modify charts, colors, and layouts.


πŸ“ˆ Domain-2 Compliance

βœ… Pure Statistical Modeling - No machine learning black boxes
βœ… Descriptive Analysis - Comprehensive statistical summaries
βœ… Correlation Analysis - Factor relationship identification
βœ… Regression-Based Scoring - Weighted linear model
βœ… Clear Risk Thresholds - Statistically justified classifications
βœ… Full Documentation - Complete methodology report
βœ… Explainable Results - Transparent calculations
βœ… Source Code Provided - Open and auditable


πŸ§ͺ Testing

Test with Invalid Data

# Upload data/test_invalid.csv to see validation in action
# Contains records that violate 24-hour constraint

Manual Entry Testing

  1. Select "Manual Entry" mode

  2. Adjust time values to exceed 24 hours

  3. Observe real-time validation feedback

  4. Correct values to see risk assessment


πŸ“š Documentation

  • METHODOLOGY.md - Detailed statistical methodology

  • AI_USAGE_SUMMARY.md - AI assistance documentation

  • SIMPLE_UPDATE.md - Recent updates and changes

  • Inline Comments - Code-level documentation


🀝 Contributing

This project is developed for educational purposes. Suggestions for improvements:

  1. Additional risk factors

  2. Enhanced visualizations

  3. Export functionality

  4. Multi-language support

  5. Mobile responsiveness


πŸ“„ License

Educational project developed for Domain 2: Data & Statistical Modelling.


πŸ™ Acknowledgments

  • Statistical methods based on psychological research

  • Risk factors from academic burnout literature

  • Ethical guidelines from mental health best practices

  • UI/UX inspired by modern data platforms


πŸ“ž Support

For questions, issues, or suggestions:

  • Review inline code documentation

  • Check METHODOLOGY.md for detailed explanations

  • Examine sample data for format examples


⚠️ Disclaimer

STAYWELL is an early warning system, not a diagnostic tool.

Always involve qualified mental health professionals for student support. This system provides statistical guidance to complement, not replace, professional judgment.


Built with ❀️ for Student Wellness

Empowering Early Intervention Through Statistical Intelligence

Issues & PRs Board
No issues or pull requests added.