knn
✓ Published0🌍 Public
BBcohn
Last edited Mar 11, 2016
Created on Mar 11, 2016
This interactive visualization shows a k-nearest neighbors (k-NN) decision boundary on a 2D scatterplot. Users can generate random labeled points, click to add their own, and adjust the zoom by dragging axis ticks. After specifying a number of neighbors, clicking “Find Decision Boundary” draws a steelblue contour line separating the classified regions, based on the current point distribution. The implementation uses D3 v3 with SVG rendering, custom mouse-drag interactions for axis scaling, and jQuery for input handling. The boundary is computed and drawn dynamically as the underlying points or zoom level changes.
AI-generated description