clustering-0.3.0: High performance clustering algorithms

Safe HaskellNone
LanguageHaskell2010

AI.Clustering.KMeans

Contents

Synopsis

Documentation

data KMeans a Source #

Results from running kmeans

Constructors

KMeans 

Fields

Instances

Show a => Show (KMeans a) Source # 

Methods

showsPrec :: Int -> KMeans a -> ShowS #

show :: KMeans a -> String #

showList :: [KMeans a] -> ShowS #

kmeans Source #

Arguments

:: Int

The number of clusters

-> Matrix Double

Input data stored as rows in a matrix

-> KMeansOpts 
-> KMeans (Vector Double) 

Perform K-means clustering

kmeansBy Source #

Arguments

:: Vector v a 
=> Int

The number of clusters

-> v a

Input data

-> (a -> Vector Double) 
-> KMeansOpts 
-> KMeans a 

Perform K-means clustering, using a feature extraction function

Initialization methods

data Method Source #

Different initialization methods

Constructors

Forgy

The Forgy method randomly chooses k unique observations from the data set and uses these as the initial means.

KMeansPP

K-means++ algorithm.

Centers (Matrix Double)

Provide a set of k centroids

References

Arthur, D. and Vassilvitskii, S. (2007). k-means++: the advantages of careful seeding. Proceedings of the eighteenth annual ACM-SIAM symposium on Discrete algorithms. Society for Industrial and Applied Mathematics Philadelphia, PA, USA. pp. 1027–1035.