which is the more accurate way of calculating mean?

583 Views Asked by At

I have two formulas of calculating a mean Direct and shortcut I guess, which one is accurate(Accuracy and precision ) and dont have errors, how to prove it ?

$$ \overline{x} = \frac{1}{n} \sum_{i=1}^r \tilde{x}_i f_i \qquad \overline{x} = \frac{\sum_{i=1}^n x_i}{n} $$ EDIT:

  • $\tilde{x}_i$ = midpoint of the ith interval,
  • $f_i$ = frequency of ith interval,
  • $r$ = number of intervals
1

There are 1 best solutions below

4
On

It depends on the type of numbers you are dealing with. The second formula will work always with any set of numbers. It could be good for distributions of numbers that are somewhat uniform, i.e. that no number exists in much greater quantities than the others. The second one should be used when the distribution deviates from the uniform distribution. It is good for calculating the mean of nearly continuous distributions (such as those that are run discretely over many trials). Taking the limit of the first expression yields $$\int x\cdot f(x) dx,$$ which is the expression for calculating the mean of a continuous distribution.

So in summary: the second one will work for discrete distributions only. The second one always works, though you need not consider frequencies in simple scenarios (such as when you need to calculate the mean of 3 numbers) and thus it may not be practical.