Enum AggregationFunctionConstants

    • Method Detail

      • values

        public static AggregationFunctionConstants[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (AggregationFunctionConstants c : AggregationFunctionConstants.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static AggregationFunctionConstants valueOf​(String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        name - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        IllegalArgumentException - if this enum type has no constant with the specified name
        NullPointerException - if the argument is null
      • apply

        public double apply​(CompareFunction[] compareFunctions,
                            double[] cluster,
                            double[] data,
                            double[] fieldWeights,
                            double[] missingValueWeights,
                            double[] similarityScales,
                            double pParameter)
        Description copied from interface: AggregationFunction
        Applies this AggregationFunction. Computes the distance/similarity of two vectors. Compare function, field weights, missing value weights and similarity scales at index i must correspond to cluster and data vector values at the same index.
        Specified by:
        apply in interface AggregationFunction
        Parameters:
        compareFunctions - the CompareFunctions to measure distance/similarity between the vectors
        cluster - the cluster seeds
        data - the data vector
        fieldWeights - field weights for each field/its values
        missingValueWeights - missing value weights for each field/its values
        similarityScales - similarity scales for each field/its values
        pParameter - the p-parameter, only used by the Minkowski function
        Returns:
        the aggregation value computed by this function