Josh Hirschkorn
--:--:--
All projects

Apr 2022 · May 2022

Student Grade Prediction with Linear Regression

Predicting final grades from prior performance, study time and absences.

  • Python
  • scikit-learn
  • Pandas
  • Matplotlib
Repository
Best run accuracy
93.8%
Training runs
30

A linear regression model predicting students’ final grades from earlier grades, study time, number of past failures and absences.

Model and selection

The dataset is reduced to the relevant numerical features, then the model is trained across 30 runs and the best-performing version, at 93.8% accuracy, is selected and saved with pickle for reuse. Training repeatedly and keeping the best run is a blunt instrument, but it does expose how much the result depends on the split.

Interpretation

The regression coefficients and intercept are the useful output, since they show how much weight each feature carries. A scatter plot of second-period grades against final grades makes the dominant signal obvious: prior performance explains most of the outcome, and the remaining features add comparatively little.