Stat question involving standard deviation

59 Views Asked by At

at a recent Halloween party, the boys appeared to be consuming more packages of Halloween candy than were the girls. if the mean number of the packages consumed by the 2 boys was 6, and that for the 8 girls was 4, and the standard deviation for the whole group was 2 packages, what was the correlation between gender and the number of packages consumed

can someone help me out, thanks.

1

There are 1 best solutions below

0
On BEST ANSWER

Well, correlation is (letting $g$ be the variable representing gender and $c$ the variable representing candy consumption):

$$ \rho = \frac{\mathrm{cov}(g, c)}{\sigma_{g}\sigma_{c}}. $$

Here, coding $g=1$ for girls and $g=0$ for boys, and also designating the means with bars:

$$ \mathrm{cov}(g, c) = \frac{1}{10}\sum_{i=1}^8(g_i-\bar{g})(c-\bar{c}) $$

We sum and then average over the 10 party-goers.

Adding and diving over the boys and the girls separately, this equals $$ \frac{1}{10}\sum_{i=1}^8(g-0.8)(c-5.5) = \frac{2}{10}(-0.8)(6-4.4) + \frac{8}{10}(0.2)(4-4.4) $$

So the covariance between gender and candies consumed is easily found using the above expression. It turns out to be $-0.32$. The only ingredient for our answer that we still need is the standard deviation of gender. This is:

$$ \sigma_g=\frac{1}{10}\sum_{i=1}^8(g-0.8)^2=\frac{2}{10}(-0.8)^2 + \frac{8}{10}(0.2)^2. $$

This is enough to find correlation. Indeed, $\sigma_g=0.16$ per the above expression and hence correlation is:

$$ \rho= -\frac{0.32}{0.16*2} = -1. $$

There is hence a perfect negative correlation. This would be positive, mind you, if we coded gender oppositely.