| Weka_clusterers | R Documentation |
R interfaces to Weka clustering algorithms.
Cobweb(x, control = NULL)
FarthestFirst(x, control = NULL)
SimpleKMeans(x, control = NULL)
XMeans(x, control = NULL)
DBScan(x, control = NULL)
x |
an R object with the data to be clustered. |
control |
an object of class |
There is a predict method for
predicting class ids or memberships from the fitted clusterers.
Cobweb implements the Cobweb \bibcitepFisher:1987 and Classit
\bibcitepGennari+Langley+Fisher:1989 clustering algorithms.
FarthestFirst provides the
“farthest first traversal algorithm” by
\bibcitetHochbaum+Shmoys:1985,
which works as a fast simple
approximate clusterer modeled after simple k-means.
SimpleKMeans provides clustering with the k-means
algorithm.
XMeans provides k-means extended by an
“Improve-Structure part” and automatically determines the
number of clusters.
DBScan provides the “density-based clustering algorithm”
by \bibcitetEster+Kriegel+Sander:1996.
Note that noise points are assigned to NA.
A list inheriting from class Weka_clusterers with components
including
clusterer |
a reference (of class
|
class_ids |
a vector of integers indicating the class to which
each training instance is allocated (the results of calling the Weka
|
XMeans requires Weka package XMeans to be installed.
DBScan requires Weka package optics_dbScan to be
installed.
Ester+Kriegel+Sander:1996, Fisher:1987, Gennari+Langley+Fisher:1989, Hochbaum+Shmoys:1985, Pelleg+Moore:2000, Witten+Frank:2005
cl1 <- SimpleKMeans(iris[, -5], Weka_control(N = 3))
cl1
table(predict(cl1), iris$Species)
## Not run:
## Requires Weka package 'XMeans' to be installed.
## Use XMeans with a KDTree.
cl2 <- XMeans(iris[, -5],
c("-L", 3, "-H", 7, "-use-kdtree",
"-K", "weka.core.neighboursearch.KDTree -P"))
cl2
table(predict(cl2), iris$Species)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.