71
Confidence intervals for Proportions Chapter 19

Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Embed Size (px)

Citation preview

Page 1: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Confidence intervals for Proportions

Chapter 19

Page 2: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Objectives:

1. Standard Error

2. Confidence Interval

3. One-proportion z-interval

4. Margin of Error

5. Critical Value

Page 3: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Introduction

• Statistical Inference

– Involves methods of using information from a sample to draw conclusions regarding the population.

– In formal statistical inference, we use probability to express the strength of our conclusions.

Page 4: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Example of Statistical Inference• In the Vietnam War years, a lottery determined the order in which men

were drafted for army service. The lottery assigned draft numbers by choosing birth dates in random order. We expect a correlation near zero between birth dates and draft numbers if the draft numbers come from random choice. The actual correlation between birth date and draft number in the first draft lottery was r = -0.226. That is, men born later in the year tended to get lower draft numbers. Is this small correlation evidence that the lottery was biased?

• Our unaided judgment can’t tell because any two variables will have some association in practice, just by chance. So we calculate that a correlation this far from zero has probability less than 0.001 in a truly random lottery.

• Because a correlation as strong as that observed would almost never occur in a random lottery, there is strong evidence that the lottery was unfair.

Page 5: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Two Most Common Types of Formal Statistical Inference

1. Confidence Intervals– Estimate the value of a population

parameter.

2. Tests of Significance– Assess the evidence for a claim about a

population.

Page 6: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Conference Intervals and Tests of Significance

• Both types of inference are based on the sampling distributions of a sample statistic.

• That is, both report probabilities that state what would happen if we used the inference method many times.

Page 7: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

CONFIDENCE INTERVAL

Page 8: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

We choose 50 people in an undergrad class, and find that 10 of them are

Hispanic: = (10)/(50) = 0.2 (proportion of Hispanics in sample)

You treat a group of 120 Herpes patients given a new drug; 30 get better:

= (30)/(120) = 0.25 (proportion of patients improving in sample)

The sample proportion We now study categorical data and draw inference on the proportion,

or percentage, of the population with a specific characteristic.

If we call a given categorical characteristic in the population “success,”

then the sample proportion of successes, ,is:

sample in the nsobservatio ofcount

sample in the successes ofcount ˆ p

Page 9: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Sampling distribution of The sampling distribution of is never exactly normal. But as the

sample size increases, the sampling distribution of becomes

approximately normal.

Page 10: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Concept of Confidence Intervals• As we discussed in sampling distributions, the existence

of sampling variation affects the accuracy of a sample statistic as an estimator of a population parameter.

• The unbiased estimators calculated using a sampling distribution can be described as point estimators – specific numbers that are estimates of the parameter.

• In this section, we will develop the idea of a different type of estimate, an interval estimate, which incorporates the sampling variability of the point estimators.

Page 11: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Standard Error

• Both of the sampling distributions we’ve looked at are Normal.– For proportions

– For means

ˆpq

SD pn

SD yn

Page 12: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Standard Error

• When we don’t know p or σ, (which we normally don’t, because they are population parameters) we’re stuck, right?

• Nope. We will use sample statistics to estimate these population parameters.

• Whenever we estimate the standard deviation of a sampling distribution, we call it a standard error.

Page 13: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Standard Error

• For a sample proportion, the standard error is

• For the sample mean, the standard error is

ˆ ˆˆ

pqSE p

n

sSE y

n

Page 14: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

A Confidence Interval

• Recall that the sampling distribution model of

is centered at p, with standard deviation .

• Since we don’t know p, we can’t find the true standard deviation of the sampling distribution model, so we need to find the standard error:

p̂pq

n

SE( p̂) p̂q̂

n

Page 15: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

A Confidence Interval• By the 68-95-99.7% Rule, we know

– about 68% of all samples will have ’s within 1 SE of p

– about 95% of all samples will have ’s within 2 SEs of p

– about 99.7% of all samples will have ’s within 3 SEs of p

• We can look at this from ’s point of view…

Page 16: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

A Confidence Interval

• Consider the 95% level: – There’s a 95% chance that p is no more than 2 SEs

away from . – So, if we reach out 2 SEs, we are 95% sure that p will

be in that interval. In other words, if we reach out 2 SEs in either direction of , we can be 95% confident that this interval contains the true proportion.

• This is called a 95% confidence interval.

Page 17: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

A Confidence Interval

Page 18: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Confidence Interval

• Definition– Confidence Interval is a range of values used

to estimate the true value of a population parameter.

Page 19: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

What Does “95% Confidence” Really Mean?

• Each confidence interval uses a sample statistic to estimate a population parameter.

• But, since samples vary, the statistics we use, and thus the confidence intervals we construct, vary as well.

Page 20: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

What Does “95% Confidence” Really Mean?

• The figure to the right shows that some of our confidence intervals (from 20 random samples) capture the true proportion (the green horizontal line), while others do not:

Page 21: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

What Does “95% Confidence” Really Mean?

• Our confidence is in the process of constructing the interval, not in any one interval itself.

• Thus, we expect 95% of all 95% confidence intervals to contain the true parameter that they are estimating.

Page 22: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

What Does “95% Confidence” Really Mean?

• Returning to our pervious example.

• 20 samples from the same population gave these 95% confidence intervals. In the long run, 95% of all samples give an interval that contains the population proportion p.

Page 23: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

A Level C Confidence Interval has Two Parts:

1. An interval calculated from the data, usually of the form

estimate ± margin of error– Example: estimate –

margin of error – how accurate we believe our estimate is, based on

the variability of the estimate. For a 95% confidence interval the margin of error

would be .ˆ2 ( )SE p

Page 24: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

2. A Confidence Level C, which gives the probability that the interval will capture the true parameter value in repeated samples.– Example: 95% confidence interval – normally

use confidence level of 90% or higher (want to be sure of our conclusions).

Page 25: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Margin of Error: Certainty vs. Precision

• We can claim, with 95% confidence, that the interval contains the true population proportion. – The extent of the interval on either side of is called the margin

of error (ME).• In general, confidence intervals have the form estimate ±

ME.• The more confident we want to be, the larger our ME

needs to be, making the interval wider.

p̂2SE( p̂)

Page 26: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Margin of Error: Certainty vs. Precision

Page 27: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Margin of Error: Certainty vs. Precision

• To be more confident, we wind up being less precise. – We need more values in our confidence interval to be more

certain.• Because of this, every confidence interval is a balance

between certainty and precision.• The tension between certainty and precision is always

there.– Fortunately, in most cases we can be both sufficiently certain and

sufficiently precise to make useful statements.

Page 28: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Margin of Error: Certainty vs. Precision

• The choice of confidence level is somewhat arbitrary, but keep in mind this tension between certainty and precision when selecting your confidence level.

• The most commonly chosen confidence levels are 90%, 95%, and 99% (but any percentage can be used).

Page 29: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Critical Values

• The ‘2’ in (our 95% confidence interval) came from the 68-95-99.7% Rule.

• Using a table or technology, we find that a more exact value for our 95% confidence interval is 1.96 instead of 2. – We call 1.96 the critical value and denote it z*.

• For any confidence level, we can find the corresponding critical value (the number of SEs that corresponds to our confidence interval level).

2 ( )ˆ ˆp SE p

Page 30: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Example:

Lower CriticalValue

Upper CriticalValue

ConfidenceLevel

Page 31: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Critical Values

• Example: For a 90% confidence interval, the critical value is 1.645:

Page 32: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

z*• The critical value z* is the number (z-score)

on the borderline separating sample statistics that are likely to occur from those that are unlikely to occur, for a given confidence level.

Page 33: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

z* is the same for any normal distribution for a given confidence level

Page 34: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Problem:

• Find the critical value z* for a confidence level of 88%?

• invNorm(.94)=1.555

Page 35: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Your Turn:

• Find the critical value z* for a confidence level of 73%?

• invNorm(.73)=.6128

Page 36: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Assumptions and Conditions• All statistical models are made upon assumptions.

– Different models make different assumptions. – If those assumptions are not true, the model might be

inappropriate and our conclusions based on it may be wrong.

• You can never be sure that an assumption is true, but you can often decide whether an assumption is plausible by checking a related condition.

Page 37: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Assumptions and Conditions• Here are the assumptions and the

corresponding conditions you must check before creating a confidence interval for a proportion:

• Independence Assumption: We first need to Think about whether the Independence Assumption is plausible. It’s not one you can check by looking at the data. Instead, we check two conditions to decide whether independence is reasonable.

Page 38: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Assumptions and Conditions– Randomization Condition: Were the data sampled at

random or generated from a properly randomized experiment? Proper randomization can help ensure independence.

– 10% Condition: Is the sample size no more than 10% of the population?

Sample Size Assumption: The sample needs to be large enough for us to be able to use the CLT.– Success/Failure Condition: We must expect at least

10 “successes” and at least 10 “failures.”

Page 39: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

One-Proportion z-Interval• When the conditions are met, we are ready to find the

confidence interval for the population proportion, p.• The confidence interval is

where

• The critical value, z*, depends on the particular confidence level, C, that you specify.

p̂z SE p̂

SE( p̂) p̂q̂

n

Page 40: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

One-Sample Confidence Interval for p Summary

C

Z*−Z*

me me

Confidence intervals contain the population proportion p in C% of

samples. For an SRS of size n drawn from a large population and with

sample proportion calculated from the data, an approximate level C

confidence interval for p is:

C is the area under the standard

normal curve between −z* and z*.

ˆ , is the margin of error

ˆ ˆ* * (1 )

p me me

me z SE z p p n

Using as an unbiased estimate of p.p̂

Page 41: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Procedure:Confidence Interval for a Population Proportion

1. Identify the population of interest and the parameter you want to draw conclusions about (population proportion p).

2. Choose the appropriate inference procedure. Verify the conditions for using the selected procedure.– Conditions population proportion;

• Random condition• 10% condition• Success/Failure condition

Page 42: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

3. If the conditions are met, carry out the inference procedure.– Confidence interval (CI)

• CI = estimate ± margin of error

– In general• CI = estimate ± z* • SE

– For population proportion p• Estimate = • • z*: calculated based on the confidence level•

p̂ˆ ˆ

ˆ( )pq

SE pn

*ˆ ˆCI for : ( )p p z SE p

Page 43: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

*ˆ ˆ( )p z SE p

4. Interpret your results in the context of the problem.

• Summary – Confidence interval for population proportion p

Unbiased estimate of population proportion p

Upper critical value for confidence level

Standard deviation of the sampling distribution of sample proportions

Page 44: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Example - Medication side effects

Arthritis is a painful, chronic inflammation of the joints.

An experiment on the side effects of pain relievers examined

arthritis patients to find the proportion of patients who suffer

side effects. It was found that 23 out of 440 arthritis patients

suffered side effects. What are some side effects of ibuprofen?Serious side effects (seek medical attention immediately):

Allergic reaction (difficulty breathing, swelling, or hives),Muscle cramps, numbness, or tingling,Ulcers (open sores) in the mouth,Rapid weight gain (fluid retention),Seizures,Black, bloody, or tarry stools,Blood in your urine or vomit,Decreased hearing or ringing in the ears,Jaundice (yellowing of the skin or eyes), orAbdominal cramping, indigestion, or heartburn,

Less serious side effects (discuss with your doctor):Dizziness or headache,Nausea, gaseousness, diarrhea, or constipation,Depression,Fatigue or weakness,Dry mouth, orIrregular menstrual periods

Page 45: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Solution

• Check Conditions– Randomization Condition; assume the 440 arthritis

patients were randomly selected.– 10% Condition; it is reasonable to assume there are

more than 4,400 total arthritis patients.– Success/Failure Condition: n = (440)(23/440) = 23 and

n = (440)(317/440) = 317, both are greater than 10.

• All required conditions are met.

p̂q̂

Page 46: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

What is the sampling distribution for the proportion of arthritis patients with

adverse symptoms for samples of 440? Upper tail probability P0.25 0.2 0.15 0.1 0.05 0.03 0.02 0.01

z* 0.67 0.841 1.036 1.282 1.645 1.960 2.054 2.32650% 60% 70% 80% 90% 95% 96% 98%

Confidence level C

Let’s calculate a 90% confidence interval for the population proportion of arthritis patients who suffer some “adverse symptoms.”

What is the sample proportion ?

ˆ ˆ ˆ ( , (1 ) ) N p p p n

ˆ ˆ* (1 )

1.645 0.052(1 0.052) / 440

1.645 0.014 0.023

me z p p n

me

me

052.0440

23ˆ p

For a 90% confidence level, z* = 1.645.

Using the one sample method, we

calculate a margin of error me:

With 90% confidence level, between 2.9% and 7.5% of

arthritis patients taking this pain medication experience

some adverse symptoms.

ˆ90%CIfor :

or 0.052 0.023

p p me

Page 47: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Your Turn:

• In a random sample of 50 Philadelphia families with children of preschool age, 35 had children enrolled in preschool. Find a 95% confidence interval for the true proportion of Philadelphia families with children enrolled in preschool.

Page 48: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Solution

• Check Conditions– Random condition: given, sample was random.– 10% condition: it is reasonable that the number

preschool age children in Philadelphia is greater than 500.

– Success/Failure condition:

so the sample is large enough.

35ˆ .7

50p

ˆ ˆ50(.7) 35 10 & 50(.3) 15 10np nq

Page 49: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Solution • 95% CI (one-proportion z-interval)

• Conclusion: We are 95% confident that between 57.3% and 82.7% of preschool age children in Philadelphia are currently enrolled in preschool.

*ˆ ˆ95% CI for : ( )p p z SE p35

ˆ .750

p * 1.96z .7 .3ˆ ˆˆ( ) .0648

50

pqSE p

n

The 95% CI is: .7 .127 or .573,.827

*ˆ ˆ( ) .7 1.96 .0648 .7 .127p z SE p

Page 50: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Confidence Intervals on the TI-83/84

• Press STAT key, choose TESTS, and then choose A: 1-PropZInterval…

• Adjust the settings;– x: the number selected (not )– n: the sample size– C-level: confidence level

• Then choose “Calculate”

Page 51: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Solve the Previous Problem Using the TI-84

• In a random sample of 50 Philadelphia families with children of preschool age, 35 had children enrolled in preschool. Find a 95% confidence interval for the true proportion of Philadelphia families with children enrolled in preschool.

• Solution: .57298,.82702

ˆ .7

50

p

n

Page 52: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

How Confidence Intervals Behave• The user chooses the confidence level, and the margin

of error follows from this choice. – The higher the confidence level, the greater the margin of error

and hence, the larger the confidence interval.– The lower the confidence level, the lesser the margin of error

and hence, the smaller the confidence interval.

• We would like high confidence and a small margin of error.– High confidence says that our method almost always gives

correct answers.– A small margin of error says that we know the parameter more

precisely.

Page 53: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Margin of Error• The margin of error gets smaller when;

1. Z* gets smaller. Trade-off between confidence level and margin of error. To obtain a smaller margin of error from the same data, you must be willing to accept a lower confidence level.

2. gets smaller. measures the variation in the population. It is easier to pin down p when is small (less variation).

3. n gets larger. Increasing the sample size n reduces the margin of error for a fixed confidence level (large sample size means less variation).

• Because n appears under the radical, we must increase the sample size by a factor of four to cut the margin of error in half.

ˆ ˆ* (1 )me z p p n

ˆ ˆ ˆ( ) : (1 )SE p p p n ˆ( )SE pˆ( )SE p

Page 54: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Choosing the Sample Size• We can arrange to have both high confidence

and a small margin of error by taking a large enough sample.

• To determine the sample size n that will yield a confidence interval for a population proportion with a specified margin of error me.

• (margin of error wanted)• Solve for n:

ˆ ˆ* (1 )me z p p n

2

*

ˆ ˆ1p pn

me

z

Page 55: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Example:

• At the end of every school year, the state administers a reading test to a SRS drawn from a population of 100,000 third graders. Over the last five years, students who took the test correctly answered 75% of the test questions. What sample size should you use to achieve a margin of error equal to 4%, with a confidence level of 95%?

Page 56: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Solution.04me *95% 1.960CL z ˆ .75p

* ˆ ˆpqme z

n

(.75)(.25).04 1.96

n

2

.1875450.19

.04

1.96

n

Sample size should be 451 third graders.

Page 57: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Choosing Your Sample Size• To determine the sample size, choose a Margin of Error

(me) and a Confidence Interval Level.• The formula requires which we don’t have yet because

we have not taken the sample. A good estimate for , which will yield the largest value for (and therefore for n) is 0.50.

• Solve the formula for n.

p̂q̂

p̂p̂

* ˆ ˆpqme z

n

2

*

ˆ ˆpqn

me

z

Page 58: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Example:

• At the end of every school year, the state administers a reading test to a SRS drawn from a population of 100,000 third graders. What sample size should you use to achieve a margin of error equal to 4%, with a confidence level of 95%?

Page 59: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Solution:.04me

*95% 1.960CL z

* ˆ ˆpqme z

n

.5 .5.04 1.96

n

2

.25600.25

.04

1.96

n

Sample size should be 601 third graders.

ˆ .5 (most conservative value)use p

Page 60: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Your Turn:

• Suppose the U.S. President wants an estimate of the proportion of the population who support his current policy toward revisions in the Social Security System. The president wants the estimate to be within .04 of the true proportion. Assume a 90 percent level confidence. How large a sample is required?

Page 61: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Solution

(.5)(.5).04 1.645

n

2

.25422.8

.04

1.645

n

* ˆ ˆpqme z

n

Sample size should be 423.

Page 62: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Sample Size

• In practice, taking samples costs time and money. The required sample size may be impossibly expensive.

• Notice once again that it is the size of the sample that determines the margin of error. The size of the population (as long as the population is much larger than the sample) does not influence the sample size we need.

Page 63: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

The Perfect Confidence Interval

Page 64: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

What Can Go Wrong?Don’t Misstate What the Interval Means:• Don’t suggest that the parameter varies.• Don’t claim that other samples will agree with yours.• Don’t be certain about the parameter.• Don’t forget: It’s about the parameter (not the statistic).• Don’t claim to know too much.• Do take responsibility (for the uncertainty).• Do treat the whole interval equally.

Page 65: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

What Can Go Wrong?

Margin of Error Too Large to Be Useful:• We can’t be exact, but how precise do we need to be?• One way to make the margin of error smaller is to reduce

your level of confidence. (That may not be a useful solution.)

• You need to think about your margin of error when you design your study.– To get a narrower interval without giving up confidence, you

need to have less variability.– You can do this with a larger sample…

Page 66: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

What Can Go Wrong?

Choosing Your Sample Size:• In general, the sample size needed to produce a

confidence interval with a given margin of error at a given confidence level is:

where z* is the critical value for your confidence level.• To be safe, round up the sample size you obtain.

n z 2

p̂q̂

ME2

Page 67: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

What Can Go Wrong?

Violations of Assumptions:• Watch out for biased samples—keep in mind

what you learned in Chapter 12.– There is no correct method for inference from data

haphazardly collected with bias of unknown size. Fancy formulas cannot rescue badly produced data.

• Think about independence.

Page 68: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

What have we learned?

• Finally we have learned to use a sample to say something about the world at large.

• This process (statistical inference) is based on our understanding of sampling models, and will be our focus for the rest of the book.

• In this chapter we learned how to construct a confidence interval for a population proportion.– Best estimate of the true population proportion is the one we

observed in the sample.

Page 69: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

What have we learned?– Best estimate of the true population proportion is the

one we observed in the sample.– Create our interval with a margin of error.– Provides us with a level of confidence.– Higher level of confidence, wider our interval.– Larger sample size, narrower our interval.– Calculate sample size for desired degree of precision

and level of confidence.– Check assumptions and condition.

Page 70: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

What have we learned?

• We’ve learned to interpret a confidence interval by Telling what we believe is true in the entire population from which we took our random sample. Of course, we can’t be certain, but we can be confident.

Page 71: Confidence intervals for Proportions Chapter 19. Objectives: 1.Standard Error 2.Confidence Interval 3.One-proportion z-interval 4.Margin of Error 5.Critical

Assignment

• Pg. 455 – 458: #1 – 15 odd, 21, 23, 29, 31, 35

• Read Chapter 20, Pg. 459 - 475