Skip to content
← All projects

Student Risk Early Warning

Flags at-risk students before final grades and explains why, in a one-screen D3 dashboard.

Solo · analysis pipeline and dashboard · 2026 · Live

Student Risk Early Warning overview

01 · The problem

The problem

Schools learn a student failed only when the final grade is issued. The question was whether earlier signals (midterm grades, past failures, absences, lifestyle) can flag at-risk students in time to act, and explain why.

02 · The data

The data

UCI Student Performance (Cortez and Silva, 2008): 1,044 students from two Portuguese schools in Mathematics and Portuguese, 33 attributes and three grade periods. A student is at risk when the final grade is below 10 of 20, a 22% minority class.

03 · The approach

The approach

Six research questions, one per dashboard card: Pearson correlation and Random Forest importance for key drivers, OLS scatter, K-means personas (k = 3), a 200-tree Random Forest with class weighting against logistic regression and decision-tree baselines, 5-fold cross-validation, subject-stratified models and a gender fairness audit. Recall leads the model card because a missed student is the real cost.

04 · The results

The results

Random Forest recall 82.6% on a 209-student hold-out (38 of 46 at-risk students caught), F1 80.9%, cross-validated recall 79.1% ± 8.1 pp. The final-grade distribution is bimodal: 53 students (5.1%) withdrew. A Social Risk persona carries 42.1% at-risk in Mathematics versus 21.3% in Portuguese. Six linked D3 charts fit one 1440 x 900 screen with no build step.

05 · Why it matters

Why it matters

Shows model choices driven by the use case: recall over accuracy, honest fairness numbers, and a dashboard a teacher can read in one glance.

Gallery

Dark mode: six linked charts on one screen
Light mode

Through the DABM lens

DData
1,044 students · grades, attendance and lifestyle
AAgent
teachers and advisers deciding who needs help before finals
BBehavior
midterm drops, past failures and absences that precede failing
MModeling
class-weighted random forest · K-means personas · fairness audit

Stack

  • Python
  • scikit-learn
  • pandas
  • D3.js
  • JavaScript
  • Vercel

A fuller case study for this project is coming soon.