brand banner

Some random stats facts

Bessel's Correction, adding in quadrature, SEM

Updated Β· 7 min read Β· #statistics

Some random stats facts

Bessel's Correction, adding in quadrature, SEM

Bessel’s Correction

Sample variance (𝑠2) is said to be a β€œbiased estimator” compared to population variance (𝜎2). We correct this bias by dividing the sample variance by π‘βˆ’1.

The bias can be seen using computer simulations, but these articles purport to show algebraic proofs:

Sum of 𝑋𝑛 is 𝑁 times mean:

𝑋̄=1π‘βˆ‘π‘›=π‘–π‘π‘‹π‘›βŸΉπ‘π‘‹Μ„=βˆ‘π‘›=𝑖𝑁𝑋𝑛

Square of mean is not the same as mean of squares, 𝔼[π‘Œ]2≠𝔼[π‘Œ2].

Simple counterexample is shown using π‘…π‘Œ={βˆ’1,1}.

𝔼[π‘Œ]2=(1π‘βˆ‘π‘›=1π‘π‘Œπ‘›)2=βˆ’1+12=0𝔼[π‘Œ2]=1π‘βˆ‘π‘›=1𝑁(π‘Œπ‘›2)=1+12=1𝔼[π‘Œ]2≠𝔼[π‘Œ2]

Variance is mean of square minus square of mean:

  • πœ‡=𝔼[π‘Œ]: population mean
  • π‘ŒΜ„: sample mean
𝕍[π‘Œ]=𝔼[(π‘Œβˆ’πœ‡)2]by definition of variance=𝔼[π‘Œ2βˆ’2π‘Œπœ‡+πœ‡2]=𝔼[π‘Œ2]βˆ’2πœ‡π”Ό[π‘Œ]+πœ‡2=𝔼[π‘Œ2]βˆ’πœ‡2=𝔼[π‘Œ2]βˆ’π”Ό[π‘Œ]2

Adding in quadrature

Errors add in quadrature because, for independent errors, it’s the variances that add, not the standard deviations.

The math

Say your result is 𝑄=𝐴+𝐡, and 𝐴 and 𝐡 each have a random error with standard deviations 𝜎𝐴 and 𝜎𝐡. The variance of a sum is

Var(𝐴+𝐡)=Var(𝐴)+Var(𝐡)+2Cov(𝐴,𝐡).

If the errors are independent, the covariance is zero, so

πœŽπ‘„2=𝜎𝐴2+𝜎𝐡2βŸΉπœŽπ‘„=𝜎𝐴2+𝜎𝐡2.

That square root of a sum of squares is β€œadding in quadrature.” Nothing here assumes Gaussian errors. It only needs independence and finite variances.

The intuition

Adding the errors directly, 𝜎𝐴+𝜎𝐡, assumes the worst case every time: both errors at full size and in the same direction. Independent errors don’t conspire like that. Sometimes 𝐴 reads high while 𝐡 reads low, and they partly cancel. On average the combined error is bigger than either one alone but smaller than their plain sum.

A random walk shows the same thing. After 𝑁 independent steps of size 𝜎, you’re typically about π‘πœŽ from where you started, not π‘πœŽ. This is also why averaging 𝑁 measurements shrinks the error by 1/𝑁.

The geometric picture

You can treat each independent error source as a vector, with its length equal to its standard deviation. Independence plays the role of being perpendicular: covariance acts like a dot product, and independent errors have zero covariance. The total error is the length of the sum of perpendicular vectors, which is just the Pythagorean theorem. That’s where the name comes from.

The general rule

For any function 𝑄=𝑓(π‘₯1,…,π‘₯𝑛) with small, independent errors, a first-order (linear) approximation gives

πœŽπ‘„2β‰ˆβˆ‘π‘–(πœ•π‘“πœ•π‘₯𝑖)2𝜎π‘₯𝑖2.

Each error is scaled by how sensitive 𝑄 is to that input, and then the results add in quadrature. For products and quotients, this works out to adding the relative errors in quadrature.

When not to use it

  • Correlated or systematic errors. If two inputs share an error, like the same miscalibrated instrument, the covariance term doesn’t vanish.1 When they’re fully correlated, πœŽπ‘„=𝜎𝐴+𝜎𝐡, so linear addition is correct. Linear addition is also a safe upper bound when you don’t know how the errors are correlated.
  • Large errors or strongly nonlinear functions. The derivative formula is only a linear approximation, so it can be off when errors are big compared to how curved 𝑓 is.

In short, quadrature is right when the errors are independent, because independent errors partly cancel.

Where the variance of a sum comes from

It comes straight from the definition of variance plus the algebra of (π‘Ž+𝑏)2=π‘Ž2+𝑏2+2π‘Žπ‘.

Start from the definition

The variance of a random variable is the average squared distance from its mean:

Var(𝑋)=𝔼[(π‘‹βˆ’πœ‡π‘‹)2].

Apply it to 𝐴+𝐡

The mean of a sum is the sum of the means: πœ‡π΄+𝐡=πœ‡π΄+πœ‡π΅. That follows from linearity of expectation. So

Var(𝐴+𝐡)=𝔼[((𝐴+𝐡)βˆ’(πœ‡π΄+πœ‡π΅))2].

To keep it short, write each deviation as π‘Ž=π΄βˆ’πœ‡π΄ and 𝑏=π΅βˆ’πœ‡π΅. Then the quantity inside the square is just π‘Ž+𝑏:

Var(𝐴+𝐡)=𝔼[(π‘Ž+𝑏)2].

Expand the square

(π‘Ž+𝑏)2=π‘Ž2+𝑏2+2π‘Žπ‘.

Expectation is linear, so take it term by term:

𝔼[(π‘Ž+𝑏)2]=𝔼[π‘Ž2]+𝔼[𝑏2]+2𝔼[π‘Žπ‘].

Identify each piece

  • 𝔼[π‘Ž2]=𝔼[(π΄βˆ’πœ‡π΄)2]=Var(𝐴)
  • 𝔼[𝑏2]=𝔼[(π΅βˆ’πœ‡π΅)2]=Var(𝐡)
  • 𝔼[π‘Žπ‘]=𝔼[(π΄βˆ’πœ‡π΄)(π΅βˆ’πœ‡π΅)]. This is the definition of the covariance Cov(𝐴,𝐡).

Substituting those in gives

Var(𝐴+𝐡)=Var(𝐴)+Var(𝐡)+2Cov(𝐴,𝐡).

Why the covariance vanishes for independent errors

Covariance measures whether 𝐴 and 𝐡 tend to be off from their means in the same direction. If they’re independent, the expectation of the product factors:

𝔼[π‘Žπ‘]=𝔼[π‘Ž]𝔼[𝑏]=0β‹…0=0,

because each deviation averages to zero by construction.2 The cross term drops out and you’re left with πœŽπ‘„2=𝜎𝐴2+𝜎𝐡2.

So the covariance term is just the 2π‘Žπ‘ cross term from squaring a sum. That’s also why the geometric picture works. This formula has the same form as the law of cosines,

|π‘Žβƒ—+𝑏⃗|2=|π‘Žβƒ—|2+|𝑏⃗|2+2π‘Žβƒ—β‹…π‘βƒ—,

with covariance playing the role of the dot product. Independent errors make that term zero, the way perpendicular vectors do, and you get Pythagoras.

  1. 1Write each measurement as its true value plus an independent error plus a shared error 𝑠: 𝐴=𝐴true+𝑒𝐴+𝑠 and 𝐡=𝐡true+𝑒𝐡+𝑠, where 𝑒𝐴, 𝑒𝐡, 𝑠 are independent with mean zero. The deviations are π‘Ž=𝑒𝐴+𝑠 and 𝑏=𝑒𝐡+𝑠, so 𝔼[π‘Žπ‘]=𝔼[𝑒𝐴𝑒𝐡]+𝔼[𝑒𝐴𝑠]+𝔼[𝑠𝑒𝐡]+𝔼[𝑠2]. The first three terms factor to 0β‹…0, but the last is 𝔼[𝑠2]=πœŽπ‘ 2, which can’t factor because 𝑠 is not independent of itself. So Cov(𝐴,𝐡)=πœŽπ‘ 2>0: both inputs are pushed off in the same direction by the same amount, and that can’t cancel. In the extreme where 𝑠 is the only error, 𝜎𝐴=𝜎𝐡=πœŽπ‘  and Var(𝐴+𝐡)=πœŽπ‘ 2+πœŽπ‘ 2+2πœŽπ‘ 2=(2πœŽπ‘ )2, which is exactly πœŽπ‘„=𝜎𝐴+𝜎𝐡.
  2. 2We defined π‘Ž=π΄βˆ’πœ‡π΄, which is just 𝐴 shifted so that its mean sits at zero. By linearity of expectation, 𝔼[π‘Ž]=𝔼[𝐴]βˆ’πœ‡π΄=πœ‡π΄βˆ’πœ‡π΄=0, and likewise 𝔼[𝑏]=0. Note that independence of 𝐴 and 𝐡 carries over to π‘Ž and 𝑏, since subtracting a constant doesn’t change how two variables depend on each other.

Β© 2026 James Yap

Personal Website and Knowledge Base