Collabora Office GAMMADIST: Gamma probabilities with shape and scale
Calculate gamma CDF or density with optional cumulative mode, distinguish scale from rate and preserve legacy negative and zero endpoint rules.
Verification status: See the evidence and test scope described in this guide. How formula examples are checked
Quick answer: =GAMMADIST(6;2;3) independently gives approximately 0.5939941503. Alpha is shape 2, Beta is scale 3, and the omitted fourth argument defaults to cumulative probability. =GAMMADIST(6;2;3;FALSE()) gives density approximately 0.0902235222.
Syntax, parameter units and default mode
=GAMMADIST(Number; Alpha; Beta [; C])
Alpha and Beta must be positive. The official GAMMADIST help documents the optional fourth argument; the inspected wrapper sets it to TRUE when omitted. FALSE/0 requests density, while TRUE/nonzero requests the CDF.
Beta is scale, not rate. The distribution helpers evaluate the standardized coordinate Number/Beta. If your model uses a rate λ, convert it to scale 1/λ before supplying Beta. For shape α and scale β, the mean is αβ and variance αβ². Number and Beta must use compatible units; Alpha is dimensionless.
CDF means the probability at or below Number. Density is measured per unit of Number and is not the probability of one exact continuous value. A probability for a nonzero interval requires a difference of CDF values.
Worked example: shape 2 and scale 3
Enter B2 = 6, B3 = 2 and B4 = 3. Use =GAMMADIST(B2;B3;B4) and, separately, =GAMMADIST(B2;B3;B4;FALSE()).
For shape 2, the formulas simplify to:
- CDF:
1−exp(−x/β)×(1+x/β). - Density:
x×exp(−x/β)/β².
At x = 6 and β = 3, x/β = 2. The independent CDF is 1−3exp(−2) = 0.5939941502901619. Density is (2/3)exp(−2) = 0.0902235221577418.
If the unit is hours, the density is per hour. Changing all time quantities consistently to minutes changes the numerical density by the inverse unit conversion, while the probability of the corresponding event remains the same. Simply replacing scale 3 with rate 1/3 without changing the interpretation would describe a different distribution.
Advanced use: probability across an interval
For the same assumed model, compute the probability of a value between 3 and 9:
=GAMMADIST(9;2;3)-GAMMADIST(3;2;3)
The independent result is approximately 0.5366106089, from 2exp(−1)−4exp(−3). The model mean is 6 and standard deviation is sqrt(18), approximately 4.242640687. These summarize the chosen parameters; GAMMADIST does not estimate them from observations or certify the model’s suitability.
For shape 1 the gamma distribution reduces to an exponential distribution with mean equal to Beta. This is a useful parameterization check: the rate is the reciprocal of that scale. The helper’s distinct behavior at zero also becomes especially clear at shape 1.
Negative inputs and exact-zero density
The legacy ScGammaDist(true) wrapper allows negative Number values to reach its helpers. They return 0 for negative x in both CDF and density mode. The CDF is also zero at x = 0.
Density at the exact zero endpoint depends on Alpha:
| Formula | Inspected-source result |
|---|---|
=GAMMADIST(0;1;3;FALSE()) |
1/3 |
=GAMMADIST(0;2;3;FALSE()) |
0 |
=GAMMADIST(0;0.5;3;FALSE()) |
Internal DivisionByZero |
The last case reflects the singular density for shape below 1. It is not a claim that a probability is infinite: the CDF at zero remains zero. This endpoint policy differs from CHISQDIST’s helper, which assigns zero density at every nonpositive x.
Nonpositive Alpha or Beta follows internal IllegalArgument; for example, =GAMMADIST(6;2;0) is invalid. Use explicit positive numerical parameters and do not rely on negative inputs being silently converted into meaningful observations.
Distinction from GAMMA.DIST
GAMMA.DIST uses the same helper through a different wrapper flag. It requires all four arguments and rejects negative x. GAMMADIST’s omitted cumulative mode and negative-input extension therefore make it a separate legacy contract, not an unconditional spelling alias.
No native UI error strings, application outputs or universal precision guarantee are asserted here. The calculations use simple closed forms; extreme shapes, scales and tail probabilities can involve different numerical paths in the evaluator.
Product scope, compatibility and evidence
This guide covers the new Collabora Office desktop for Linux, using the Flathub source tag coda-26.04.4.3-1 and commit 81339d176148d0d5c81ff05d82540f58f8aaa117. The official desktop release notes and Linux package manifest identify that product/build. The package manifest is a dated observation from October 18, 2026, rather than an installed-binary check.
The 26.04 function help and exact evaluator source were inspected on October 18, 2026. Expected examples were independently calculated; no Collabora application was run. Expected scalar results were derived from the documented contracts, inspected source and independent calculations; native output formatting and error localization have not been tested. Classic, Online/CODE, other operating systems and file-format round trips require their own checks.
These are the documented legacy contracts. A similar dotted name does not establish identical argument order, defaults or boundary behavior. The first Collabora release introducing this function is not established by the reviewed sources. No cited retirement or deprecation notice was found; “legacy” here describes the function contract, not a claim that the function has been removed. File-format round trips require separate verification.
Related functions
- GAMMA.DIST: compare the mandatory flag and negative-input check
- CHISQDIST: compare chi-square probabilities and its endpoint convention