Transcript Chapter 7
Chapter 7
Hypothesis Testing
GOALS:
• Define a hypothesis and hypothesis testing.
• Describe the five step hypothesis testing procedure.
• Distinguish between a one-tailed and a two-tailed test of
hypothesis.
• Conduct a test of hypothesis about a population mean.
• Conduct a test of hypothesis about a population
proportion.
• Define Type I and Type II errors.
Hypothesis
testing
Definitions
& steps
hypothesis
testing
One-tailed
test
Two-tailed
test
p-value
Type I &
Type II error
What is a Hypothesis?
A statement about the value of a population
parameter
Data are then used to check the reasonableness
of the statement
Examples
The
mean monthly income for systems analysts is
Rs15,000.
Twenty percent of all customers at Pizza Hut return
for another meal within a month.
What is Hypothesis Testing?
A procedure, based on sample evidence
and probability theory, used to determine
whether the hypothesis is a reasonable
statement and should not be rejected, or is
unreasonable and should be rejected.
Definitions
Null Hypothesis (H0): A statement about the value of a
population parameter
Alternative Hypothesis (H1): A statement that is
accepted if the sample data provide evidence that the
null hypothesis is false.
Level of Significance: The probability of rejecting the
null hypothesis when it is actually true.
Definitions
Test statistic: A value, determined from
sample information, used to determine
whether or not to reject the null
hypothesis.
Critical value: The dividing point between
the region where the null hypothesis is
rejected and the region where it is not
rejected.
Five step procedure for testing a hypothesis
Step 1:
State null & alternate hypothesis
Step 2:
Select a level of significance
Step 3:
Identify the test statistic
Step 4:
Formulate a decision rule
Do not reject null
Step 5:
Take a sample to arrive at a decision
Reject null
State null & alternate hypothesis
Example 1: A recent article indicated the mean age
of US commercial aircraft is 15 years
The null hypothesis represents the current or
reported condition. It is written as:
H0: = 15
The alternative hypothesis is that the statement
is not true, that is:
H1: 15
State null & alternate hypothesis
Example 2: A recent article indicated the mean age
of US commercial aircraft is no more than15
years
The null hypothesis represents the current or
reported condition. It is written as:
H0: 15
The alternative hypothesis is that the statement
is not true, that is:
H1: > 15
Select a level of significance
The level of significance (sometimes
called the level of risk or critical value) is
designated as (Greek letter alpha)
Select the test statistic for mean
(for large sample)
For the mean () when is known or the sample
size is large (n 30), use Z distribution as test
statistic
Z value is based on the sampling distribution of
X, which is normally distributed when the sample
is reasonably large with a mean (x) equal to
and a standard deviation x, which is equal to
/n
X
Z
n
Select the test statistic for mean
(for small sample)
When the sample is less than 30 and the
population standard deviation is not known we
use the t distribution
X
t
s
n
One-Tailed Tests
A test is one-tailed when the alternate
hypothesis, H1 , states a direction
H1: The mean yearly commissions earned by fulltime Insurance agent is more than Rs35,000.
(µ>Rs35,000)
H1: The mean speed of trucks traveling on A1 route
is less than 60 km per hour. (µ<60)
H1: Less than 20 percent of the customers pay cash
for their gasoline purchase. (µ<.20)
Note; when region of rejection is only in one tail/end
One-Tailed Tests
Sampling Distribution for the test statistic (Z) for a oneTailed Test (0.05 Level of Significance)
[H0: h & H1: >h ]
Rejection region
Do not
reject H0
0
0.95
1.65
0.05
Critical value
One-Tailed Tests
Sampling Distribution for the test statistic (Z) for a oneTailed Test (0.05 Level of Significance)
[H0: h & H1: <h ]
Rejection region
Do not
reject H0
1.65
0.05
0
0.95
Critical value
One-tailed test (Rejection of null
hypothesis)
H0: h & H1: >h
when
+ critical value < + test statistic
H0: h & H1: <h
when
- critical value > - test statistic
0
0
Critical value
Test statistic
Critical value
Test statistic
Two-Tailed Tests
A test is two-tailed when the alternate
hypothesis, H1 , does not state a direction
H1: The mean yearly commissions earned by
full-time Insurance agent is not equal
Rs35,000. (µRs35,000)
H1: The mean speed of trucks traveling on
A1 route is not equal 60 km per hour. (µ60)
Two-Tailed Tests
Sampling Distribution for the test statistic (Z) for a
one-Tailed Test (0.05 Level of Significance)
Rejection region
Rejection region
Do not
reject H0
-1.96
0.95
0.025
Critical value
0
1.96
0.025
Critical value
Two-tailed test (Rejection of null
hypothesis)
H0: =h & H1: h
when
+ critical value < + test statistic
or
- critical value > - test statistic
0
- Test statistic
+ Test statistic
- Critical value + Critical value
Example 1
The Glen valley Steel Company manufactures steel bars. If the
production process is working properly, it turns out steel bars with
mean length of at least 2.8 feet with a standard deviation of 0.20
feet. Longer steel bars can be used or altered but shorter steel bars
must be scrapped. A sample of 50 bars is selected from the
production line. The sample indicates a mean of length 2.73 feet.
The company wants to determine whether the production equipment
needs to be adjusted.
a)
State the null and alternative hypotheses.
b)
If the company wants to test the hypothesis at the 0.05 level of
significance, what decision would be made using the critical value
approach to hypothesis testing?
Example 1
Step 1 - Null hypothesis & alternative hypothesis
H0: 2.8
H1: < 2.8
One-tailed test because alternative hypothesis
shows a direction
n = 50 >30 use Z test and = 0.2
Example 1
Step 2 – Level of significance
level of significance is 0.05
Z value related to 0.05 = -1.645
Step 3 – Identify the test statistic
X 2.73, n 50, μ 2.8, σ 0.02
X μ 2.73 2.8
Z
2.47
σ n 0.20 50
Example 1
Step 4 & 5 – Formulate a decision rule &
take a decision
Rejection region
Test statistic
-2.47
Do not
reject H0
-1.645
0
Critical value
Decision Rule
Test statistic < critical value
Reject null hypothesis
Example 2
The Glen valley Steel Company manufactures steel bars. If the
production process is working properly, it turns out steel bars with
mean length of at least 2.8 feet. Longer steel bars can be used or
altered but shorter steel bars must be scrapped. A sample of 20
bars is selected from the production line. The sample indicates a
mean of length 2.73 feet and a standard deviation of 0.20 feet. The
company wants to determine whether the production equipment
needs to be adjusted.
a)
State the null and alternative hypotheses.
b)
If the company wants to test the hypothesis at the 0.05 level of
significance, what decision would be made using the critical value
approach to hypothesis testing?
Example 2
Step 1 - Null hypothesis & alternative hypothesis
H0: 2.8
H1: < 2.8
One-tailed test because alternative hypothesis
shows a direction
n = 20 <30 use t-distribution and = 0.2
Example 2
Step 2 – Level of significance
level of significance is 0.05 & degree of
freedom = 19
t value related to 0.05 = -1.729
Step 3 – Identify the test statistic
X 2.73, n 50, μ 2.8, σ 0.02
X μ 2.73 2.8
t
1.57
s n 0.20 20
Example 2
Step 4 & 5 – Formulate a decision rule &
take a decision
Rejection region
Do not
reject H0
-1.729 -1.57 0
Critical value
Decision Rule
Test statistic > critical value
Do not reject null hypothesis
Test statistic
Exercise 1
a)
b)
The director of manufacturing at a clothing factory needs
to determine whether a new machine is producing a
particular type of cloth according to the manufacturers
specifications, which indicate that the cloth should have a
mean breaking strength of 70 pounds and a standard
deviation of 3.5 pounds. A sample of 49 pieces of cloth
reveals a sample mean breaking strength of 69.1 pounds
State the null and alternative hypotheses.
Is there evidence that the machine is not meeting the
manufacturers specifications for average breaking
strength? (Use a 0.05 level of significance)
Exercise 2
a)
b)
The director of manufacturing at a clothing factory needs
to determine whether a new machine is producing a
particular type of cloth according to the manufacturers
specifications, which indicate that the cloth should have a
mean breaking strength of 60 pounds and a standard
deviation of 2.5 pounds. A sample of 19 pieces of cloth
reveals a sample mean breaking strength of 59.1 pounds
State the null and alternative hypotheses.
Is there evidence that the machine is not meeting the
manufacturers specifications for average breaking
strength? (Use a 0.05 level of significance)