Professional Documents
Culture Documents
Angeline Domalayas
Presented by:
I. Test for Goodness of Fit
Where:
X² = the chi-square test
O = observed frequencies
E = expected frequencies
Example:
Suppose you wanted to see if there was a difference in the number of arrest in a certain
city for four types of crimes. A random sample of 160 arrest showed the following
distribution.
Larceny Property crimes Drug use Driving under the
thefts influence
38 50 28 44
The actual frequencies are called observed frequencies. The frequencies obtained by
calculation are called expected frequencies.
Before computing the test value, you must state the hypotheses. The null
hypotheses should be a statement indicating that there is no difference or
no change.
Ho: There is no difference in the number of arrest for each type of crime.
H1: There is difference in the number of arrest for each type of crime.
SOLUTION:
STEP 1. State the hypotheses and identify the claim.
Ho: There is no difference of arrest for each type of crime. (claim)
H1: There is a difference of arrest for each type of crime.
STEP 2. Find the critical value. The degrees of freedom are 4-1= 3 and at
α=0.05 the critical value from table G in appendix A is 7.815.
STEP 3. Compute the test value. Note the expected values are found by
E=n/k (160/4=40).
X²=Ʃ(O-E)² = (38-40)² + (50-40)² + (28-40)² + (44-40)²
E 40 40 40 40
= 0.1+2.5+3.6+0.4
=6.6
STEP 4. Make the decision. The decision is to not reject the null
hypothesis, since 6.6 ˂ 7.815
The chi-square computed value 6.6 is less than chi-square tabular value 7.815 at 0.05 level
of significance with 3 degrees of freedom, so it confirmed that it will not reject the null
hypothesis.
II. Test for Independence
• The chi-square independence test is used to
test whether two variables are independent
O= observed of frequencies
E= expected frequencies
The data for two variables are placed in a contingency table. One variable is
called the row variable, and the other variable is called the column variable. The
table is called an R x C table where R is the number of rows and C is the number
of columns.
Each value in the table is called a cell value.
The formula for computing the expected values for each cell
is:
Since the main question is whether there is a difference in opinion, the null hypothesis
is stated as follows:
Ho: The opinion about the procedure is independent of the procedure
The alternative hypothesis is stated as follows:
H1: The opinion about the procedure is dependent on the profession.
To get the degree of freedom :
d·f = (R-1)(C-1)
d·f= (2-1)(3-1)= 2
1. Find the sum of each row and each column, and find the grand total.
Group Prefer new Prefer old No preference Total
procedure procedure
Nurses 100 80 20 200
Doctors 50 120 30 200
2. For each cell, multiply the corresponding row sum by the column sum and divide by the grand total, to
get the expected value.
EXPECTED VALUE
Group Prefer new Prefer old No Preference Total
procedure procedure
Nurses 75 100 25 200
Doctors 75 100 25 200
Total 150 200 50 400
=8.33+4+1+8.33+4+1
=26.667
4. Make decisions. Since the test value 26.667 is larger than the critical value 5.991, the decision is to
reject the null hypothesis.
Conclusion: There is enough evidence to support the claim that opinion is related to
(dependent on) profession, that is, that the doctors and nurses differ in their opinions
about the procedure.
III. Test for Homogeneity of
Proportions.
• The test of homogeneity of proportions is used to test the claim that
different populations have the same proportion of subjects who have
a certain attitude or characteristics.
• This test is concerned with two or more samples, with only one
criterion variable. This test is use to determine if two or more
population are homogenous. Its data distribution are similar with
respect to a particular criterion variable.
Example:
A psychologist randomly selected 100 people from each of four income groups and asked
them if they were “very happy”. For people who made less than $30,000. 24% responded
yes. For people who made $30,000 to $74,999. 33% responded yes. For people who made
$75,000 to $99,999, 38% responded yes, and for people who made $100, 000 or more, 49%
responded yes. At α = 0.05, test the claim that there is no difference in the proportion of
people in each economic group who were very happy.
Solution:
It is necessary to make a table showing the number of people in each group who responded yes and the
number of people in each group who responded no.
For group 1, 24% of the people responded yes, so 24% of 100 = 0.24(100)=24 responded yes and 100-
24=76 responded no.
For group 2, 33% of the people responded yes, so 33% of 100 = 0.33(100)=33 responded yes and 100-
33=67 responded no.
For group 3, 38% of the people responded yes, so 38% of 100 = 0.38(100)=38 responded yes and 100-
38=62 responded no.
For group 4, 49% of the people responded yes, so 49% of 100 = 0.49(100)=49 responded yes and 100-
49=51 responded no.
Tabulate the data in a table, and find the sums of the row and
columns as shown.
E1,1 = (144)(100) =36 E1,2 = (144)(100) =36 E1,3 = (144)(100) =36 E1,4 (144)(100) =36
400 400 400 400
E2,1 = (256)(100) =64 E2,2 = (256)(100) =64 E2,3 =(256)(100) =64 E2,4 =(256)(100) =64
400 400 400 400
Step 4. Make the decision. Reject the null hypothesis since 14.150 is greater than 7.815.
Step 5. Summarize the results. There is enough evidence to reject the claim that there is
no difference in proportions. Hence, the incomes seem to make a difference in the
proportions.
IV. Analysis of Variance ( ANOVA)
• When the F test is used to test a hypothesis concerning the
means of three or more populations, the technique is called
analysis of variance – ANOVA.
Even though you are comparing three or more means in this use of the
F test, variances are used in the test instead of means.
• When the F test, two different estimates of the population variance
are made. The first estimate is called the between-group variance.
• The second estimate, the within-group variance, is made by
computing the variance using all the data and is not affected by
differences in the means.
• If there is no difference in the means, the between-group variance
estimate will be approximately equal to one.
=225.951= 25.106
9
e. Find the F test value.
F= ˢ²B = 121.359 = 4.83
25.106
ˢ²W
Step 4. Make the decision. The test value 4.83 is greater than 4.26, so
the decision is to reject the null hypothesis.