Class NormalizeDescriptor

java.lang.Object
com.pervasive.datarush.analytics.stats.NormalizeDescriptor
All Implemented Interfaces:
Serializable

public final class NormalizeDescriptor extends Object implements Serializable
Describes a field to be normalized.
See Also:
  • Constructor Details

    • NormalizeDescriptor

      public NormalizeDescriptor(String fieldName, StatsFunctions.NormalizeMethod method)
      Construct a normalization descriptor.
      Parameters:
      fieldName - name of the field to normalize
      method - type of normalization to apply
    • NormalizeDescriptor

      public NormalizeDescriptor(String inputFieldName, StatsFunctions.NormalizeMethod method, String outputFieldName)
      Construct a normalization descriptor.
      Parameters:
      inputFieldName - name of the field to normalize
      method - type of normalization to apply
      outputFieldName - name of the resultant field
  • Method Details

    • getInputFieldName

      public String getInputFieldName()
      Get the input field name of the descriptor.
      Returns:
      input field name
    • getOutputFieldName

      public String getOutputFieldName()
      Get the output field name of the descriptor.
      Returns:
      output field name
    • getMethod

      public StatsFunctions.NormalizeMethod getMethod()
      Get the normalization method of the descriptor.
      Returns:
      normalizaton method
    • descriptors

      public static NormalizeDescriptor[] descriptors(StatsFunctions.NormalizeMethod method, String... fieldNames)
      Build descriptors for the given fields and method.
      Parameters:
      method - the normalization method to apply
      fieldNames - names of the input fields
      Returns:
      descriptors for the given fields
    • descriptors

      public static NormalizeDescriptor[] descriptors(StatsFunctions.NormalizeMethod method, Collection<String> reservedNames, String... fieldNames)
    • renameOutputField

      public NormalizeDescriptor renameOutputField(String name)
      Creates a NormalizeDescriptor that is identical to this one except that the output field has a different name.
      Parameters:
      name - the name of the output field.
      Returns:
      a NormalizeDescriptor with the same input field and normalization method and the provided output field name.