Class GaussianCumulative<T extends FeatureInput>

Type Parameters:
T - the type of FeatureInput this feature operates on

public class GaussianCumulative<T extends FeatureInput> extends StatisticalBase<T>
Calculates a score between 0 and 1 based on the Cumulative Distribution Function (CDF) of a Gaussian distribution. As the value approaches the mean, the score approaches 1.0.
  • Constructor Details

    • GaussianCumulative

      public GaussianCumulative()
  • Method Details

    • deriveScore

      protected double deriveScore(double featureValue, double mean, FeatureResultSupplier stdDev) throws FeatureCalculationException
      Description copied from class: StatisticalBase
      Derive scores given the value, mean and standard deviation.
      Specified by:
      deriveScore in class StatisticalBase<T extends FeatureInput>
      Parameters:
      featureValue - the feature-value calculated from FeatureUnary.getItem()
      mean - the mean
      stdDev - a supplier for the standard deviation (if needed)
      Returns:
      the derived score
      Throws:
      FeatureCalculationException - if the score calculation fails
    • isIgnoreHigherSide

      public boolean isIgnoreHigherSide()
      If true, always returns 1.0 for values higher than the mean.
    • setIgnoreHigherSide

      public void setIgnoreHigherSide(boolean ignoreHigherSide)
      If true, always returns 1.0 for values higher than the mean.
    • isIgnoreLowerSide

      public boolean isIgnoreLowerSide()
      If true, always returns 1.0 for values lower than the mean.
    • setIgnoreLowerSide

      public void setIgnoreLowerSide(boolean ignoreLowerSide)
      If true, always returns 1.0 for values lower than the mean.
    • isRewardHigherSide

      public boolean isRewardHigherSide()
      If true, treats the higher side as if it's the full CDF.
    • setRewardHigherSide

      public void setRewardHigherSide(boolean rewardHigherSide)
      If true, treats the higher side as if it's the full CDF.
    • isRewardLowerSide

      public boolean isRewardLowerSide()
      If true, treats the lower side as if it's 1 minus the full CDF.
    • setRewardLowerSide

      public void setRewardLowerSide(boolean rewardLowerSide)
      If true, treats the lower side as if it's 1 minus the full CDF.