Introduction to Hypothesis Testing
Introduction to Hypothesis Testing
Hypothesis Testing
Type II Error
Failing to reject a false null hypothesis
The probability of committing a Type II error is called
.
Business Statistics, 4e, by Ken Black. © 2003 John Wiley & Sons. 9-11
Types of Errors
Example:
Statesville college claims that 94% of their graduates find
employment within six months of graduation. What will a type
I or type II error be?
H0: p = 0.94 (Claim)
Ha: p 0.94
A type I error is rejecting the null when it is true.
The population proportion is actually 0.94, but is rejected. (We
believe it is not 0.94.)
A type II error is failing to reject the null when it is false.
The population proportion is not 0.94, but is not rejected. (We
believe it is 0.94.)
Level of Significance
In a hypothesis test, the level of significance is your
maximum allowable probability of making a type I error. It is
denoted by , the lowercase Greek letter alpha.
Hypothesis tests are
based on .
The probability of making a type II error is denoted by , the
lowercase Greek letter beta.
By setting the level of significance at a small value, you
are saying that you want the probability of rejecting a true
null hypothesis to be small.
Commonly used levels of significance:
= 0.10 = 0.05 = 0.01
Statistical Tests
After stating the null and alternative hypotheses and
specifying the level of significance, a random sample is taken
from the population and sample statistics are calculated.
z
-3 -2 -1 0 1 2 3
Test
statistic
Right-tailed Test
2. If the alternative hypothesis contains the greater-
than symbol (>), the hypothesis test is a right-
tailed test.
H0: μ k
H a: μ > k
z
-3 -2 -1 0 1 2 3
Test
statistic
Two-tailed Test
3. If the alternative hypothesis contains the not-
equal-to symbol (), the hypothesis test is a two-
1
tailed test. In a two-tailed test, each
2 tail has an
H0: μ = k area of P.
H a: μ k
z
-3 -2 -1 0 1 2 3
Test Test
statistic statistic
Rejection and Non Rejection
Regions
Rejection Region Rejection Region
Business Statistics, 4e, by Ken Black. © 2003 John Wiley & Sons. 9-20
The cola-company in which an automatic bottling machine fills 1-
liter
bottles with cola. Now consider three different situations:
Continued.
Steps for Hypothesis Testing
5. Find the P-value.
6. Use the following decision rule.
Is the P-value less than or
equal to the level of No Fail to reject H0.
significance?
Yes
Reject H0.
Business Statistics, 4e, by Ken Black. © 2003 John Wiley & Sons. 9-27
A Classification of Hypothesis Testing
Procedures for Examining Differences
Fig. 15.9 Hypothesis Tests
Independent Paired
Samples Samples Independent Paired
Samples Samples
* Two-Group t * Paired
test * Chi-Square * Sign
t test * Mann-Whitney * Wilcoxon
* Z test
* Median * McNemar
* K-S * Chi-Square
Z-test
36
McClave, Statistics, 11th ed. Chapter 8: Inferences
Based on a Single Sample: Tests of Hypotheses
§ 7.2
Hypothesis Testing
for the Mean
(Large Samples)
Using P-values for a z-Test
The z-test for the mean is a statistical test for a population
mean. The z-test can be used when the population is normal
and is known, or for any population when the sample size n
is at least 30.
x μ σ
z standard error σx
σ n n
When n 30, the sample standard deviation s can be
substituted for .
Using P-values for a z-Test
Using P-values for a z-Test for a Mean μ
In Words In Symbols
1. State the claim mathematically State H0 and Ha.
and verbally. Identify the null
and alternative hypotheses.
2. Specify the level of Identify .
significance. x μ
z
3. Determine the standardized σ n
test statistic.
Use Table 4 in
4. Find the area that corresponds Appendix B.
to z.
Continued.
Using P-values for a z-Test
Using P-values for a z-Test for a Mean μ
In Words In Symbols
5. Find the P-value.
a. For a left-tailed test, P = (Area in left tail).
b. For a right-tailed test, P = (Area in right tail).
c. For a two-tailed test, P = 2(Area in tail of test statistic).
0.025 0.025
z
z0 = 1.96 0 z0 = 1.96
Continued.
Testing with Rejection Regions
Example continued:
A local telephone company claims that the average length
of a phone call is 8 minutes. In a random sample of 58
phone calls, the sample mean was 7.8 minutes and the
standard deviation was 0.5 minutes. Is there enough
evidence to support this claim at = 0.05?
H0: = 8 (Claim) Ha: 8
The standardized test statistic is The test statistic falls in
x μ 7.8 8 the rejection region, so
z
σ n 0.5 58 H0 is rejected.
3.05. z
z0 = 1.96 0 z0 = 1.96
55
McClave, Statistics, 11th ed. Chapter 8: Inferences
Based on a Single Sample: Tests of Hypotheses
8.2: Large-Sample Test of a Hypothesis
about a Population Mean
The Economics of
H0 : µ = 60,000
Education Review (Vol. Ha : µ ≠ 60,000
21, 2002) reported a Test Statistic:
mean salary for males x 0
with postgraduate z
x
degrees of $61,340, with
an estimated standard 61,340 60,000
z
error (s) equal to 2,185
$2,185. We wish to test, z .613
at the α = .05 level,
H0: µ = $60,000. Rejection Region: | z | > z.025 = 1.96
Do not reject H0
56
McClave, Statistics, 11th ed. Chapter 8: Inferences
Based on a Single Sample: Tests of Hypotheses
8.2: Large-Sample Test of a Hypothesis
about a Population Mean
57
McClave, Statistics, 11th ed. Chapter 8: Inferences
Based on a Single Sample: Tests of Hypotheses
§ 7.3
Hypothesis Testing
for the Mean
(Small Samples)
Critical Values in a t-Distribution
t0 = 2.500
Finding Critical Values for t
Example:
Find the critical values t0 and t0 for a two-tailed test
given = 0.10 and n = 12.
x μ
t
s n
72
McClave, Statistics, 11th ed. Chapter 8: Inferences
Based on a Single Sample: Tests of Hypotheses
8.4: Small-Sample Test of a Hypothesis
about a Population Mean
73
McClave, Statistics, 11th ed. Chapter 8: Inferences
Based on a Single Sample: Tests of Hypotheses
8.4: Small-Sample Test of a Hypothesis
about a Population Mean
74
McClave, Statistics, 11th ed. Chapter 8: Inferences
Based on a Single Sample: Tests of Hypotheses
Business Statistics: A Decision-Making Approach, 7e © 2008 Prentice-Hall, Inc. Chap 9-75
Chapter 8
78
McClave, Statistics, 11th ed. Chapter 8: Inferences
Based on a Single Sample: Tests of Hypotheses
Two Sample Hypothesis Testing
In a two-sample hypothesis test, two parameters
from two populations are compared.
H0: μ1 =
H0 : μ 1 μ 2 H0 : μ 1 μ 2
μ2
Ha: μ1 > μ2 Ha: μ1 < μ2
Ha: μ1 μ2
μx x μx μx μ1 μ2
1 2 1 2
and
2 2
σ σ
σx x σx2 σx2 1 2 .
1 2 1
n1 n2
2
Sampling distribution
for x1 x2 σx x
1 2
μ1 μ2 σx x
1 2
x1 x2
Two Sample z-Test
Two-Sample z-Test for the Difference Between
Means
A two-sample z-test can be used to test the difference
between two population means μ1 and μ2 when a large
sample (at least 30) is randomly selected from each
population and
x1 xthe samples are independent. The test
2
statistic is and the standardized test statistic is
z
x1 x2 μ1 μ2
where σx x
σ12 σ22
.
σx x
1 2
1 2
n1 n2
When the samples are large, you can use s1 and s2 in
place of 1 and 2. If the samples are not large, you can
still use a two-sample z-test, provided the populations are
normally distributed and the population standard
deviations are known.
Two Sample z-Test for the
Means
Using a Two-Sample z-Test for the Difference
Between Means (Large Independent Samples)
In Words In Symbols
1. State the claim mathematically. State H0 and Ha.
Identify the null and
alternative hypotheses.
2. Specify the level of Identify .
significance.
3. Sketch the sampling Use Table 4 in
distribution. Appendix B.
4. Determine the critical value(s).
5. Determine the rejection
regions(s). Continued.
Two Sample z-Test for the
Means
Using a Two-Sample z-Test for the Difference
Between Means (Large Independent Samples)
In Words In Symbols
x1 x2 μ1 μ2
6. Find the standardized test z
σx x
statistic. 1 2
-3 -2 -1 0 1 2 3
z
z0 = 1.28 Continued.
Two Sample z-Test for the
Means
Example continued:
H0: 1 2 z0 = 1.28
Ha: 1 > 2 (Claim) z
-3 -2 -1 0 1 2 3