rStats.js v1.3.0
    Preparing search index...

    Function qgamma

    • Quantile function of the gamma distribution. Equivalent to R's qgamma(p, shape, rate = 1, scale = 1/rate, lower.tail = TRUE, log.p = FALSE).

      Type Parameters

      Parameters

      • p: T

        Probability (or log probability with logP): a number, number[] or Float64Array. The result has the same shape.

      • shape: number

        Shape parameter.

      • options: GammaParams & TailOptions = {}

        rate or scale (see GammaParams), lowerTail and logP (see TailOptions).

      Returns VectorResult<T>

      The quantile(s).

      RangeError if both rate and scale are given and scale is not 1 / rate.

      qgamma(0.5, 2);                   // 1.6783469900166605
      qgamma([0.05, 0.95], 2, { rate: 3 }); // [0.11845383689955402, 1.5812881727968588]