Finally a '_predict_single' method as mentioned it predicts the class label for a single data point This is done by: 1. Calculating the distance between one point to all training examples 2. Selecting the k-nearest Neighbours, & returning the most common class label among them
Implementing _predict_single Method for KNN Classification
By
–
Leave a Reply