Skip to main content
Independent Digital Museum of Artificial Intelligence · Laboratory
Accessibility

These choices are saved only on this device.

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 locally

Classification 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

ClassXYAction

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.