-
K-Nearest Neighbors (KNN)MLAI/Classification 2020. 1. 20. 20:49
1. Overview
K nearest neighbors is a simple algorithm that stores all available cases and classifies new cases based on a similarity measure (e.g., distance functions)
2. Description
2.1 Procedure
- Step 1: Choose the number K of neighbors
- Step 2: Take the K nearest neighbors of the new data point, according to the Euclidean distance
- Step 3: Among these K neighbors, count the number of data points in each category
- Step 4: Assign the new data point to the category where you counted the most neighbors
3. Reference
https://en.wikipedia.org/wiki/K-nearest_neighbors_algorithm
https://en.wikipedia.org/wiki/K-nearest_neighbors_algorithm
'MLAI > Classification' 카테고리의 다른 글
Decision Tree (0) 2020.01.21 Kernel SVM (0) 2020.01.21 Support Vector Machine (SVM) (0) 2020.01.20 Naive Bayes classifier (0) 2019.10.06 Hidden Markov Model(HMM) (0) 2019.10.04