

Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!


Machine Learning (CS 5350/CS 6350) 4 Mar 2008
Now begins our foray into unsupervised learning. Most unsupervised learning problems deal only with input data, typically considered as a matrix X ∈ RN^ ×D^ over N data points and D dimensions. There are no labels.
Clustering is the problem of grouping data according to similarity.
Typically one uses a distance metric to judge similarity (though this is not always required). A metric d must satisfy:
If (1) doesn’t hold, it is a pseudo-metric.
All of our favorite norms are metrics. Non-real metrics include things like string edit distance.
Basically two types of clustering:
Hierarchical tries to build a tree over the data (N leaves). Typically binary. Flat just tries to find K clusters of the data.
Hierarchical Clustering
Bottom-up strategy:
How to measure “closest.” For individual data points, just use the metric d. What about d({x 1 , x 2 }, {x 3 , x 4 , x 5 })?
d(xR, xS )
xR∈R,xS ∈S
d(xR, xS )
Machine Learning (CS 5350/CS 6350) 2
These have very different properties. Min-link results in chaining. Max-link results in very “round” clusters. Average-link is an intermediary.
Top-down strategy:
Same story as bottom up with linkage. Here, if we remove a single element, we get a funny tree. If we want to split clusters in half, it can be very computationally expensive. Typically bottom-up is prefered.
Flat Clustering
Want to break N elements into K groups. How to choose the groups?
k
n 6 =m∈k d(xn, xm) should be low.
k 6 =k′
n∈k
m∈k′^ d(xn, xm) should be high.
Too hard to optimize a linear combination of these... there are (^) K^1!
k(−1) K−k(K k
kN^ possible clusters (for N = 19, K = 4, this is over 10^10.
Idea: propose clusters, then iteratively fix errors.
This is the k-means algorithm. It is highly sensitive to initialization, but converges quite quickly. (There are various ways to speed it up, as well.)
Initializing means:
In general, it’s a good idea to do a few runs of k-means.
k-mediods is similar, but forces each centroid to be a data point. This is advantageous for non-real-valued data.