Class DistPearson5

    • Constructor Detail

      • DistPearson5

        public DistPearson5​(StreamInterface stream,
                            double alpha,
                            double beta)
        constructs a new Pearson5 distribution.
        Parameters:
        stream - StreamInterface; the random number stream
        alpha - double; the shape parameter α of the distribution
        beta - double; the scale parameter β of the distribution
        Throws:
        IllegalArgumentException - when alpha <= 0 or beta <= 0
    • Method Detail

      • draw

        public double draw()
        draws the next stream value according to the probability of this this distribution.
        Specified by:
        draw in class DistContinuous
        Returns:
        the next double value drawn.
      • getProbabilityDensity

        public double getProbabilityDensity​(double x)
        returns the probability density value of a value x.
        Specified by:
        getProbabilityDensity in class DistContinuous
        Parameters:
        x - double; the value for which the density function needs to be calculated
        Returns:
        double; the probability density for value x
      • getAlpha

        public double getAlpha()
        Return the shape parameter α of the distribution.
        Returns:
        double; the shape parameter α of the distribution
      • getBeta

        public double getBeta()
        Return the scale parameter β of the distribution.
        Returns:
        double; the scale parameter β of the distribution
      • setStream

        public void setStream​(StreamInterface stream)
        Replace the random number stream.
        Overrides:
        setStream in class Dist
        Parameters:
        stream - StreamInterface; the new random number stream