Module datarush.analytics
Enum Class AggregationFunctionConstants
java.lang.Object
java.lang.Enum<AggregationFunctionConstants>
com.pervasive.datarush.analytics.cluster.AggregationFunctionConstants
- All Implemented Interfaces:
AggregationFunction,Serializable,Comparable<AggregationFunctionConstants>,java.lang.constant.Constable
public enum AggregationFunctionConstants
extends Enum<AggregationFunctionConstants>
implements AggregationFunction
This enumeration contains implementations of
AggregationFunctions
that correspond to the aggregation functions for clustering models in
the PMML specification.-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescription -
Method Summary
Modifier and TypeMethodDescriptiondoubleapply(CompareFunction[] compareFunctions, double[] cluster, double[] data, double[] fieldWeights, double[] missingValueWeights, double[] similarityScales, double pParameter) Applies thisAggregationFunction.static AggregationFunctionConstantsReturns the enum constant of this class with the specified name.static AggregationFunctionConstants[]values()Returns an array containing the constants of this enum class, in the order they are declared.Methods inherited from class java.lang.Enum
clone, compareTo, describeConstable, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOfMethods inherited from interface com.pervasive.datarush.analytics.cluster.AggregationFunction
is, name
-
Enum Constant Details
-
euclidean
-
squaredEuclidean
-
chebychev
-
cityBlock
-
minkowski
-
simpleMatching
-
jaccard
-
tanimoto
-
binarySimilarity
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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 class has no constant with the specified nameNullPointerException- 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:AggregationFunctionApplies thisAggregationFunction. 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:
applyin interfaceAggregationFunction- Parameters:
compareFunctions- theCompareFunctions to measure distance/similarity between the vectorscluster- the cluster seedsdata- the data vectorfieldWeights- field weights for each field/its valuesmissingValueWeights- missing value weights for each field/its valuessimilarityScales- similarity scales for each field/its valuespParameter- the p-parameter, only used by the Minkowski function- Returns:
- the aggregation value computed by this function
-