You are on page 1of 16

Contents

CHAPTER 9.
TESTS OF HYPOTHESES 1. Hypothesis Testing

2. Tests on the Mean of a Normal Distribution, Variance Known


FOR A SINGLE SAMPLE 3. Tests on the Mean of a Normal Distribution, Variance Unknown
THUNTM38@FE.EDU.V N
4. Tests on a Population Proportion

Statistical Hypothesis
A statistical hypothesis is a statement about the parameters of one or more
populations.

I assume the
HYPOTHESIS TESTING average weight of
this school is 60 kg!

1
The Null Hypothesis, 𝑯𝟎 The Alternative Hypothesis, 𝑯𝟏
▪ States the claim or assertion to be tested ▪ Is the opposite of the null hypothesis
Example. The average weight of the students who are 10 years old is 30 kgs Example. The average weight of the students who are 10 years old is not equal to
(𝐻0 : 𝜇 = 30) 30 kgs (𝐻1 : 𝜇 ≠ 30)
▪ Is always about a population parameter, NOT about a sample statistic ▪ May or may not be proven
▪ Begin with the assumption that the null hypothesis is TRUE (similar to the
notion of innocent until proven guilty)
▪ May or may not be rejected

H 0 : μ = 30 H 0 : X = 30

One-Sided and Two-Sided Hypotheses The Hypothesis Testing


Example. Consider the propellant burning rate problem. A procedure leading to a decision about a particular hypothesis is called a test of
• Burning rate is a random variable a hypothesis.
• Suppose that our interest focuses on the mean burning rate (a parameter of this
distribution). Specifically, we are interested in deciding whether or not the
mean burning rate is 50 centimeters per second.
❖ Two-sided alternative hypothesis:
𝐻0 : 𝜇 = 50 and 𝐻1 : 𝜇 ≠ 50
❖ One-sided alternative hypothesis
𝐻0 : 𝜇 = 50 and 𝐻1 : 𝜇 > 50
Or
𝐻0 : 𝜇 = 50 and 𝐻1 : 𝜇 < 50

2
The Hypothesis Testing Process The Hypothesis Testing Process
▪ Claim: The population mean age is 50. ▪ Suppose the sample mean age was 𝑋ത = 20.
H0: μ = 50, H1: μ ≠ 50 ▪ This is significantly lower than the claimed mean population age of 50.
▪ Sample the population and find the sample mean. ▪ If the null hypothesis were true, the probability of getting such a different
sample mean would be very small, so you reject the null hypothesis.
Population
Population
▪ In other words, getting a sample mean of 20 is so unlikely if the population
mean was 50, you conclude that the population mean must not be 50.

Sample
Sample

The Hypothesis Testing Process The Hypothesis Testing Process


▪ If the sample mean is close to the stated population mean, the null hypothesis is
Sampling
not rejected.
Distribution of X
▪ If the sample mean is far from the stated population mean, the null hypothesis is
rejected.
▪ How far is “far enough” to reject H0?
20 μ = 50
▪ The critical value of a test statistic creates a “line in the sand” for decision
If H0 is true
making -- it answers the question of how far is far enough.
... then you reject
If it is unlikely that you
the null hypothesis
would get a sample
that μ = 50.
mean of this value ... ... When in fact this were
the population mean…

3
Possible Errors in Hypothesis Test Decision
The Test Statistic and Critical Values Making
Sampling Distribution of the test statistic ❑ Type I Error
▪ Reject a true null hypothesis
▪ A type I error is a “false alarm”
Region of Region of
▪ The probability of a Type I Error is 𝛼
Rejection Rejection
Region of • Called level of significance of the test
Non-Rejection • Set by researcher in advance
❑ Type II Error
Critical Values ▪ Failure to reject a false null hypothesis
▪ Type II error represents a “missed opportunity”
▪ The probability of a Type II Error is 𝛽
“Too Far Away” From Mean of Sampling Distribution

Possible Errors in Hypothesis Test Decision Possible Errors in Hypothesis Test Decision
Making Making
▪ The confidence coefficient (𝟏 − 𝜶) is the probability of not rejecting H0 when
it is true.
▪ The confidence level of a hypothesis test is (𝟏 − 𝜶)𝟏𝟎𝟎%.
▪ Level of significance = 𝛼
▪ The power of a statistical test (𝟏 − 𝜷) is the probability of rejecting H0 when
it is false.

4
Level of Significance and the Rejection
Region p-Value
▪ p-value: Probability of obtaining a test statistic equal to or more extreme than
H0: μ = 30 Level of significance = a the observed sample value given 𝐻0 is true
H1: μ ≠ 30
• The p-value is also called the observed level of significance
a /2 a /2 • It is the smallest value of 𝛼 for which 𝐻0 can be rejected
▪ Compare the p-value with 𝛼
• If p-value < a, reject H0
30 • If p-value  a, do not reject H0
Critical values

Rejection Region

p-Value Exercises
Example: Consider the two-sided hypothesis test for burning rate 𝐻0 : 𝜇 = 50 and State whether each of the following situations is a correctly stated hypothesis
𝐻1 : 𝜇 ≠ 50 with 𝑛 = 16 and 𝜎 = 2.5. Suppose that the observed sample mean is 𝑥ҧ = testing problem and why
51.3 centimeters per second.
By CLT, we have

5
Exercises General Procedure for Hypothesis Tests
A textile fiber manufacturer is investigating a new drapery yarn, which the 1. Parameter of interest: From the problem context, identify the parameter of
company claims has a mean thread elongation of 12 kilograms with a standard interest.
deviation of 0.5 kilograms. The company wishes to test the hypothesis H0: μ = 12 2. Null hypothesis, 𝐻0 : State the null hypothesis, 𝐻0 .
against H1: μ < 12, using a random sample of four specimens.
3. Alternative hypothesis, 𝐻1 : Specify an appropriate alternative hypothesis, 𝐻1 .
a. What is the type I error probability if the critical region is defined as x < 11.5 4. Test statistic: Determine an appropriate test statistic.
kilograms? 5. Reject 𝐻0 if: State the rejection criteria for the null hypothesis.
b. Find β for the case in which the true mean elongation is 11.25 kilograms. 6. Computations: Compute any necessary sample quantities, substitute these into
the equation for the test statistic, and compute that value.
c. Find β for the case in which the true mean is 11.5 kilograms. 7. Draw conclusions: Decide whether or not 𝐻0 should be rejected and report
d. Calculate the P-value if the observed statistic is that in the problem context.
d1. 𝑥ҧ = 11.25 d2. 𝑥ҧ = 11.0 d3. 𝑥ҧ = 11.75

Testing Hypotheses on the Mean,


Variance Known (Z-Tests)
TESTS ON THE MEAN OF A
NORMAL DISTRIBUTION,
VARIANCE KNOWN

6
Testing Hypotheses on the Mean, Testing Hypotheses on the Mean,
Variance Known (Z-Tests) Variance Known (Z-Tests)

Example 1 Example 1
H0: μ = 30 H1: μ ≠ 30 (This is a two-tail test)
a = 0.05, n = 100, σ = 0.8, 𝑥ҧ = 29.84
Critical values Z are ±1.96
ҧ
𝑥−𝜇 29.84−30
Test statistic: 𝑧0 = = = −2.0
𝜎/ 𝑛 0.8/10

7
Example 1 Example 1
Conclusion: reject the null hypothesis and conclude there is sufficient evidence
that the mean diameter of a manufactured bolt is not equal to 30

Example 2 Example 3
Air crew escape systems are powered by a solid propellant. The burning rate of The heights of all adults in a community is known to have standard deviation of
this propellant is an important product characteristic. Specifications require that 0.03m. A random sample of 43 adults are collected, and their average height is
the mean burning rate must be 50 centimeters per second. We know that the 1.64m.
standard deviation of burning rate is σ = 2 centimeters per second. The
a) Test the hypothesis that the true average height of all adults in the community
experimenter decides to specify a type I error probability or significance level of α
= 0.05 and selects a random sample of n = 25 and obtains a sample average is 1.7m, at α = 0.05.
burning rate of 𝑥ҧ = 51.3 centimeters per second. What conclusions should be b) Use both tradition and P-value methods, at the significance level of 5%, test
drawn? the hypothesis that the average height of all adults in the community is greater
than 1.6m.

8
Exercises Exercises
State the null and alternative hypothesis in each case. A hypothesis will be used to test that a population mean equals 5 against the
alternative that the population mean is less than 5 with known variance σ. What
a. A hypothesis test will be used to potentially provide evidence that the
is the critical value for the test statistic 𝑍0 for the following significance levels?
population mean is more than 10.
a. 0.01 b. 0.05 c. 0.10
b. A hypothesis test will be used to potentially provide evidence that the
population mean is not equal to 7.
c. A hypothesis test will be used to potentially provide evidence that the
population mean is less than 5.

Exercises Exercises
Output from a software package follows: For the hypothesis test H0: μ = 10 against H1: μ > 10 and variance known,
One-Sample Z: calculate the P-value for each of the following test statistics.
Test of mu = 20 vs > 20
a. z0 = 2.05 b. z0 = −1.84 c. z0 = 0.4
The assumed standard deviation = 0.75

a. Fill in the missing items. What conclusions would you draw?


b. Is this a one-sided or a two-sided test?
c. Use the normal table and the preceding data to construct a 95% two-sided CI
on the mean.
d. What would the P-value be if the alternative hypothesis is H1: μ ≠ 20?

9
Exercises Exercises
Output from a software package follows: A manufacturer produces crankshafts for an automobile engine. The crankshafts
wear after 100,000 miles (0.0001 inch) is of interest because it is likely to have
an impact on warranty claims. A random sample of n = 15 shafts is tested and
sample mean = 2.78. It is known that σ = 0.9 and that wear is normally
distributed.
Test H0: μ = 3 versus H1: μ ≠ 3 using α = 0.05.
a. Fill in the missing items. What conclusions would you draw?
b. Is this a one-sided or a two-sided test?
c. If the hypothesis had been H0: μ = 98 versus H1: μ > 98, would you reject the null
hypothesis at the 0.05 level of significance?
d. Use the normal table and the preceding data to construct a 95% lower bound on the mean.
e. What would the P-value be if the alternative hypothesis is H1: μ ≠ 99?

Exercises Exercises
The life in hours of a battery is known to be approximately normally distributed The bacterial strain Acinetobacter has been tested for its adhesion properties. A
with standard deviation σ = 1.25 hours. A random sample of 10 batteries has a sample of five measurements gave readings of 2.69, 5.76, 2.67, 1.62 and 4.12
mean life of 𝑥ҧ = 40.5 hours. dyne-cm2. Assume that the standard deviation is known to be 0.66 dyne-cm2 and
a. Is there evidence to support the claim that battery life exceeds 40 hours? Use α that the scientists are interested in high adhesion (at least 2.5 dyne-cm2).
= 0.5. a. Should the alternative hypothesis be one-sided or two-sided?
b. Test the hypothesis that the mean adhesion is 2.5 dyne-cm2.
b. What is the P-value for the test in part (a)? c. What is the P-value of the test statistic?

10
Testing Hypotheses on the Mean,
Variance Unknown (T-Tests)
TESTS ON THE MEAN OF A
NORMAL DISTRIBUTION,
VARIANCE UNKNOWN

Testing Hypotheses on the Mean, Testing Hypotheses on the Mean,


Variance Unknown (T-Tests) Variance Unknown (T-Tests)

11
Example Example (cont.)
𝐻0 : 𝜇 = 0.82 vs 𝐻1 : 𝜇 > 0.82, 𝛼 = 0.05 𝐻0 : 𝜇 = 0.82 vs 𝐻1 : 𝜇 > 0.82, 𝛼 = 0.05
𝑛 = 15, 𝑥ҧ = 0.83725, 𝑠 = 0.02456 𝑛 = 15, 𝑥ҧ = 0.83725, 𝑠 = 0.02456
ҧ 0
𝑥−𝜇 ҧ 0
𝑥−𝜇
Test statistic: 𝑡0 = = 2.72 Test statistic: 𝑡0 = = 2.72
𝑠/ 𝑛 𝑠/ 𝑛
Critical value: 𝑡0.05, 14 = 1.761 Reject 𝐻0 if p-value < 𝛼
The critical region: Reject 𝐻0 if 𝑡 > 𝑡0.05, 14 Conclusion: From Appendix A Table II we find for a t distribution with 14 degrees
Conclusion: we reject the null hypothesis. of freedom that t0 = 2.72 falls between two values: 2.624, for which α = 0.01, and
2.977, for which α = 0.005. Because this is a one-tailed test, we know that the P-
value is between those two values, that is, 0.005 < P < 0.01. Therefore, because P
< 0.05, we reject H0 and conclude that the mean coefficient of restitution exceeds
0.82.

Example (cont.) Example


𝐻0 : 𝜇 = 0.82 vs 𝐻1 : 𝜇 > 0.82, 𝛼 = 0.05 The heights of all adults in a community is known to have a normal distribution. A
𝑛 = 15, 𝑥ҧ = 0.83725, 𝑠 = 0.02456 random sample are collected and the heights (in meters) are recorded as follows:
1.55 1.60 1.58 1.62 1.65 1.70 1.68
Test the hypothesis that the average height of all adults in the community is at
most 1.60(m), at the significance level of 5%.

The reported P-value is 0.008. Because the 95% lower confidence bound exceeds 0.82,
we would reject the hypothesis that H0: μ = 0.82 and conclude that the alternative
hypothesis H1: μ > 0.82 is true.

12
Exercises Exercises
A hypothesis will be used to test that a population mean equals 10 against the For the hypothesis test H0: μ = 7 against H1: μ ≠ 7 with variance unknown and n =
alternative that the population mean is greater than 10 with unknown variance.
What is the critical value for the test statistic T0 for the following significance 20, approximate the P-value for each of the following test statistics.
levels? a. t0 = 2.05 b. t0 = −1.84 c. t0 = 0.4
a. α = 0.01 and n = 20 b. α = 0.05 and n = 12
c. α = 0.10 and n = 15

Exercises Exercises
For the hypothesis test H0: μ = 5 against H1: μ < 5 with variance unknown and n = An article in the ASCE Journal of Energy Engineering (1999, Vol. 125, pp. 59–
12, approximate the P-value for each of the following test statistics. 75) describes a study of the thermal inertia properties of autoclaved aerated
a. t0 = 2.05 b. t0 = −1.84 c. t0 = 0.4 concrete used as a building material. Five samples of the material were tested in a
structure, and the average interior temperatures (∘C) reported were as follows:
23.01, 22.22, 22.04, 22.62, and 22.59.
Test the hypotheses H0: μ = 22.5 versus H1: μ ≠ 22.5, using α = 0.05. Find the P-
value.

13
Exercises Exercises
Consider the following computer output.
Cloud seeding has been studied for many decades as a weather modification
procedure (for an interesting study of this subject, see the article in
Technometrics, “A Bayesian Analysis of a Multiplicative Treatment Effect in
Weather Modification,” 1975, Vol. 17, pp. 161–166). The rainfall in acre-feet
from 20 clouds that were selected at random and seeded with silver nitrate
follows: 18.0, 30.7, 19.8, 27.1, 22.3, 18.8, 31.8, 23.4, 21.2, 27.9, 31.9, 27.1, 25.0,
24.7, 26.9, 21.8, 29.2, 34.8, 26.7, and 31.6.
Can you support a claim that mean rainfall from seeded clouds exceeds 25 acre- a. Fill in the missing values. You may calculate bounds on the P-value. What conclusions
feet? Use α = 0.01. Find the P-value. would you draw?
b. Is this a one-sided or a two-sided test?
c. If the hypothesis had been H0: μ = 90 versus H1: μ > 90, would your conclusions change?

Large-Sample Tests on a Proportion

TESTS ON A POPULATION
PROPORTION

14
Example Exercises
𝐻0 : 𝑝 = 0.05 vs 𝐻1 : 𝑝 < 0.05 A company claims that the percentage of defective products is kept under control,
that is less than 3%. In a random sample of 135 products it is found out that 6 of
𝑛 = 200, 𝑥 = 4, 𝛼 = 0.05 them are defective. Test the claim of the company at the significance level of 5%.
𝑥−𝑛𝑝0
Test statistic: 𝑧0 = = −1.95
𝑛𝑝0 1−𝑝0

Reject 𝐻0 : p = 0.05 if the p-value is less than 0.05.


Because z0 = −1.95, the P-value is Φ(−1.95) = 0.0256, so we reject H0

Exercises Exercises
Consider the following computer output Suppose that of 1000 customers surveyed, 850 are satisfied or very satisfied with
a corporation’s products and services.
a. Test the hypothesis H0: p = 0.9 against H1: p ≠ 0.9 at α = 0.05. Find the P-
value.
b. Explain how the question in part (a) could be answered by constructing a 95%
two-sided confidence interval for p.
Using the normal approximation,
a. Is this a one-sided or a two-sided test?
b. Complete the missing items.

15
Exercises Exercises
An article in the British Medical Journal [“Comparison of Treatment of Renal An article in Fortune (September 21, 1992) claimed that nearly one-half of all
Calculi by Operative Surgery, Percutaneous Nephrolithotomy, and Extra- engineers continue academic studies beyond the B.S. degree, ultimately receiving
Corporeal Shock Wave Lithotripsy” (1986, Vol. 292, pp. 879–882)] repeated that either an M.S. or a Ph.D. degree. Data from an article in Engineering Horizons
percutaneous nephrolithotomy (PN) had a success rate in removing kidney stones (Spring 1990) indicated that 117 of 484 new engineering graduates were planning
of 289 of 350 patients. The traditional method was 78% effective. graduate study.
a. Is there evidence that the success rate for PN is greater than the historical a. Are the data from Engineering Horizons consistent with the claim reported by
success rate? Find the P-value. Fortune? Use α = 0.05 in reaching your conclusions. Find the P-value for this test.
b. Explain how the question in part (a) could be answered with a confidence b. Discuss how you could have answered the question in part (a) by constructing a
interval. two-sided confidence interval on p.

16

You might also like