diff options
author | Cédric Bonhomme <kimble.mandel@gmail.com> | 2012-11-16 15:23:26 +0100 |
---|---|---|
committer | Cédric Bonhomme <kimble.mandel@gmail.com> | 2012-11-16 15:23:26 +0100 |
commit | 3e927164b77a325a68da7c3672a83977a2c408af (patch) | |
tree | c0ec8dfcc235d7f277bc69db8cb6160f7e5a4dbc | |
parent | Added tests with clusters. (diff) | |
download | newspipe-3e927164b77a325a68da7c3672a83977a2c408af.tar.gz newspipe-3e927164b77a325a68da7c3672a83977a2c408af.tar.bz2 newspipe-3e927164b77a325a68da7c3672a83977a2c408af.zip |
Test draw function. Set K to 8.
-rw-r--r-- | source/testclusters.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/source/testclusters.py b/source/testclusters.py index 0e1e2a32..ea6406b1 100644 --- a/source/testclusters.py +++ b/source/testclusters.py @@ -2,11 +2,11 @@ import clusters -K = 10 +K = 8 -blognames,labels,data = clusters.readfile("blogdata1.txt") +blognames,words,data = clusters.readfile("blogdata1.txt") -#coords = clusters.scaledown(data) +coords = clusters.scaledown(data) print "Generating clusters..." kclust = clusters.kcluster(data, k=K) @@ -20,4 +20,4 @@ for i in range(K): -#clusters.draw2d(coords,blognames,jpeg='mds2d.jpg')
\ No newline at end of file +clusters.draw2d(coords,blognames,jpeg='mds2d.jpg')
\ No newline at end of file |