Class GammaPD

All Implemented Interfaces:
Serializable, Cloneable

public class GammaPD extends ProbabilityDistribution implements Serializable, Cloneable
The gamma probability distribution.
See Also:
  • Constructor Details

    • GammaPD

      public GammaPD()
      Constructor for the gamma probability distribution.
  • Method Details

    • pdf

      public double pdf(double x, double... params)
      Returns the value of the gamma probability density function.

      The probability density function of the gamma distribution is

      $$ f(x; a, b) = x^{a - 1} \frac{1}{{b^{a} \Gamma (a)}} e^{ - {x}/{b}} $$

      where \( a > 0\) and \( b> 0\) are the shape and scale parameters, respectively.

      Specified by:
      pdf in class ProbabilityDistribution
      Parameters:
      x - a double, the value (quantile) at which to evaluate the pdf
      params - a double array specifying the parameters, a and b. The parameters can also be given in the form pdf(x,a,b), where a and b are scalars.
      Returns:
      a double, the probability density at x given the parameter values
    • getParameterLowerBounds

      public double[] getParameterLowerBounds()
      Returns the lower bounds of the parameters.
      Specified by:
      getParameterLowerBounds in class ProbabilityDistribution
      Returns:
      a double array containing the lower bounds for \( a > 0\) and \( b> 0\)
    • getParameterUpperBounds

      public double[] getParameterUpperBounds()
      Returns the upper bounds of the parameters.
      Specified by:
      getParameterUpperBounds in class ProbabilityDistribution
      Returns:
      a double array containing the upper bounds for \( a > 0\) and \( b> 0\)