3.6 Feature Selection: k-Nearest Neighbors (k-NN)
The fourth method for addressing feature selection is the k-nearest neighbors (k-NN) method, which works by finding the k known training cases closest to a new case, and then combining (e.g., by averaging) those answers to estimate its value or class. If there are M input features, the cases are points in an M-dimensional space.
It is important to carefully consider the set of variables before using k-NN, but it can be worth the effort because k-NN can track unusual surfaces, is intuitive to explain, and no fitting is involved. Using a representative subset of a sample is helpful because k-NN estimation processing time increases nonlinearly with the number of cases.
Advantages of the KNN are that this method: |
Disadvantages of the KNN are that this method: |
|
|
© 2025 CFA Institute