Pick a dataset
Six generated shapes, or make your own by drawing points or uploading a CSV
(x1,x2,label columns).
Pick a class below, then draw on the plot in step 3 — click or drag to add points.
x1,x2,labelPick how it learns
Each one is real, hand-computed math — nothing here is a pretrained or simulated model.
Watch it draw the line
The background shading is the model's own confidence at every point in the space — computed on a real 100×100 grid, not interpolated between a handful of samples.
How this actually works — for anyone curious, no math background needed
Every dataset here starts from a seeded random-number generator — the same "random" numbers come out every time for a given seed, which is what makes a short seed alone enough to reproduce a whole dataset in a shareable link, without ever sending the actual points. Every model is evaluated across a real 100×100 grid to paint the background — 10,000 real predictions per render, not a guess filled in between a handful of samples.
Linear Regression, as a classifier
Fits the single straight line that best fits the points, solved directly in one step — no trial and error. It was actually built to minimize distance-to-the-line, not to sort two classes apart, and is only being repurposed here as a classifier — which is exactly why it tends to fail hardest on anything that isn't already close to a straight line.
Logistic Regression
The same idea as above — a straight-line score — but this time actually trained, step by step, specifically to separate the two classes, and squashed into a 0-100% confidence instead of a raw number. Still fundamentally a straight line underneath, just a properly-trained one.
Linear classifier, hinge loss
Another straight-line model, trained a different way (the Pegasos algorithm) that pushes the line to sit with as much breathing room as possible between the two classes, not just anywhere that separates them. Deliberately not called "SVM" — a true support vector machine works in a fundamentally different way (see below); this is a similar-looking straight line trained toward a similar goal, not the same algorithm.
SVM (RBF kernel)
The model above earns the name "SVM" this one deliberately avoids. Instead of one straight line, it measures how "similar" a new point is to every point it was trained on, and only a subset of those training points — the ones that were genuinely hard to classify — end up mattering to the final answer at all (that subset is the literal "support vectors"). How "local" that similarity is (called gamma) and how much breathing room it demands between the two classes are both fixed at values tuned to work well across most shapes here, rather than left as sliders to tune by hand.
k-Nearest Neighbors
No training step at all — the "model" is just the stored points. To classify anywhere, find
the k closest real data points and take a vote. It's the one model here that
genuinely never generalizes past its own data — turn k down to 1 and watch the
boundary trace every single point's own tiny neighborhood.
Gaussian Naive Bayes
The one properly probabilistic model here — everything else either draws a boundary directly or votes; this one instead learns roughly what a "typical" point in each class looks like (its average position and how spread out it is), then asks a new point which typical shape it resembles more. Its boundary curves in a different way than logistic regression's whenever the two classes are spread out differently — a real consequence of it modeling the data itself, not just the line between the two groups.
Random Forest
Grows a whole crowd of simple decision trees, each shown a slightly different random slice of the same data, and lets them vote. Each individual tree can only ever cut the space with straight horizontal or vertical lines — which is exactly why the final boundary looks stepped and blocky rather than smooth, even though the crowd's combined vote is a real, more nuanced result than any one tree could give alone.
Neural Network
The one model here that actually learns in layers — your points feed into a first layer of small units, whose output feeds into the next layer, and so on, each layer combining what the one before it found into something a bit more refined, until a final layer turns that into a class call. Trained live via real backpropagation, accelerated in your browser through TensorFlow.js, running for as many passes over the data as it takes to stop improving (capped at 250, so it can't run forever). The diagram next to the sliders redraws instantly when you change the layer count or width, and lights up with the network's real trained connections (blue vs. rust) once a training run finishes — that's not decorative, it's the actual numbers the network learned.
The share link and QR code
The dataset type, PRNG seed, point count, selected model, and every one of its
hyperparameters are packed into a small byte payload, base64url-encoded into this page's own
URL — the same scheme Echo State and Inkling already use for their own share links. A
drawn-by-hand or uploaded dataset has no seed to replay, so its actual points are quantized
(one byte each for x1/x2, one for the label) and packed in
afterward instead — still small enough to fit comfortably in a QR code even at a few hundred
points. The QR itself is generated by the same vendored qrcode.min.js library
already sitting in those two tools' own folders.