Class SimplifiedSilhouette

  • All Implemented Interfaces:
    Evaluator, ResultProcessor

    public class SimplifiedSilhouette
    extends java.lang.Object
    implements Evaluator
    Compute the simplified silhouette of a data set.

    The simplified silhouette does not use pairwise distances, but distances to centroids only.

    Since:
    0.7.0
    Author:
    Stephan Baier, Erich Schubert
    • Field Detail

      • LOG

        private static final Logging LOG
        Logger for debug output.
      • noiseOption

        private NoiseHandling noiseOption
        Option for noise handling.
      • key

        private java.lang.String key
        Key for logging statistics.
    • Method Detail

      • evaluateClustering

        public double evaluateClustering​(Relation<? extends NumberVector> rel,
                                         Clustering<?> c)
        Evaluate a single clustering.
        Parameters:
        rel - Data relation
        c - Clustering
        Returns:
        Mean simplified silhouette
      • centroids

        public static int centroids​(Relation<? extends NumberVector> rel,
                                    java.util.List<? extends Cluster<?>> clusters,
                                    NumberVector[] centroids,
                                    NoiseHandling noiseOption)
        Compute centroids.
        Parameters:
        rel - Data relation
        clusters - Clusters
        centroids - Output array for centroids
        Returns:
        Number of ignored noise elements.
      • processNewResult

        public void processNewResult​(java.lang.Object result)
        Description copied from interface: ResultProcessor
        Process a result.
        Specified by:
        processNewResult in interface ResultProcessor
        Parameters:
        result - Newly added result subtree.