Documentation of 'org.ddogleg.clustering.AssignCluster' Java class
AssignCluster
org.ddogleg.clustering

Interface AssignCluster<D>

  • All Superinterfaces:
    java.io.Serializable
    All Known Implementing Classes:
    AssignGmm_F64, AssignKMeans_F64


    public interface AssignCluster<D>
    extends java.io.Serializable
    Used to assign a point to set of clusters. Clusters are given labels from 0 to N-1, where N is the number of clusters.
    • Method Detail

      • assign

        int assign(D point)
        Assigns the point to cluster which is the best fit.
        Parameters:
        point - Point which is to be assigned
        Returns:
        Index of the cluster from 0 to N-1
      • assign

        void assign(D point,
                    double[] fit)
        Performs a soft assignment of a point to all the clusters. Clusters with a better fit will have a larger value in 'fit'. The sum of fit is equal to 1, unless everything is zero. Then it is zero.
        Parameters:
        point - Point which is to be assigned
        fit - Storage for relative fit quality of each cluster. Length must be at least the number of clusters.
      • getNumberOfClusters

        int getNumberOfClusters()
        Total number of clusters.
        Returns:
        The total number of clusters.
      • copy

        AssignCluster<D> copy()
        Creates an exact copy of this class.
        Returns:
        Copy of class

DataMelt 3.0 © DataMelt by jWork.ORG

You see the box below because you did not login.