K Nearest Flashcards

1
Q

K Nearest

A

Store the traaining records only, no model computed.
Simplest form of learning
Lazy evalutaion
Accurate but Slow

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Elements

A

Training Dataset
Similarity Function
Value k of number neighbors

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Similarity Measure

A

Euclidean = sqrt(sum(pi-qi)^2)
L-norm = sum(|xi-yi|^r)^(1/r)
Manhattan = sum(|xi-yi|)
Linf-norm = max|xi-yi|
Cosine dist = arcccos(sqrt(xiyi)/(sqrt(xi^2)sqrt(yi)^2)) [0,180]
Jaccard Distance = 1-J(x,y) J(x,y)=|x inters y|/|x u y|
Hamming distance = n - m / n m = matching components

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

KD-Trees

A

Split the space hierarchically using a tree
Split point close to the mean
Inneeficient when number of attributes too large

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Ball Trees

A

Hyperspheres

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

K-nearest neighbor Regression

A

Other regression models are parametric
Approximation function with weight vector
Nearest Neighbor fits each point locally

Given dataset (X1,Y1),(X2,Y2)….(Xn,Yn)
Given query point Xq
Yq computed as local interpolation of neighbor
How well did you know this?
1
Not at all
2
3
4
5
Perfectly