2D kernel classifier with random train/validation split
First add labeled 2D points by clicking in the left panel. Then click Random split to send each point
to either the training panel (left) or the validation panel (right). The classifier is fit only on the training set,
but its decision regions and boundary are shown on both panels. Training and validation classification error
are displayed underneath.
Training error: N/A
Validation error: N/A
class +1
class −1
decision boundary
How it works
Before splitting, all points live in the left panel and clicking there adds more points.
After splitting, the left panel shows only the training set and the right panel shows only the validation set.
Re-splitting keeps the same pooled points but changes which side they go to.
Suggested demo: load the concentric example, split, fit linear + logistic, then compare with
poly degree 2 or RBF.