Chapter 7 Confidence Intervals (置信区间) z-Based Confidence Intervals for a Population Mean: Known t-Based Confidence Intervals for a Population Mean: Unknown Sample Size Determination(样本量计算) Confidence Intervals for a Population Proportion
Chapter 7 Confidence Intervals
Statistical Inferences Estimation (估计) Point estimation (点估计) Confidence interval estimation (置信区间的估计) Hypothesis-testing (假设检验 ) Chapter 7 Confidence Intervals
Chapter 7 Confidence Intervals Example The Dean of the Business School wants to estimate the mean number of hours worked per week by students. A sample of 49 students showed a mean of 24 hours with a standard deviation of 4 hours. What is the population mean? The value of the population mean is not known. Our best estimate of this value is the sample mean of 24.0 hours. This value is called a point estimate. Chapter 7 Confidence Intervals
Chapter 7 Confidence Intervals A point estimate is a single value (statistic) used to estimate a population value (parameter). A confidence interval (CI) is a range of values within which the population parameter is expected to occur at a specified probability (confidence level). The two confidence levels that are used extensively are the 95% and the 99%. An Interval Estimate states the range within which a population parameter probably lies. Chapter 7 Confidence Intervals
z-Based Confidence Intervals for a Population Mean Consider the sampling distribution of the sample mean Recall from Chapter 6 that if a population is normally distributed with mean m and standard deviation s, then the sampling distribution of is normal with mean m = m and standard deviation Even if the population being sampled is non-normal, when the sample size n is large, the sampling distribution of sample means is again approximately normal (by the Central Limit Theorem) Chapter 7 Confidence Intervals
Chapter 7 Confidence Intervals Recall the empirical rule, so… 68.26% of all possible sample means are within one standard deviation of the population mean 95.44% of all possible sample means are within two standard deviations of the population mean 99.73% of all possible sample means are within three standard deviations of the population mean Chapter 7 Confidence Intervals
Chapter 7 Confidence Intervals The Car Mileage Case Example 7.1 Recall that the population of car mileages is normally distributed with mean m. We assume that the standard deviation is known : s = 0.8 mpg Note that m is unknown and is to be estimated Taking samples of size n = 5, the sampling distribution of sample mean mileages is normal with mean m = m (which is also unknown) and standard deviation The probability is 0.9544 that will be within plus or minus 2s = 2 • 0.35777 = 0.7155 of m Chapter 7 Confidence Intervals
Chapter 7 Confidence Intervals The Car Mileage Case #2 Then there is a 0.9544 probability that will be a value so that interval [ ± 0.7155] contains m In other words P( – 0.7155 ≤ m ≤ + 0.7155) = 0.9544 The interval [ ± 0.7155] is referred to as the 95.44% confidence interval for m. We take three samples with means = 31.3, 31.72, and 32.5, respectively. Suppose actually m=31.5. Chapter 7 Confidence Intervals
Chapter 7 Confidence Intervals The Car Mileage Case #3 95.44% Confidence Intervals for m Three intervals shown Two contain m One does not Chapter 7 Confidence Intervals
Chapter 7 Confidence Intervals According to the 95.44% confidence interval, we know even before we sample that of all the possible samples that could be selected … … There is 95.44% probability that the sample mean that is calculated is such that the interval [ ± 0.7155] will contain the actual (but unknown) population mean m In other words, of all possible sample means, 95.44% of all the corresponding intervals will contain the population mean m Note that there is a 4.56% probability that the interval does not contain m The sample mean is either too high or too low Chapter 7 Confidence Intervals
Chapter 7 Confidence Intervals Generalizing In the example, we found the probability that m is contained in an interval of integer multiples of s More usual to specify the (integer) probability and find the corresponding number of s The probability that the confidence interval will not contain the population mean m is denoted by a In the example, a = 0.0456 Chapter 7 Confidence Intervals
Generalizing Continued The probability that the confidence interval will contain the population mean m is denoted by 1 - a 1 – a is referred to as the confidence coefficient (1 – a) 100% is called the confidence level In the example, 1 – a = 0.9544 Usual to use two decimal point probabilities for 1 – a Here, focus on 1 – a = 0.95 or 0.99 Chapter 7 Confidence Intervals
General Confidence Interval In general, the probability is 1 – a that the population mean m is contained in the interval The normal point za/2 gives a right hand tail area under the standard normal curve equal to a/2 The normal point - za/2 gives a left hand tail area under the standard normal curve equal to a/2 The area under the standard normal curve between -za/2 and za/2 is 1 – a Chapter 7 Confidence Intervals
Chapter 7 Confidence Intervals
z-Based Confidence Intervals for a Mean with s Known If a population has standard deviation s (known), and if the population is normal or if sample size is large (n 30), then … … a (1-a)100% confidence interval for m is Chapter 7 Confidence Intervals
Chapter 7 Confidence Intervals 95% Confidence Level For a 95% confidence level, 1 – a = 0.95 a = 0.05 a/2 = 0.025 For 95% confidence, need the normal point z0.025 The area under the standard normal curve between -z0.025 and z0.025 is 0.95 Then the area under the standard normal curve between 0 and z0.025 is 0.475 From the standard normal table, the area is 0.475 for z = 1.96 Then z0.025 = 1.96 Chapter 7 Confidence Intervals
The Effect of a on Confidence Interval Width za/2 = z0.005 = 2.575 za/2 = z0.025 = 1.96 Chapter 7 Confidence Intervals
Chapter 7 Confidence Intervals The 95% confidence interval is Chapter 7 Confidence Intervals
Chapter 7 Confidence Intervals For 99% confidence, need the normal point z0.005 Reading between table entries in the standard normal table, the area is 0.495 for z0.005 = 2.575 The 99% confidence interval is Chapter 7 Confidence Intervals
Chapter 7 Confidence Intervals The Car Mileage Case Example 7.2 Given: = 31.5531 mpg s = 0.8 mpg n = 49 95% Confidence Interval: 99% Confidence Interval: Chapter 7 Confidence Intervals
Chapter 7 Confidence Intervals The 99% confidence interval is slightly wider than the 95% confidence interval The higher the confidence level, the wider the interval Reasoning from the intervals: The target mean mileage should be at least 31 mpg Both confidence intervals exceed this target According to the 95% confidence interval, we can be 95% confident that the mileage is between 31.33 and 31.78 mpg So we can be 95% confident that, on average, the mean mileage exceeds the target by at least 0.33 mpg and at most 0.78 mpg Chapter 7 Confidence Intervals
Section 7.2 t-Based Confidence Intervals for a Population Mean If s is unknown (which is usually the case), we can construct a confidence interval for m based on the sampling distribution of If the population is normal, then for any sample size n, this sampling distribution is called the t distribution (t分布) Chapter 7 Confidence Intervals
The t Distribution(t 分布) The curve of the t distribution is similar to that of the standard normal curve Symmetrical and bell-shaped The t distribution is more spread out than the standard normal distribution The spread of the t is given by the number of degrees of freedom(自由度) Denoted by df For a sample of size n, there are one fewer degrees of freedom, that is, df = n – 1 Chapter 7 Confidence Intervals
Degrees of Freedom and the t-Distribution As the number of degrees of freedom increases, the spread of the t distribution decreases and the t curve approaches the standard normal curve Chapter 7 Confidence Intervals
The t Distribution and Degrees of Freedom For a t distribution with n – 1 degrees of freedom, As the sample size n increases, the degrees of freedom also increases As the degrees of freedom increase, the spread of the t curve decreases As the degrees of freedom increases indefinitely, the t curve approaches the standard normal curve If n ≥ 30, so df = n – 1 ≥ 29, the t curve is very similar to the standard normal curve Chapter 7 Confidence Intervals
t and Right Hand Tail Areas Use a t point denoted by ta ta is the point on the horizontal axis under the t curve that gives a right hand tail equal to a So the value of ta in a particular situation depends on the right hand tail area a and the number of degrees of freedom df = n – 1 a = 1 – a , where 1 – a is the specified confidence coefficient Chapter 7 Confidence Intervals
Chapter 7 Confidence Intervals
Using the t Distribution Table Rows correspond to the different values of df Columns correspond to different values of a See Table 7.3, Tables A.4 and A.20 in Appendix A and the table on the inside cover Table 7.3 and A.4 gives t points for df 1 to 30, then for df = 40, 60, 120, and ∞ On the row for ∞, the t points are the z points Table A.20 gives t points for df from 1 to 100 For df greater than 100, t points can be approximated by the corresponding z points on the bottom row for df = ∞ Always look at the accompanying figure for guidance on how to use the table Chapter 7 Confidence Intervals
Chapter 7 Confidence Intervals Example 7.3 Find ta for a sample of size n = 15 and right hand tail area of 0.025 For n = 15, df = 14 a = 0.025 Note that a = 0.025 corresponds to a confidence level of 0.95 In Table 7.3, along row labeled 14 and under column labeled 0.025, read a table entry of 2.145 So ta = 2.145 Chapter 7 Confidence Intervals
t-Based Confidence Intervals for a Mean: s Unknown If the sampled population is normally distributed with mean , then a (1-a)100% confidence interval for m is ta/2 is the t point giving a right-hand tail area of /2 under the t curve having n – 1 degrees of freedom Chapter 7 Confidence Intervals
Chapter 7 Confidence Intervals Debt-to-Equity Ratio Example 7.4 Estimate the mean debt-to-equity ratio of the loan portfolio of a bank Select a random sample of 15 commercial loan accounts Box plot is given in figure below Know: = 1.34 s = 0.192 n = 15 Want a 95% confidence interval for the ratio Assume all ratios are normally distributed but s unknown Chapter 7 Confidence Intervals
Chapter 7 Confidence Intervals Have to use the t distribution At 95% confidence, 1 – a = 0.95 so a = 0.05 and a/2 = 0.025 For n = 15, df = 15 – 1 = 14 Use the t table to find ta/2 for df = 14 ta/2 = t0.025 = 2.145 for df = 14 The 95% confidence interval: Chapter 7 Confidence Intervals
Section 7.3 Sample Size Determination If s is known, then a sample of size Letting E denote the desired margin of error, so that is within E units of , with 100(1-)% confidence. Chapter 7 Confidence Intervals
Chapter 7 Confidence Intervals If s is unknown and is estimated from s, then a sample of size so that is within E units of , with 100(1-)% confidence. The number of degrees of freedom for the ta/2 point is the size of the preliminary sample minus 1 Chapter 7 Confidence Intervals
Chapter 7 Confidence Intervals Car Mileage Case Example 7.5 We wish to find the sample size that is needed to make the margin of error in a 95% confidence interval for mean equal to 0.3. We regard the previously discussed sample of five mileages as a preliminary sample, and calculated the s=0.7583 from 5 sample cars. We find that the appropriate sample size is: Rounding up, we employ a sample of size 50. Chapter 7 Confidence Intervals
Chapter 7 Confidence Intervals Car Mileage Case Example 7.5 Given: = 31.5531 mpg s = 0.7992 mpg n = 49 t- based 95% Confidence Interval: where ta/2 = t0.025 = 2.0106 for df = 49 – 1 = 48 degrees of freedom Note: the error bound B = 0.2296 mpg, within the maximum error of 0.3 mpg Chapter 7 Confidence Intervals
Section 7.4 Confidence Intervals for a Population Proportion If the sample size n is large*, then a (1-a)100% confidence interval for p is * Here n should be considered large if both Chapter 7 Confidence Intervals
Chapter 7 Confidence Intervals Phe-Mycin Side Effects Example 7.6 Given: n = 200, 35 patients experience nausea. Note: so both quantities are > 5 For 95% confidence, za/2 = z0.025 = 1.96 and Chapter 7 Confidence Intervals
Determining Sample Size for Confidence Interval for p A sample size will yield an estimate , precisely within E units of p, with 100(1-)% confidence Note that the formula requires a preliminary estimate of p. The conservative value of p = 0.5 is generally used when there is no prior information on p Chapter 7 Confidence Intervals
A Comparison of Confidence Intervals and Tolerance Intervals A tolerance interval contains a specified percentage of individual population measurements Often 68.26%, 95.44%, 99.73% A confidence interval is an interval that contains the population mean m, and the confidence level expresses how sure we are that this interval contains m Often confidence level is set high (e.g., 95% or 99%) Because such a level is considered high enough to provide convincing evidence about the value of m Chapter 7 Confidence Intervals
Chapter 7 Confidence Intervals Car Mileage Case Example 7.7 Tolerance intervals shown: [ ± s] contains 68% of all individual cars [ ± 2s] contains 95.44% of all individual cars [ ± 3s] contains 99.73% of all individual cars The t-based 95% confidence interval for m is [31.32, 31.78], so we can be 95% confident that m lies between 31.23 and 31.78 mpg Chapter 7 Confidence Intervals
Chapter 7 Confidence Intervals Summary: Selecting an Appropriate Confidence Interval for a Population Mean Chapter 7 Confidence Intervals