Machine Learning KNN Presentation
Machine Learning KNN Presentation
Neighbor
Back Ground
Prepared By
Anand Bhosale
Supervised Unsupervised
X1 X2 Class X1 X2
10 100 Square 10 100
2 4 Root 2 4
Distance
Distance
Distances
the distance s
between two Hammin
g
instances Distance
Minkows
ki
distance
Distances
X X y
y z
Distance
Hamming Distance
Distances Measure
d(x , y) = |x – y|TSxy1|x – y|
Nearest Neighbor and Exemplar
Exemplar
• Arithmetic Mean
• Geometric Mean
• Medoid
• Centroid
Arithmetic Mean
Geometric Mean
p
q
K-NN
K=5
K-NN
P1 7 7 BAD
P2 7 4 BAD
P3 3 4 GOOD
P4 1 4 GOOD
KNN Example
P1 P2 P3 P4