1
$\begingroup$

I have two sets of averaged data I am working with, which account for a score and the average amount of users that achieved this.

For example:

Average Score $4$, Total Number of participants (which the average is derived from): $835$

Average Score $3.5$, Total Number of participants: $4,579$

Can I calculate a weighted mean from these two averages and participant counts, or would that be inaccurate?

3 Answers 3

6

I assume you want to calculate the average score of all participants, which is (given your data) equal to $$\frac{835}{835+4579} \cdot 4 + \frac{4579}{835+4579}\cdot 3.5$$

so the answer is yes.


In general, if you have $n$ numbers $\{a_1,\dots, a_n\}$ with an average of $a$, and $m$ numbers $\{b_1,\dots, b_m\}$ with an average of $b$, you know that

$$\frac{a_1+\cdots + a_n}{n}=a\\ \frac{b_1+\cdots + b_m}{m}=b$$

or, in other words, $$a_1+\cdots + a_n = n\cdot a\\b_1+\cdots + b_m = m\cdot b$$

and you are looking for the number $\frac{a_1+\cdots + a_n+ b_1 + \cdots + b_m}{m+n}$

Now this simplifies to $$\frac{a_1+\cdots + a_n+ b_1 + \cdots + b_m}{m+n} = \frac{n\cdot a + m\cdot b}{m+n}=\frac{n}{m+n}a + \frac{m}{m+n} b$$

which is a weighted average of $a$ (the first average) and $b$ (the second average). The weights are determined by the size of each group.

2

Assume that group 1 has an average of $m_1$ and size $N_1$ and group 2 has an average of $m_2$ and size $N_2$ then you can take the weighted average of the two means two get the overall mean: $$ m= m1\cdot \frac{N_1}{N_1+N_2}+m2\cdot \frac{N_2}{N_1+N_2}. $$

1

$$\frac{4\cdot835+3.5\cdot4579}{835+4579}$$