Function randomGamma

  • Returns a function for generating random numbers with a gamma distribution with k the shape parameter and theta the scale parameter. The value k must be a positive value; if theta is not specified, it defaults to 1.

    Parameters

    • k: number

      Shape parameter

    • Optional theta: number

      Scale paramter

    Returns (() => number)

      • (): number
      • Returns a function for generating random numbers with a gamma distribution with k the shape parameter and theta the scale parameter. The value k must be a positive value; if theta is not specified, it defaults to 1.

        Returns number