Contact

Collabora Office HYPGEOMDIST: Sampling Without Replacement and Defaults

Statistical Intermediate Collabora Office Calc

Use legacy HYPGEOMDIST for point mass or cumulative sampling probabilities; compare the mandatory flag in HYPGEOM.DIST. Scoped to the new Linux desktop source build.

Verification status: See the evidence and test scope described in this guide. How formula examples are checked

HYPGEOMDIST models the number of marked items in a random sample drawn without replacement from a finite population. Its four-argument legacy form returns a point probability. An optional fifth argument changes the calculation to a cumulative probability.

Syntax and the dotted-name distinction

=HYPGEOMDIST(X; NSample; Successes; NPopulation [; Cumulative])

X is the number of marked items in the sample, NSample is the sample size, Successes is the total number of marked items in the population, and NPopulation is the population size. These are counts, not proportions.

Cumulative omitted or FALSE selects P(K=X). TRUE selects P(K≤X). The related HYPGEOM.DIST uses the same checked evaluator but requires its fifth argument. Thus a four-argument legacy call cannot be replaced by adding a dot while leaving the argument list unchanged.

The evaluator approximately floors all four counts before checking them. Use integer counts deliberately; do not depend on that conversion to repair inaccurate input data.

Step by step: two marked items in four draws

Imagine ten numbered tokens, of which five are marked. Select four uniformly without replacing any token. Enter A2 2, B2 4, C2 5, D2 10, then calculate =HYPGEOMDIST(A2;B2;C2;D2).

=HYPGEOMDIST(2;4;5;10)

The independent point probability is:

C(5,2)*C(5,2)/C(10,4) = 100/210 = 10/21

That is approximately 0.4761904762, or 47.61904762%. The numerator chooses two marked and two unmarked tokens; the denominator counts all four-token samples. This is a sampling model, not a claim that any one real sample will contain two marked items.

Both =HYPGEOMDIST(2;4;5;10;FALSE) and =HYPGEOM.DIST(2;4;5;10;FALSE) have the same source/math target for these ordinary inputs. Their shared result does not remove the different required-argument contracts.

Cumulative probability and support

For =HYPGEOMDIST(2;4;5;10;TRUE), add the probabilities for zero, one and two marked tokens. The combination numerators are 5, 50 and 100 over denominator 210. Their sum is 155/210 = 31/42, approximately 0.7380952381.

The feasible count range is max(0,n-(N-M)) through min(n,M), where n is sample size, M marked population and N total population. Some impossible counts return zero rather than triggering the initial argument guard. For example, =HYPGEOMDIST(3;4;2;10) returns source-predicted 0 because only two marked items exist. =HYPGEOMDIST(4;4;2;10;TRUE) includes all feasible counts and has expected cumulative probability 1.

By contrast, X=5 with sample size 4 is caught by the source’s argument guard and yields internal IllegalArgument. An impossible sample count and a count above the marked population therefore do not necessarily follow the same error path.

Advanced: at least three marked tokens

For the original ten-token population, the complement of the cumulative probability through two is 1-31/42 = 11/42, approximately 26.19047619%. This is the probability of at least three marked tokens in the four draws. The expression uses 1-P(K≤2), not 1-P(K=2).

The expected count is n*M/N = 4*5/10 = 2, but an expectation is not a guaranteed sample outcome. Sampling with replacement would be a different model because the population composition would not change between draws.

Reproduce the help’s rounded example

The help publishes HYPGEOMDIST(2;2;90;100) as 0.81. The exact finite-population calculation is (90/100)*(89/99) = 89/110, approximately 0.8090909091, which rounds to 0.81. Do not replace the second factor with 90/100; doing so silently changes the without-replacement model.

Validation and numerical limits

The checked source rejects negative X, X above sample size, sample size above population, marked count above population and negative marked count after flooring. The control HYPGEOMDIST(2.9;4.8;5.7;10.9) follows the same floored counts as the main example, but integer inputs are clearer.

The evaluator accumulates feasible mass terms for the cumulative result. This guide uses small counts and does not promise unlimited-size combinatorial evaluation, tail accuracy or runtime performance. Internal error identities are source predictions; localized application displays were not observed.

Product, version and verification

This guide is scoped to the new Collabora Office desktop for Linux, package source tag coda-26.04.4.3-1, commit 81339d176148d0d5c81ff05d82540f58f8aaa117. The 26.04 HYPGEOMDIST help, exact evaluator and dispatch source were checked October 18, 2026. The Linux package manifest provides the recorded product mapping; it is mutable and is not proof of an installed binary.

No Collabora runtime or calculation engine was executed. All worked values are independent mathematical controls or explicit source predictions; vendor display rounding is identified separately. No screenshots, performance benchmarks or cross-platform tests are claimed. This evidence does not certify Classic, Online, CODE, mobile, Windows or macOS.

“Legacy” distinguishes the function’s spelling and argument contract. The checked registration and current help do not establish that it is retired or deprecated. Its first Collabora introduction release is unknown; upstream release history and file-conversion compatibility are not inferred.