As an instructor and learning analytics researcher, I often see students and practitioners run into the same hurdle when learning machine learning. We read about algorithms like Support Vector Machines, Random Forests, or Neural Networks, and we look at accuracy tables in papers. However, accuracy numbers alone do not show how each algorithm actually draws a boundary between student groups, or what happens to individual students when we adjust a parameter.
To address this, I extended Jo Chuang's original Machine Learning Playground into Machine Learning Playground 2.0 (Live App | GitHub Repository). It runs directly in the browser with no installation required, and it is designed for teaching and experimenting with classification in Learning Analytics (LA) and Educational Data Mining (EDM).
In this post, I walk through how I use the tool to compare 10 classifiers, inspect their parameters, test counterfactual interventions, and connect classification metrics to school resource decisions.
The main workspace centers on a 2D plot. Each point represents a student, classified as either On-Track or At-Risk along two numeric features, such as LMS engagement and assignment completion.
You can click directly on the blank canvas to plot your own points, or load one of three built-in educational datasets from the presets bar:
Higher Ed Retention (Linear Pattern): Students separate roughly along a diagonal line based on attendance/engagement and assignment completion.
K-12 Formative Mastery (L-Shaped Rule Pattern): Students succeed if either their diagnostic score or their practice volume is high, leaving an At-Risk corner where both are low.
Gaming the System (Enclosed Island Pattern): A cluster of students exhibiting rapid guessing and hint abuse sits inside a surrounding group of typical learners.
Main workspace of Machine Learning Playground 2.0 with a plotted student cohort.
Once a cohort is on the canvas, clicking through the 10 algorithms shows right away that not every classifier fits every pattern.
Linear models (Perceptron, Logistic Regression, Linear SVM): Draw a straight line across the 2D space. On the Higher Ed Retention preset, a straight boundary separates the two groups well. On the Gaming the System preset, a straight line fails because it cannot enclose a cluster surrounded on all sides.
Rule-based models (Decision Tree, Association Rules / CBA): Cut the space using horizontal and vertical thresholds (Decision Tree) or fixed grid intervals (CBA). On the K-12 Formative Mastery preset, these axis-aligned cuts match the L-shaped pass/fail logic directly.
Local, kernel, and ensemble models (KNN, Polynomial/RBF SVM, Random Forest, XGBoost, Neural Network): Form curved or enclosed boundaries that wrap around non-linear clusters.
Instead of switching through all 10 models one by one, you can also click Compare All Models in the toolbar to evaluate all 10 classifiers on the current dataset and rank them by F1 score and Accuracy.
Comparison of decision boundaries exported via Save PNG on the same student cohort.
Model Comparison table evaluating all 10 classifiers on the active cohort.
A common criticism of machine learning in education is that practitioners only see the final prediction without understanding what drives it. Below the canvas, the workspace includes two ways to examine the fitted model:
Algorithm-Specific Inspector: Depending on the selected algorithm, this panel shows the Decision Tree flowchart, KNN neighbor votes, Logistic Regression log-odds weights, SVM support vector counts, Naive Bayes group means and standard deviations, Random Forest or XGBoost feature split proportions, CBA IF-THEN rules, or ANN layer dimensions.
Counterfactual Boundary Analysis: This panel measures the smallest change in Feature X, Feature Y, or both combined that would move a selected At-Risk student across the decision boundary to On-Track. Moving the sliders lets you test how much improvement a student would need under that specific model.
Moving the cursor across the canvas also updates the Cursor Probe above the plot, showing the predicted class and risk probability at that coordinate.
Inspecting learned model parameters and testing counterfactual score changes.
In educational early-warning systems, two kinds of mistakes carry very different consequences. Flagging an On-Track student (a false positive) uses advisor outreach time. Missing an At-Risk student (a false negative) means a struggling learner receives no early support.
Below the inspector, the Classification & Evaluation Metrics section reports Accuracy, Sensitivity (Recall), Specificity, Precision, F1 Score, the 2x2 Confusion Matrix, and the empirical ROC curve with Area Under the Curve (AUC).
Next to those metrics, the Educational Resource & Policy Impact Planner translates false positives and false negatives into either staff hours or remediation dollars. If you select Logistic Regression and lower the Decision Threshold slider, you can watch Sensitivity rise while Specificity drops, and see how that threshold shift changes total resource cost.
Connecting confusion matrix errors and ROC thresholds to institutional resource costs.
Machine Learning Playground 2.0 is not meant to replace statistical programming in R or Python for real institutional datasets. Rather, it gives students and instructors a way to build intuition before writing code: to see why linear classifiers fail on enclosed clusters, why tree depth affects overfitting, and why selecting a decision threshold is a policy choice as much as a technical one.
You can try the application at https://taridwong.github.io/ml-playground-2.0/ or view the source code on GitHub.