net.sf.jdmf.algorithms.clustering.centroid.impl
Class FirstRandomOthersDistantChoiceStrategy

java.lang.Object
  extended by net.sf.jdmf.algorithms.clustering.centroid.impl.FirstRandomOthersDistantChoiceStrategy
All Implemented Interfaces:
InitialCentroidChoiceStrategy

public class FirstRandomOthersDistantChoiceStrategy
extends java.lang.Object
implements InitialCentroidChoiceStrategy

A simple, but effective initial centroid choice strategy. The first centroid is randomly chosen from available points, subsequent centroids are points with the biggest total distance from all centroids already chosen.

Author:
quorthon

Constructor Summary
FirstRandomOthersDistantChoiceStrategy()
           
 
Method Summary
 java.util.List<java.util.Vector<java.lang.Double>> chooseInitialCentroids(java.util.List<java.util.Vector<java.lang.Double>> points, java.lang.Integer numberOfClusters)
          Chooses initial centroids based on all points and the predicted number of clusters.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FirstRandomOthersDistantChoiceStrategy

public FirstRandomOthersDistantChoiceStrategy()
Method Detail

chooseInitialCentroids

public java.util.List<java.util.Vector<java.lang.Double>> chooseInitialCentroids(java.util.List<java.util.Vector<java.lang.Double>> points,
                                                                                 java.lang.Integer numberOfClusters)
Description copied from interface: InitialCentroidChoiceStrategy
Chooses initial centroids based on all points and the predicted number of clusters.

Specified by:
chooseInitialCentroids in interface InitialCentroidChoiceStrategy
See Also:
InitialCentroidChoiceStrategy.chooseInitialCentroids(java.util.List, java.lang.Integer)