org.apache.mahout.clustering
Class KMeansClusteringPolicy

java.lang.Object
  extended by org.apache.mahout.clustering.KMeansClusteringPolicy
All Implemented Interfaces:
ClusteringPolicy

public class KMeansClusteringPolicy
extends Object
implements ClusteringPolicy

This is a simple maximum likelihood clustering policy, suitable for k-means clustering


Constructor Summary
KMeansClusteringPolicy()
           
 
Method Summary
 Vector select(Vector probabilities)
          Return the index of the most appropriate model
 void update(ClusterClassifier posterior)
          Update the policy with the given classifier
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

KMeansClusteringPolicy

public KMeansClusteringPolicy()
Method Detail

select

public Vector select(Vector probabilities)
Description copied from interface: ClusteringPolicy
Return the index of the most appropriate model

Specified by:
select in interface ClusteringPolicy
Parameters:
probabilities - a Vector of pdfs
Returns:
a Vector of weights

update

public void update(ClusterClassifier posterior)
Description copied from interface: ClusteringPolicy
Update the policy with the given classifier

Specified by:
update in interface ClusteringPolicy
Parameters:
posterior - a ClusterClassifier


Copyright © 2008-2012 The Apache Software Foundation. All Rights Reserved.