Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

44
Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12

Transcript of Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Page 1: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning

Estimating Means

with Confidence

Chapter 12

Page 2: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 2

11.1 Introduction to CI for Means• A parameter is a population characteristic – value

is usually unknown. We estimate the parameter using sample information.

• A statistic, or estimate, is a characteristic of a sample. A statistic estimates a parameter.

• A confidence interval is an interval of values computed from sample data that is likely to include the true population value.

• The confidence level for an interval describes our confidence in the procedure we used. We are confident that most of the confidence intervals we compute using a procedure will contain the true population value.

Page 3: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 3

More Estimation Situations

Situation 1. Estimating the mean of a quantitative variable.

Example research questions:

What is the mean time that college students watch TV per day? What is the mean pulse rate of women?

Population parameter: (spelled “mu” and pronounced “mew”) = population mean for the variable

Sample estimate: = the sample mean for the variablex

Page 4: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 4

More Estimation Situations

Situation 2. Estimating the population mean of paired differences for a quantitative variable.

Example research questions:

What is the mean difference in weights for freshmen at the beginning and end of the first semester? What is the mean difference in age between husbands and wives in Britain?

Population parameter: d = population mean of the differences in the two measurements

Sample estimate: = the mean of the differences for a sample of the two measurements

d

Page 5: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 5

Situation 3. Estimating the difference between two populations with regard to the mean of a quantitative variable.

Example research questions:How much difference is there in average weight loss for those who diet compared to those who exercise to lose weight? How much difference is there between the mean foot lengths of men and women?

Population parameter: 1 – 2 = difference between the two population means.

Sample estimate: = difference between the two sample means.

More Estimation Situations

21 xx

Page 6: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 6

Paired Data

Paired data (or paired samples): when pairs of variables are collected. Only interested in population (and sample) of differences, and not in the original data.

• Each person measured twice. Two measurements of same characteristic or trait are made under different conditions.

• Similar individuals are paired prior to an experiment. Each member of a pair receives a different treatment. Same response variable is measured for all individuals.

• Two different variables are measured for each individual. Interested in amount of difference between two variables.

Page 7: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 7

Independent SamplesTwo samples are called independent samples when the measurements in one sample are not related to

the measurements in the other sample.

• Random samples taken separately from two populations and same response variable is recorded.

• One random sample taken and a variable recorded, but units are categorized to form two populations.

• Participants randomly assigned to one of two treatment conditions, and same response variable is recorded.

• Two random samples taken from a population and a separate variable is measured in each sample..

Page 8: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 8

Standard Errors

Rough Definition: The standard error of a sample statistic measures, roughly, the average difference between the statistic and the population parameter. This “average difference” is over all possible random samples of a given size that can be taken from the population.

Technical Definition: The standard error of a sample statistic is the estimated standard deviation of the sampling distribution for the statistic.

Page 9: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 9

Poll: Class of 175 students. In a typical day, about how much time to you spend watching television?

Standard Errors of a Sample Means

Example 11.2 Mean Hours Watching TV

diffs paired of dev std sample ,).(.

deviation standard sample ,).(.

dd sn

sdes

sn

sxes

Variable N Mean Median TrMean StDev SE Mean

TV 175 2.09 2.000 1.950 1.644 0.124 124.

175

644.1..

n

sxes

Page 10: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 10

Study: n1 = 42 men on diet, n2 = 27 men on exercise routine

Standard Error of the Difference Between Two Sample Means

Example 11.3 Lose More Weight by Diet or Exercise?

2

22

1

21

21 ).(.n

s

n

sxxes

Diet: Lost an average of 7.2 kg with std dev of 3.7 kgExercise: Lost an average of 4.0 kg with std dev of 3.9 kg

So, kg 2.30.42.721 xx

81.0

47

9.3

42

7.3).(. and

22

21 xxes

Page 11: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 11

Using Student’s t-Distribution to Determine the Multiplier

t* multiplier: value in a t-distribution with df = n – 1 such that the area between

-t* and +t* equals the desired confidence level.

t-distribution: bell shape, centered at 0, more spread out than standard normal curve from using s, instead of .

Page 12: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 12

Lesson 1: Finding a CI for a Mean for Any Sample Size and Any Confidence Level

Sample estimate Multiplier Standard error

Sample estimate: = sample mean

Standard error:

t-interval: where df = n – 1 for the multiplier t*.

11.2 CI Module 3: Confidence Intervals for One Population Mean

n

sxes ..

x

n

stx *

Page 13: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 13

Conditions Required

Situation 1: The population of the measurements is |bell-shaped, and a random sample of any size is measured. In practice, for small samples, the data should show no extreme skewness and should not contain any outliers.

Situation 2: The population of measurements is not bell-shaped, but a large random sample is measured. A somewhat arbitrary definition of a “large” sampleis n ≥ 30, but if there are extreme outliers, it is better to have an even larger sample size than n = 30.

Two Situations t-interval is Valid:

Page 14: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 14

Example 11.5 Mean Forearm Length

Data: Forearm lengths (cm) for a random sample of n = 9 men

25.5, 24.0, 26.5, 25.5, 28.0, 27.0, 23.0, 25.0, 25.0

Note: Dotplot shows no obvious skewness and no outliers.

95% Confidence Interval: 25.5 2.31(.507) 25.5 1.17 24.33 to 26.67 cm

507.9

52.1.. and ,52.1 ,5.25

n

sxessx

Multiplier t* from Table A.2 with df = 8 is t* = 2.31

Page 15: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 15

Calculating a Confidence Interval for a Population Mean

t-interval:

1.Make sure appropriate conditions apply checking sample size and/or a shape picture. For small samples (n < 30) with extreme skewness or outliers, you cannot proceed.2.Choose a confidence level.3.Compute the sample mean and standard deviation.4.Calculate the standard error of the mean.5.Calculate df = n – 1 6.Use Table A.2 (or software) to find the multiplier t*.

n

stxxestx ** ..

Page 16: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 16

Example 11.6 Watching TVPoll: Class of 175 students. In a typical day, about

how much time to you spend watching television?

The sample mean was 2.09 hours and the sample standard deviation was 1.644 hours. 124.

175

644.1..

n

sxes

Page 17: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 17

Example 11.6 Watching TV

Note: the 99% CI estimate is wider than the 95% one.

A 95% Confidence Interval: 2.09 1.98(.124) 2.09 .25 1.84 to 2.34 hours

A 99% Confidence Interval: 2.09 2.63(.124) 2.09 .33 1.76 to 2.42 hours

Page 18: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 18

Example 11.6 Watching TV

Correct Interpretation of a CI for a Mean

We don’t know whether or not the mean TV viewing hours for Penn State students is really between 1.84 to 2.34 hours.

•It is if we got one of the 95% of possible samples for which the sample mean is close enough to the true population mean for our procedure to work.

•It isn’t if we happened to get one of the 5% of possible samples for which the sample mean is too far away from the population mean for the procedure to work.

Page 19: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 19

Example 11.6 Watching TV

A Common Misinterpretation of a CI for a Mean

•We can be fairly certain that the population mean forearm length is covered by this interval. •This does not give us any information about the range of individual forearm lengths. •Do not fall into the trap of thinking that 95% of men’s forearm lengths are in this interval.

Page 20: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 20

Example 11.7 What Students Sleep More? Q: How many hours of sleep did you get last night,

to the nearest half hour?

Note: Bell-shape was reasonable for Stat 10 (with smaller n).

Notes: Interval for Stat 10 is wider (smaller sample size)Two intervals do not overlap Stat 10 average significantly higher than Stat 13 average.

Class N Mean StDev SE MeanStat 10 (stat literacy) 25 7.66 1.34 0.27Stat 13 (stat methods) 148 6.81 1.73 0.14

Page 21: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 21

Lesson 2: Special Case: Approximate 95% Confidence Intervals for Large Samples

For sufficiently large samples, the interval

Sample estimate 2 Standard error

is an approximate 95% confidence interval for a population parameter.

Note: The 95% confidence level describes how often the procedure provides an interval that includes the population value. For about 95% of all random samples of a specific size from a population, the confidence interval captures the population parameter.

Page 22: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 22

Example 11.8 Watching TV

Article: with 95% confidence, the mean is between 1.8 and 2.3 hours.

Technically: We are 95% confident the interval from 1.842 to 2.338 hours is correct in that it captures the mean television viewing hours for Penn State students.

t-Interval: 2.09 1.98(.124) 2.09 .25 1.84 to 2.34 hours

Approximate 95% Confidence Interval: 2.09 2(.124) 2.09 .248 1.842 to 2.338 hours

Page 23: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 23

Data: two variables for each of the n individuals or pairs, use the difference d = x1 – x2

Population parameter: d = mean of the differences for the population

Sample estimate: = sample mean of the differences

Standard error:

CI for d: where df = n – 1 for the multiplier

t*

11.3 CI Module 4: CI for Population Mean of Paired Differences

n

sdes d..

d

destd ..*

Page 24: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 24

Data: two variables for n individuals or pairs; use the difference d = x1 – x2.

Population parameter: d = mean of differences for the population = 1 – 2.

Sample estimate: = sample mean of the differences

Standard deviation and standard error: sd = std dev of sample of differences;

Confidence interval for d: where df = n – 1 for the multiplier t*.

11.3 CI Module 4: CI for Population Mean of Paired Differences

destd ..*

n

sdes d..

d

Page 25: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 25

Conditions Required

Situation 1: The population of differences is |bell-shaped, and a random sample of any size is measured. In practice, for small samples, the differences in the sample should show no extreme skewness and should not contain any outliers.

Situation 2: The population of differences is not bell-shaped, but a large random sample is measured. A somewhat arbitrary definition of a “large” sample is n ≥ 30 pairs, but if there are extreme outliers in the sample of differences, it is better to have an even larger sample size than n = 30.

Two Situations t-interval is Valid:

Page 26: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 26

Example 11.9 Screen Time: Computer vs TV

Data: Hours spent watching TV and hours spent on computer per week for n = 25 students.

Note: Boxplot shows no obvious skewness and no outliers.

Task: Make a 90% CI for the mean difference in hours spent using computer versus watching TV.

Page 27: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 27

Example 11.9 Screen Time: Computer vs TV

90% Confidence Interval: 5.36 1.71(3.05) 5.36 5.22 0.14 to 10.58 hours

05.325

24.15.. and ,24.15 ,36.5

n

sdessd d

d

Multiplier t* from Table A.2 with df = 24 is t* = 1.71

Results:

Interpretation: We are 90% confident that the average difference between computer usage and television viewing for students represented by this sample is covered by the interval from 0.14 to 10.58 hours per week, with more hours spent on computer usage than on television viewing.

Page 28: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 28

Calculating a Confidence Interval for a Population Mean of Paired Differences

1.Make sure appropriate conditions apply checking sample size and/or a shape picture of the differences.2.Choose a confidence level.3.Compute the differences for the n pairs in the sample, then find the mean and std dev for the differences.4.Calculate the standard error of the mean difference.5.Calculate df = n – 1 6.Use Table A.2 (or software) to find the multiplier t*.

n

stddestd d ** ..

Page 29: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Lesson 1: The General (Unpooled) Case

Copyright ©2011 Brooks/Cole, Cengage Learning 29

11.4 CI Module 5: CI for Difference in Two Population Means (Independent Samples)

Page 30: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 30

CI for Difference for the Difference between Two Population Means (Indep)

Approximate CI for 1 – 2:

where t* is the value in a t-distribution with area between -t* and t* equal to the desired confidence level. Approximate df difficult to specify. Use computer software or conservatively use the smaller of the two sample sizes and subtract 1.

Note: for an approximate 95% CI, use a multiplier of 2.

2

22

1

21*

21 n

s

n

stxx

Page 31: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 31

Degrees of Freedom

The t-distribution is only approximately correct and df formula is complicated (Welch’s approx):

Statistical software can use the above approximation, but if done by-hand then use a conservative df = smaller of n1 – 1 and n2 – 1.

Page 32: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 32

Necessary Conditions

Two samples must be independent and either:

Situation 1: Populations of measurements both bell-shaped, and random samples of any size are measured.

Situation 2: Large (n 30) random samples are measured. But if there are extreme outliers, or extreme skewness, it is better to have an even larger sample than n = 30.

Page 33: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 33

Example 11.11 Effect of a Stare on Driving

Randomized experiment: Researchers either stared or did not stare at drivers stopped at a campus stop sign; Timed how long (sec) it took driver to proceed from sign to a mark on other side of the intersection.

Task: Make a 95% CI for the difference between the mean crossing times for the two populations represented by these two independent samples.

No Stare Group (n = 14): 8.3, 5.5, 6.0, 8.1, 8.8, 7.5, 7.8, 7.1, 5.7, 6.5, 4.7, 6.9, 5.2, 4.7

Stare Group (n = 13): 5.6, 5.0, 5.7, 6.3, 6.5, 5.8, 4.5, 6.1, 4.8, 4.9, 4.5, 7.2, 5.8

Page 34: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 34

Example 11.11 Effect of a Stare on Driving

Checking Conditions:

Boxplots show …

• No outliers and no strong skewness.

• Crossing times in stare group generally faster and less variable.

Page 35: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 35

Example 11.11 Effect of a Stare on Driving

The 95% confidence interval for the difference between the population means is 0.14 seconds to 1.93 seconds .

Note: The df = 21 was reported by the computer package based on the Welch’s approximation formula.

Page 36: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 36

Lesson 2: Equal Variance Assumption and the Pooled Standard ErrorMay be reasonable to assume the two populations have equal population standard deviations, or equivalently, equal population variances:

Estimate of this variance based on the combined or “pooled” data is called the pooled variance. The square root of the pooled variance is called the pooled standard deviation:

222

21

2

11 deviation standard Pooled

21

222

211

nn

snsnsp

Page 37: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 37

Pooled Standard Error

21

21

2

2

2

1

2

21

11

11

).(. Pooled

nns

nns

n

s

n

sxxes

p

p

pp

Note: Pooled df = (n1 – 1) + (n2 – 1) = (n1 + n2 – 2).

Page 38: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 38

Pooled Confidence Interval

Pooled CI for the Difference Between Two Means (Independent Samples):

where t* is found using a t-distribution with df = (n1 + n2 – 2) and sp is the pooled standard deviation.

21

*21

11

nnstxx p

Page 39: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 39

Example 11.14 Male and Female Sleep Times

Data: The 83 female and 65 male responses from students in an intro stat class.

Note: We will assume equal population variances.

Task: Make a 95% CI for the difference between the two population means sleep hours for females versus males.

Q: How much difference is there between how long female and male students slept the previous night?

Page 40: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 40

Example 11.14 Male and Female Sleep Times

Notes:• Two sample standard deviations are very similar.• Sample mean for females higher than for males.• 95% confidence interval contains 0 so cannot rule out

that the population means may be equal.

Two-sample T for sleep [with “Assume Equal Variance” option]

Sex N Mean StDev SE MeanFemale 83 7.02 1.75 0.19Male 65 6.55 1.68 0.21

Difference = mu (Female) – mu (Male)Estimate for difference: 0.46195% CI for difference: (-0.103, 1.025)T-Test of difference = 0 (vs not =): T-Value = 1.62 P = 0.108 DF = 146Both use Pooled StDev = 1.72

Page 41: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 41

Example 11.14 Male and Female Sleep Times

Pooled standard deviation and pooled standard error “by-hand”:

72.1957.2

26583

68.116575.1183

2

11 dev std Pooled

22

21

222

211

nn

snsnsp

285.065

1

83

172.1

11).(. Pooled

2121

nn

sxxes p

Page 42: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 42

Pooled or Unpooled?

• If the larger sample size produced the larger standard deviation, the pooled procedure is acceptable because it will be conservative.

• If the smaller standard deviation accompanies the larger sample size, the pooled test can be quite misleading and not recommended.

• If sample sizes are equal, the pooled and unpooled standard errors are equal. Unless the sample standard deviations are quite similar, it is best to use the unpooled procedure.

Page 43: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 43

Example 11.15 Male and Female Sleep Times

Note: Unpooled s.e. is 0.30 while pooled s.e. is 0.36 (larger).

Page 44: Copyright ©2011 Brooks/Cole, Cengage Learning Estimating Means with Confidence Chapter 12.

Copyright ©2011 Brooks/Cole, Cengage Learning 44

Confidence Interval for the Difference in Two Population Means

1.Make sure appropriate conditions apply checking sample size and/or a shape picture of the differences.2.Choose a confidence level.3.Compute the mean and std dev for each sample.4.Determine whether the std devs are similar enough to pooled procedure can be used.5.Calculate the appropriate standard error (pooled or unpooled).6.Calculate the appropriate df.7.Use Table A.2 (or software) to find the multiplier t*.

21*

21 .. xxestxx