Your Equation

Library / Probability distributions / PRD-50

Probability distributions

Batch variation: variance of the successes

Variance of the success count, which includes the extra variation caused by the success probability changing between batches.

Ref
PRD-50
Rev
v1
Field
Probability distributions
Result
Var[X]

The variance n a b (a + b + n)/[(a + b)²(a + b + 1)] includes the extra variation caused by the success probability changing from batch to batch. It exceeds the plain binomial variance by the factor (a + b + n)/(a + b + 1), which is greater than 1 whenever n > 1.

Variance of the success count, which includes the extra variation caused by the success probability changing between batches. It exceeds the plain binomial variance.

Calculator

Solve for
140
0.210
0.210
  • Plain binomial variance at the same mean p2.4
  • Overdispersion factor, (a + b + n)/(a + b + 1)2.5
  • Standard deviation of the count2.449

What drives the result

Each variable is moved across its typical range while the others stay at the values above. The longest bar is the key driver.

Variance of the successes () current value 6
nTrials per batch nKey driver
0.2472
bShape b
2.357.36
aShape a
1.84
  • The variance of 6 is 2.5 times the plain binomial variance of 2.4.
  • The smaller a + b is, the more batches differ from each other and the larger the extra variance.
Chart data as tables

Ranked variables

VariableTypical rangeLowest resultHighest resultSwing ()Local stepChange in result
n Trials per batch n1 to 40 0.247271.76+1 +17.3 %
b Shape b0.2 to 10 2.357.3595.008+10%−4.9 %
a Shape a0.2 to 10 1.84264.158+10%−0.267 %

Sweep of Trials per batch n

Trials per batch nVariance of the successes
10.24
5.8752.556
10.756.772
15.6312.89
20.520.91
25.3830.83
30.2542.65
35.1356.38
4072

Sweep one variable

Variance of the successes ()Hover, touch, or use the arrow keys on the chart
0204060 5152535 Trials per batch n now 6

Variables and how each one contributes

Var[X]

Variance of the successes

Result ·

What the equation gives you. Everything else feeds it.

n

Trials per batch n

· typical 1 to 40

The number of trials in a batch (a whole number, at least 1). More trials per batch raise the mean count and the variance. Raising it by 1 (to 11) moves the result by +17.3 %, from 6 to 7.04.

a

Shape a

· typical 0.2 to 10

The first shape of the beta distribution of batch probabilities (a plain number). Raises the average success probability and narrows its spread. Raising it by 10 % (to 2.2) moves the result by −0.267 %, from 6 to 5.984.

b

Shape b

· typical 0.2 to 10

The second shape of the beta distribution of batch probabilities (a plain number). Lowers the average success probability and narrows its spread. Raising it by 10 % (to 3.3) moves the result by −4.9 %, from 6 to 5.706.

Worked example with the values above

  1. Numerator: n a b (a + b + n) = 900.
  2. Denominator: (a + b)²(a + b + 1) = 150.
  3. Var = 6.

Assumptions and limits

  • Within a batch the trials are independent with a common probability p; across batches p follows a beta distribution with shapes a, b > 0.
  • n and x are whole numbers, and 0 ≤ x ≤ n.

Common mistakes

  • Using a plain binomial when batches differ in quality: it understates the variance and the chance of extreme batches.
  • Treating a and b as probabilities: they are shape parameters, and a/(a + b) is the mean probability.
  • Using the formula for x outside 0 to n: the probability is zero there.

Statistics and uncertainty

A mean, variance or percentile is calculated from fitted parameters, and the uncertainty in those parameters passes straight through. A distribution fitted to a small sample can have parameters that are far from the truth, especially in the tails and for the variance, so quote the result together with the sample size it rests on.

Where it is used

  • Defect counts in batches of parts when batch quality varies.
  • Test pass counts across lots, and any count with more spread than a binomial.

Maths you need

  • Binomial distribution: successes in independent trials
  • Beta distribution: a model for a probability that varies

Related formulas

Practise this formula