Laboratory · Interactive exhibit LAB-05
A tiny classifier that changes when the data changes
Move the new point, add examples to either category, and watch a 3-nearest-neighbours classifier change its decision.
Algorithm: real k-NN with k = 3, running locallyClassification field
Click or tap the plot to move the new point. With a keyboard use the arrow keys and Enter to classify.
The tiny dataset
| Class | X | Y | Action |
|---|
k-NN does not learn weights like a neural network. It compares a new point with labelled examples and lets the nearest neighbours vote.
Documentation
Nearest-neighbour classification has a long history in pattern recognition. This exhibit uses Euclidean distance and three neighbours to make dependence on training examples visible.
Curatorial note: The plot is synthetic. The axes do not represent human traits or a real-world decision.