Post on 01-Jan-2016
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 1
Introductory Statistics: A Problem-Solving Approachby Stephen Kokoska
Chapter 8: Confidence Intervals Based on a Single
Sample
Introduction
A single value of a statistic computed from a sample conveys little information about confidence and reliability.
Alternative method: use a single value to construct an interval in which we are fairly certain the true value lies.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 2
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 3
Point Estimation
Point estimate of a population parameter: a single number computed from a sample which serves as a best guess for the parameter.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 4
Estimator
An estimator (statistic) is a rule used to produce a point estimate of a population parameter.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 5
Estimator and Estimate
Estimator: a statistic of interest, a random variable. An estimator has a distribution, a mean, a variance, and a standard deviation.
Estimate: a specific value of an estimator.
Unbiased Estimator
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 6
Unbiased and Biased Estimators
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 7
Copyright 2011, W.H.Freeman and Company, all rights
reserved 8
Some Unbiased Estimators• The sample mean is an unbiased statistic for
estimating the population mean.
• The sample proportion is an unbiased statistic for estimating the population proportion.
• The sample variance is an unbiased statistic for estimating the population variance.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 9
Minimum-Variance Unbiased Estimator
If several statistics from which to choose, select the one with the smallest possible variance.
If one of these statistics has the smallest possible variance, it is called the minimum-variance unbiased estimator (MVUE).
Remarks
If the underlying population is normal, the sample mean is the MVUE for estimating the population mean.
So, if the population is normal, the sample mean is a really good statistic to use for estimating the populations mean.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 10
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 11
Confidence Interval (CI)
A confidence interval (CI) for a population parameter is an interval of values constructed so that, with a specified degree of confidence, the value of the population parameter lies in this interval.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 12
Confidence Coefficient
The confidence coefficient is the probability the CI encloses the population parameter in repeated samplings.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 13
Confidence Level
The confidence level is the confidence coefficient expressed as a percentage.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 14
Critical Value
zα/2 is a critical value. It is a value
on the measurement axis in a
standard normal distribution such
that
P(Z ≥ zα/2) = α/2.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 15
Remarks
1. The subscript on z could be any variable, or letter.
2. Z /2: a z value such that there is /2 of the area (probability) to the right of z /2.
z /2 : the negative critical value.
Remarks (cont.)
3. Critical values are always defined in terms of right-tail probability.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 16
Remarks (cont.)
4. zα/2 critical values are easy to find by using the complement rule and working backward.
P(Z ≥ z /2) = /2
P(Z ≤ z /2) = 1 /2
Work backward in Table 3 to find z
/2.Copyright 2011 by W. H.
Freeman and Company. All rights reserved. 17
Critical Values
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 18
Example: Critical Values for 95% Confidence Level
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 19
Constructing a General 100(1 )% Confidence Interval for a Population Mean
1. Find a symmetric interval about 0 such that the probability Z lies in this interval is 1 .
P(zα/2 < Z < zα/2) = 1 .
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 20
Constructing a General 100(1 )% Confidence Interval for a Population Mean
2. Substitute for Z.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 21
12/2/ z
n
XzP
Constructing a General 100(1 )% Confidence Interval for a Population Mean
3. Manipulate this equation to obtain the probability statement.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 22
12/2/n
zXn
zXP
Critical Values
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 23
Illustration of a (1 ) 100% CI
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 24
Illustration of 95% CI
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 25
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 26
How to Find a 100(1 α)% CI for µ When σ is Known
Given a random sample of size n from a population with mean µ, if
1. the underlying population distribution is normal and/or n is large, and
2. the population standard deviation σ is known, then a 100(1 α)% confidence interval for µ has as endpoints the values
nzx
2
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 27
Remarks
1. This CI for µ can only be used if σ is known.
2. If n large and σ unknown, some statisticians substitute s for σ. This produces an approximate confidence interval.Next section: an exact confidence interval for when is unknown.
3. As confidence coefficient increases (n, constant), CI is wider.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 28
Concepts to Remember
1. The population parameter, µ, is fixed.
The confidence interval varies from sample to sample.
Correct statement: We are 95% confident the interval captures the true mean µ.
Incorrect statement: We are 95% confident µ lies in the interval.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 29
Concepts to Remember (cont.)
2. Confidence coefficient: a probability, a long-run limiting relative frequency.
In repeated samples, the proportion of confidence intervals that capture the true value of µ approaches the confidence coefficient, in this case, 0.95.
Cannot be certain about any one specific confidence interval.
The confidence is in the long-run process.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 30
Example: Tire Weight
The total weight of a filled tire can dramatically affect the performance and safety of an automobile. Some transportation officials argue that mechanics should check the tire weights of every vehicle as part of an annual inspection.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 31
Example (cont.)
Suppose the weight of a 185/60/14 filled tire is normally distributed
with standard deviation 1.25 pounds. In a random sample of 15 filled tires, the sample mean weight was 18.75 pounds. Find a 95% confidence interval for the true mean weight of 185/60/14 tires.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 32
Example (cont.)
nzx
025.0
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 33
Example (cont.)
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 34
63.075.1815
25.1)96.1(75.18
Example (cont.)
(18.12, 19.38) is a 95% confidence interval for the true mean weight (in pounds) of 185/60/14 tires.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 35
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 36
Necessary Sample Size
1. Suppose n is large (unknown), is known, confidence level is 100(1 )%.
2. Desired width W. B = W/2: bound on the error of estimation.B is half the width of the confidence interval.
Necessary Sample Size (cont.)
3. Confidence interval endpoints:
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 37
nzx
2/
Necessary Sample Size (cont.)
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 38
nzB
2/
Necessary Sample Size (cont.)
4. Solve for n and the resulting formula is:
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 39
2
2/
B
zn
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 40
A Confidence Interval for a Population Mean When σ Is Unknown
Confidence interval for µ based on Z: valid only when σ is known which is unrealistic.
Theorem
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 41
Comparison of Density Curves
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 42
Properties of t Distribution
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 43
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 44
Critical Value
tα is a critical value related to a t
distribution with df degrees of
freedom. If T has a t distribution
with df degrees of freedom then
P(T ≥ t α) = α.
Illustration of Critical Values
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 45
Example: Visualization of t0.01 = 2.5176.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 46
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 47
Remarks
tα:a t value such that there is of
the area to the right of tα
tα: the negative critical value Because the t distribution is
symmetric, P(T ≤ tα) = P(T ≥ tα) = α.
How to Find a 100(1 α)% CI for µ When σ is Unknown
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 48
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 49
Remarks
1. This CI can be used with any sample size n (≥ 2).This produces an exact CI for µ.
2. This CI for µ is valid only if the underlying population is normal.
A Large-Sample CI for a Population Proportion
Let p = true population proportion of a success.
Use the sample proportion to construct a CI for p.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 50
A Large-Sample CI for a Population Proportion
Sample of n individuals.
X = number of individuals with the characteristic or number of successes.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 51
Sample Proportion
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 52
Standardize the Sample Proportion
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 53
A Large-Sample Confidence Interval for a Population Proportion
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 54
Example: Americans with Hypertension
High blood pressure, or hypertension, occurs when the force of blood against the artery walls is too strong. In a recent survey, 1100 adult Americans were randomly selected and examined for high blood pressure. The number of patients classified with hypertension
is 319. Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 55
Example (cont.)
Find a 95% confidence interval for the true proportion of adult Americans with
hypertension.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 56
1100
)29.01(29.096.129.0
)ˆ1(ˆˆ 2/
n
ppzp
Example (cont.)
= 0.29 ± 0.0268 = (0.2632, 0.3168)
(0.2632, 0.3168) is a 95% confidence interval for the true proportion, p, of adult Americans with hypertension.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 57
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 58
Necessary Sample Size
1. Suppose n is large (unknown), confidence level is 100(1 )%, bound on the error of estimation is B.
Necessary Sample Size (cont.)
2. The bound on the error of estimation is the step in each direction:
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 59
n
ppzB
)ˆ1(ˆ2/
Necessary Sample Size (cont.)
3. Solve for n and the resulting formula is:
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 60
2
2/)ˆ1(ˆ
B
zppn
Necessary Sample Size (cont.)
Problem: sample proportion is unknown. Don't know sample proportion until we have n.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 61
Necessary Sample Size (cont.)
Solutions:1. Use a reasonable estimate for sample
proportion from previous experience.2. If no prior information is available, use
0.5 as the estimate of the sample proportion.
This produces a very conservative, large value of n.Copyright 2011 by W. H.
Freeman and Company. All rights reserved. 62
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 63
A Confidence Interval for a Population Variance
1. Seems reasonable to use S 2 as an estimator for σ 2.
2. A CI for σ 2 is based on a new standardization and a chi-square distribution.
3. Chi-square (2) distribution:a) Positive probability only for non-negative
values.b) Focus on the properties and a method for
finding critical values.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 64
Properties of a Chi-Square Distribution
1. A chi-square distribution is completely determined by one parameter, df, the number of degrees of freedom, a positive integer (df = 1, 2, 3, 4,…). There is a different chi-square distribution corresponding to each value of df.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 65
Properties of a Chi-Square Distribution (cont.)
2. If X has a chi-square distribution with df degrees of freedom, denoted X ~df
2, then µX = df and σX
2= 2df.
The mean of X is df, the number of degrees of freedom, and the variance is 2 twice the number of degrees of freedom.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 66
Properties of a Chi-Square Distribution (cont.)
3. Suppose X ~ df2. The density
curve for X is positively skewed (not symmetric), and as x increases it gets closer and closer to the x axis but never touches it. As df increases, the density curve becomes flatter and actually looks more normal.
Examples of Density Curvers for Chi-Square Distributions
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 67
Critical Values
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 68
Illustration of Critical Values
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 69
Illustration of Critical Values
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 70
Example: Visualization of 2
0.05 = 18.3070
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 71
x
Example: Visualization of 2
0.99 = 1.2390.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 72
x
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 73
Theorem Let S 2 be the sample variance of a
random sample of size n from a normal distribution with variance σ 2. The random variable
has a chi-square distribution with n 1 degrees of freedom.
2
2)1( SnX
CI for a Population Variance
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 74
Example: Kiln-Fired Dishes
Earthenware dishes are made from clay
and are fired, or exposed to heat, in a large kiln. Large fluctuations in the kiln temperature can cause cracks, bumps, or other flaws (and increase cost).
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 75
Example (cont.)
With the kiln set at 800C, a random sample of 19 temperature measurements (in C) was obtained.
The sample variance was s2 = 17.55.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 76
Example (cont.)
a) Find a 95% confidence interval for the true population variance in temperature of the kiln when it is set to 800C. Assume that the underlying distribution is normal.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 77
Example (cont.)
s2 = 17.55, n = 19, df = 19 1 =18
2 /2 = 20.025 = 31.5264
21- /2 = 2
0.975 = 8.2307
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 78
x
x
x
x
Example (cont.):Left Endpoint
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 79
0202.105264.31
)55.17)(18()1(2
2/
2
sn
Example (cont.):Right Endpoint
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 80
3807.382307.8
)55.17)(18()1(2
2/1
2
sn
Example (cont.)
(10.0202, 38.3807) is a 95% confidence interval for the true population variance in temperature when the kiln is set to 800C.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 81
Example (cont.)
b) Quality control engineers have determined that the maximum variance in temperature during firing should be 16C. Using the confidence interval constructed in part a), is there any evidence to suggest that the true temperature variance is greater than 16C? Justify your answer.Copyright 2011 by W. H.
Freeman and Company. All rights reserved. 82
Example (cont.)
Claim: 2 = 16 Experiment: s2 = 17.55 Likelihood: The likelihood is
expressed as a 95% confidence interval, an interval of likely values for 2, (10.0202, 38.3807), from part a).
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 83
Example (cont.)
Conclusion: The required kiln temperature variance, 16C, is included in this confidence interval. There is no evidence to suggest that 2 is different from 16C.
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 84
Example (cont.)
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 85
Copyright 2011 by W. H. Freeman and Company. All
rights reserved. 86
Remarks
1. This CI for σ 2 is valid only if the underlying population is normal.
2. Take the square root of each endpoint to obtain a 100(1 α)% CI for σ.