I understand that, if errors are random and independent, the addition (or difference) of two measured quantities, say $x$ and $y$, is equal to the quadratic sum of the two errors. In other words, the error of $x + y$ is given by $\sqrt{e_1^2 + e_2^2}$, where $e_1$ and $e_2$ and the errors of $x$ and $y$, respectively.

However, I have not yet been able to find how to calculate the error of both the arithmetic mean and the weighted mean of the two measured quantities. How do errors propagate in these cases?


The first assertion deals wtih mean squared errors, which in probabilistic terms translates into standard deviations.

Now, probability says that the variance of the sum of two independent variables is the sum of the variances. That is, if $z = x + y$ ($x$ and $y$ indep), then $\sigma_z^2 = \sigma_x^2 + \sigma_y^2 $ and $$e_z = \sigma_z = \sqrt{\sigma_x^2 + \sigma_y^2} = \sqrt{e_x^2 + e_y^2} $$

Knowing this, and knowing that $Var(a X) = a^2 Var(X)$, if $z = a x + (1-a) y$ (weighted mean, if $ 0\le a \le1$) we get:

$$\sigma_z^2 = a^2\sigma_x^2 + (1-a)^2\sigma_y^2 $$

$$e_z = \sqrt{a^2 e_x^2 + (1-a)^2 e_y^2} = a \sqrt{ e_x^2 + \left(\frac{1-a}{a}\right)^2 e_y^2} $$

In particular, if $a=1/2$ , then $e_z = \frac{1}{2}\sqrt{ e_x^2 + e_y^2} $

Another particular case: if $e_x = e_y$ then

$$e_z = e_x \sqrt{a^2 +(1-a)^2}$$

  • $\begingroup$ If I understand it correctly, and in a more general form, if we had $n$ independent variables with their corresponding weights, $c_{1}, c_{2}...c_{n}$, the error of their weighted mean (when $\sum_{i=1}^n{c_{i}} = 1$) would be $\sqrt{c_{1}^2 e_1^2 + c_{2}^2 e_2^2 + ... + c_{n}^2 e_n^2}$. Right? $\endgroup$ – plok Mar 23 '12 at 10:56
  • $\begingroup$ @plok that's right $\endgroup$ – leonbloy Mar 23 '12 at 12:12

The arithmetic mean is just a scaled version of the sum, so you just need to know that the error scales as the quantity itself under scaling; thus the error in the arithmetic mean is $\sqrt{e_1^2+e_2^2}/2$. (You need to enclose the argument of the root in curly braces instead of parentheses to have it displayed under the square root.)

For more general error propagation, you need to multiply the errors with the partial derivatives with respect to the individual quantities. In the case of the geometric mean, $g(x,y)=\sqrt{xy}$, these are

$$\frac{\partial g}{\partial x}=\frac12\sqrt{\frac yx}\;,\quad\frac{\partial g}{\partial y}=\frac12\sqrt{\frac xy}\;,$$

so the error $e$ is

$$ \begin{eqnarray} e &=& \sqrt{\left(\frac{\partial g}{\partial x}e_x\right)^2+\left(\frac{\partial g}{\partial y}e_y\right)^2}\\ &=& \frac12\sqrt{\frac yxe_x^2+\frac xye_y^2} \\ &=& \frac1{2g}\sqrt{(e_xy)^2+(e_yx)^2}\;. \end{eqnarray} $$

  • $\begingroup$ could you maybe provide a general equation for the geometric mean of n observations g(x1,x2,...xn)? $\endgroup$ – Roey Angel Apr 3 '13 at 13:58
  • 2
    $\begingroup$ @Roey: The geometric mean is $\sqrt[n]{x_1\cdots x_n}$, so the derivatives are $$\frac{\partial g}{\partial x_i}=\frac1n\frac g{x_i}\;,$$ so the error is $$\sqrt{\left(\frac{\partial g}{\partial x_i}e_1\right)^2+\dotso+\left(\frac{\partial g}{\partial x}_ie_n\right)^2}=\frac gn\sqrt{\left(\frac{e_1}{x_1}\right)^2+\dotso+\left(\frac{e_n}{x_n}\right)^2}\;.$$ $\endgroup$ – joriki Apr 3 '13 at 14:35
  • $\begingroup$ Thanks! I assume you meant though: $(\frac{\partial g}{\partial xn}e_n\right)^2$ in the left hand side of the equation. $\endgroup$ – Roey Angel Apr 3 '13 at 15:34
  • 1
    $\begingroup$ @Roey: I did, thanks, and likewise with index $1$ in the first term. (Your comment isn't rendering properly because you left off the \left at the beginning.) $\endgroup$ – joriki Apr 3 '13 at 16:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.