Tip-Off
Predicts NBA winners, margins and calibrated win probabilities.
67.5% winner accuracy, against 55.2% for always picking the home team. Full 2025–26 regular season, 1,225 games the model never trained on.
- Role
- Solo project for Michigan Edge, the University of Michigan sports analytics club: data, features, model and calibration, the Streamlit app and the weekly data job.
- Stack
- Python, scikit-learn, Streamlit, Plotly, Docker
- Year
- 2026
The demo's server sleeps when idle, so its first load can take up to 67 seconds.
The live app shows a daily slate from the NBA schedule: one card per game with the TV network, tip-off time, arena and the model's pick, written as a margin and a probability. You can step through game days or follow one team. Teams and Players pages chart power rankings, offense against defense, and each rotation player's profile.

Key features and results
Each prediction answers three questions: who wins, by how many points, and how sure the model is. On the full 2025–26 regular season, scored only on games it never trained on, it picked 67.5% of winners against 55.2% for always picking the home team, and its margins were off by 11.91 points on average against 13.40 for a constant home-court edge. Any two teams can be compared, with an adjustment for players on the injury report.

Architecture
Game results and player stats come from the NBA API; rosters, the schedule and injuries come from ESPN, refreshed every Monday by a GitHub Actions job that commits them. Every feature is computed only from games played before the one being predicted: season-to-date margin, last-10 form, home and road splits, rest days and back-to-backs. A random forest predicts the margin, and a logistic calibrator fit on held-out predictions turns it into a win probability. Training is walk-forward, the app calls the same prediction code as the command line, and Docker trains and predicts in one command.

Origins
It began as a folder of scripts and spreadsheets: data gathering, an injury tracker, a betting calculator and an accuracy tracker. The confidence it reported came from a hand-tuned formula. The first real change after moving it into git, on 31 August 2026, fixed data leakage: features became point-in-time, validation became walk-forward, and calibrated probabilities replaced the formula. The demo, logos and weekly data job came after.
