Example of K Nearest Neighbors with Categorical Response
1.
Select Help > Sample Data and open Equity.jmp.
2.
Select Analyze > Predictive Modeling > K Nearest Neighbors.
3.
Select BAD and click Y, Response.
Because one of the potential predictors, DEBTINC, has many missing values that might be informative, you do not include it in your model.
4.
Select LOAN through CLNO and click X, Factor.
5.
Select Validation and click Validation.
6.
K Nearest Neighbors Report
8.
Next to Number of Neighbors, K, type 1.

Help created on 9/19/2017