K-mean clustering and Soft K-means clustering (octave)
(c) David J.C. MacKay
| Lecture course |
Other demonstrations |
1. Hard K-means clustering, demonstrated in two dimensions.
Introductory simple examples; then examples where the
results do not look so good, showing a need for
a probabilistic approach.
2. Soft K-means clustering. Radii of Gaussians visualized.
Several versions of Soft K-means, and various pathological data sets.
This demonstration should work if you are running X-windows on a
unix machine that has octave-2.0 and gnuplot.
More recent versions of octave (eg 2.1) may give problems.
If you have got octave and gnuplot on some other system (eg cygwin under Windoze),
it may work.
To run the demonstration:
- get the demonstration files (41K)
by clicking here http
- unpack thus:
tar zxvf kmeans.tar.gz This unpacks a load of files into a directory
called kmeans and another directory called kmeansoft.
[If there are any complaints about the clock time use
tar zxvfm kmeans.tar.gz]
modify your X windows defaults so that the gnuplot colours and fonts
come out right. (Execute this command on the machine running X windows.)
xrdb -load Xdefaults.gnu
(Works fine with octave-2.0 but not with octave-2.1.33, which seems to
have plotting bugs.)
- To run the demo:
Select from a range of demonstrations. If you keep hitting return you
will be taken through the sequence
- To run soft K-means, change to directory kmeansoft and run octave there.
David MacKay <firstname.lastname@example.org>
Last modified: Sun Nov 30 08:50:02 2003