Answer:
1) ![\chi^2 = \frac{(30-25)^2}{25} +\frac{(20-25)^2}{25} =1 +1 =2](https://tex.z-dn.net/?f=%20%5Cchi%5E2%20%3D%20%5Cfrac%7B%2830-25%29%5E2%7D%7B25%7D%20%2B%5Cfrac%7B%2820-25%29%5E2%7D%7B25%7D%20%3D1%20%2B1%20%3D2)
2) ![df = c-1 = 2-1](https://tex.z-dn.net/?f=%20df%20%3D%20c-1%20%3D%202-1)
Where c represent the number of categories c=2
Step-by-step explanation:
Previous concepts
A chi-square goodness of fit test "determines if a sample data matches a population".
A chi-square test for independence "compares two variables in a contingency table to see if they are related. In a more general sense, it tests to see whether distributions of categorical variables differ from each another".
Assume the following dataset:
Tall =30 , Short =20
We need to conduct a chi square test in order to check the following hypothesis:
H0: The deviations from a 1:1 ratio (25 tall and 25 short) are due to chance.
H1: The deviations from a 1:1 ratio (25 tall and 25 short) are NOT due to chance.
Part 1
So then we know that the expected values would be 25 for each case
The statistic to check the hypothesis is given by:
And if we replace we got:
![\chi^2 = \frac{(30-25)^2}{25} +\frac{(20-25)^2}{25} =1 +1 =2](https://tex.z-dn.net/?f=%20%5Cchi%5E2%20%3D%20%5Cfrac%7B%2830-25%29%5E2%7D%7B25%7D%20%2B%5Cfrac%7B%2820-25%29%5E2%7D%7B25%7D%20%3D1%20%2B1%20%3D2)
Part 2
For this case the degreed of freedom are given by:
![df = c-1 = 2-1](https://tex.z-dn.net/?f=%20df%20%3D%20c-1%20%3D%202-1)
Where c represent the number of categories c=2
And we can calculate the p value given by:
And we can find the p value using the following excel code:
"=1-CHISQ.DIST(2,1,TRUE)"