Enum Combiner.Type

java.lang.Object
java.lang.Enum<Combiner.Type>
uk.ac.starlink.ttools.plot2.layer.Combiner.Type
All Implemented Interfaces:
Serializable, Comparable<Combiner.Type>, java.lang.constant.Constable
Enclosing class:
Combiner

public static enum Combiner.Type extends Enum<Combiner.Type>
Defines the scaling properties of a combiner. This also provides information on how the results of the populated bin list should be interpreted.
  • Enum Constant Details

    • EXTENSIVE

      public static final Combiner.Type EXTENSIVE
      Sum-like aggregation. To first order, the bin result quantities scale linearly with the number of values submitted. If a bin value is NaN because no values have been submitted, it can be interpreted as zero.
    • INTENSIVE

      public static final Combiner.Type INTENSIVE
      Average-like aggregation. To first order, the bin result quantities are not dependent on the number of values submitted. No numeric value can be assumed if a bin value is NaN because no values have been submitted.
    • DENSITY

      public static final Combiner.Type DENSITY
      Density-like aggregation. This is like EXTENSIVE, but results should be divided by bin size; the getBinFactor method in general will return a value that is not unity.
  • Method Details

    • values

      public static Combiner.Type[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      Returns:
      an array containing the constants of this enum type, in the order they are declared
    • valueOf

      public static Combiner.Type 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
    • isExtensive

      public boolean isExtensive()
      Indicates whether the bin values scale to first order with the number of submitted values per bin.
      Returns:
      true iff no submitted values corresponds to a zero bin value
    • getBinFactor

      public double getBinFactor(double binExtent)
      Returns a scaling factor which ought to be applied to bin values. This may be unity, or it may depend on the supplied bin extent.
      Parameters:
      binExtent - bin size in some natural units
      Returns:
      factor to multiply bin contents by before use