Sample Problems
Sample Problems
“Sample problems in Hypothesis Testing (Two Samples) The formula for t computed requires the mean of
our samples.
Problem #1 1 1
PETA or the Philippine Ethical Treatment for x1
n
x 540 108
5
Animals claims that the mean daily costs of food for dogs
1 1
and cats are the same. The results for samples of the two x2 x 545 109
types of pets are show below. At 5% level of significance, n 5
is there sufficient evidence to support the claim?
x1 x2 108 109
Cats 125 110 105 100 100 t 0.2
Dogs 115 110 110 105 105 2 2
s s 108.75 17.5
1
2
n1 n2 5 5
Solution:
Since the population variance of each group is not
given and the sample sizes are less than 30, hence we will i.e. tcomputed 0.2
use t-test. The claim is “the mean daily cost of food for
dogs and cats are the same”. (Step 4) Decision
Since the computed t value of -0.2 is greater than
(Step 1) State the null and alternative hypotheses -2.57, hence the decision is not to reject the null
hypothesis.
Hₒ: 1 2 , The mean daily cost of food for dogs and
cats are the same. (claim) (Step 5) Conclusion
Hₐ: 1 2 , The mean daily cost of food for dogs and At 5% level of significance, there is sufficient
evidence to support the claim that the mean daily cost of
cats are not the same.
food for dogs and cats are the same.
(Step 2) Determine the critical value(s)
Problem #2
The economist wants to prove that there is
Since we are in t-test, we need to consider the
significant difference between the mean hourly rates
degrees of freedom, and the level of significance. First,
charged by automobile mechanics in Manila and Quezon
we will determine the variance of each group.
City. The population variance of the hourly rates for each
city is 703.93 (Manila) and 698.87 (Quezon). He
x x
2
435 randomly selects 10 auto repair facilities from both cities
s2
108.75
n 1 and record their hourly rates (in pesos). For instance the
1
4
computed mean hourly rates for Manila and Quezon City
x x
2
70
2
s 17.5 is 170 pesos and 165 pesos respectively. At 5% level of
n 1
2
4 significance, is there sufficient evidence to support the
Use rule of thumb to decide whether to assume claim of the economist?
the population variances are equal or not.
s1 Solution:
0.5 2 Since the population variance of each group is
s2
given hence we can use z-test. The claim is “There is
0.5 10.43 2 significant difference between the mean hourly rates
4.18
charged by automobile mechanics in Manila and Quezon
0.5 2.5 2
City”.
Since the computed ratio did not meet the
requirement, hence we will assume that the population
Hₒ: 1 2 , There is no significant difference between
variances are not equal. Compute for the degrees of
freedom. (Round down the result) the mean hourly rates charged by automobile mechanics
in Manila and Quezon City.
2 Hₐ: 1 2 , There is significant difference between the
s12 s22 108.75 17.5
2
Using the t distribution table we will have ±2.57 i.e. zcritical 1.96
i.e. tcritical 2.57
(Step 3) Compute for test statistic The claim is “there is significant relationship between the
number of employees and the production units”
x1 x2 170 165 (Step 1) State the null and alternative hypotheses
z 0.42 Hₒ: 0 , There is no significant relationship between
12 22 703.93 698.87
the number of employees and the production units.
n1 n2 10 10
Hₐ: 0 , There is significant relationship between the
i.e. zcomputed 0.42 number of employees and the production units. (claim)
Solution:
Compute for the coefficient of correlation using
pearson.
(x) (y) x² y² xy
2 20 4 400 40
4 15 16 225 60
6 25 36 625 150
8 28 64 784 224
5 22 25 484 110
25 110 145 2518 584
n xy x y
r
n x 2 x 2 n y 2 y 2
5 584 25 110
5 145 25 2 5 2518 110 2
r 0.77