230 likes | 420 Views
Confidence Interval (CI) for a Proportion Choosing the Sample Size. When we collect data from our 1 random sample and compute the sample proportion, the interval of values. Confidence Interval for p. forms an (approximate) confidence interval (CI) for p .
E N D
Confidence Interval (CI)for a ProportionChoosing the Sample Size
When we collect data from our 1 random sample and compute the sample proportion, the interval of values Confidence Interval for p forms an (approximate) confidence interval (CI) for p.
A marketing firm intends to survey newspaper readers to determine what percent of readers notice a particular ad campaign. They will summarize their data and form a 95% confidence interval; the interval will be reported back to the company purchasing the ads. The company has requested an error margin no greater than 0.05. What should be the sample size n? Example
Before the study is conducted, E is unknown. If the goal is to sample enough to have an error margin no greater than a target value E: Error Margin
A marketing firm intends to survey newspaper readers to determine what percent of readers notice a particular ad campaign. They will summarize their data and form a 95% confidence interval; the interval will be reported back to the company purchasing the ads. The company has requested an error margin no greater than 0.05. Example
Use 0.5 as the prevalence. “Ignorant” Solution • It’s impossible to sample 0.16 of a reader. • Answer: Sample at least 385 readers. • Sample sizes must be whole numbers.
320 of the 385 readers noticed the campaign. The actual error margin is Implementing the Solution Had 0.83 had been known in advance (it wasn’t), the required sample size would have been 217.
If you use 0.5 to determine the sample size, you will get an error margin no more than the desired value. • But…Unless the prevalence turns out to be 0.5 exactly, the error margin will be less than desired. • The error margin will be considerably less than desired if the prevalence is far from 0.5. Time and money are wasted. Flaw in Ignorant Solution
How many trees should we sample in order to estimate the proportion expected to die with error margin no greater than 0.02 = 2%? Assume we want 99% confidence in our result. Past history suggests a result in the vicinity of 0.190. A 90% CI based on 216 trees yielded 0.190 ± 0.044. We might try values 0.15 to 0.25 in order to obtain an indication of what the sample size should be. Example
The actual error margin will depend on the observed proportion. If it is closer to 0.5 than what we use to get a sample size, then we will not meet the desired error margin. We won’t meet the goal. • That is why 0.5 is guaranteed to get the error margin. • If it is further from 0.5 than what we use, then we will undershoot the desired error margin. This is fine, except that it adds to the expense of the study. • For values 0.35 – 0.65, using 0.5 as a guess generally doesn’t oversample by too much. Example
The proportion of students who have had the flu (through 11/4/2009) was estimated with a sample of n = 62. The 90% confidence interval was: 0.177 0.080 (0.097, 0.257) How many students should be sampled to reduce the error margin by half to 0.04? Example
0.177 0.080 (0.097, 0.257) Our result supports a future result between about 0.10 and 0.26. Our best guess would be about 0.18. Assuming Required n 0.18 Example
0.177 0.080 (0.097, 0.257) Our result supports a future result between about 0.10 and 0.26. Our best guess would be about 0.18. Assuming Required n 0.18 250 (about 4 62) Example
In general, the larger n is, the smaller E is. If we only compare situations with the same confidence and proportion, then • Reducing the error margin by a multiplicative factor of k requires increasing the sample size by a factor of k2. • Ex: Making the error margin twice (2 times) as small requires making the sample size 22 = 4 times bigger. • For E = 0.02 (4 times smaller), n = 16(62) = 992. • For E = 0.01 (8 times smaller), n = 64(62) = 3968 Relation between n and E
0.177 0.080 (0.097, 0.257) Our result supports a future result between about 0.10 and 0.26. Our best guess would be about 0.18. Assuming Required n 0.18 250 (about 4 62) 0.10 152 0.26 326 0.50 (ignorant) 423 Example
A computer manufacturer’s tech support office wants to assess the percent of customers who make service calls within the first month. The company wants to be 90% confident that the sample percentage is within two percentage points of the true percentage Past surveys have revealed this figure to be in the 5 – 15% range. Example
You try 0.10. (The confidence is 90%. The desired error margin is 2%.) What is the required sample size? (Give a whole number as answer.) The required sample size is 609. Example
Some prevalence must be assumed to obtain a sample size. • If the result is closer to 0.5 than what was assumed, the error margin will be larger than desired. • If the result is farther from 0.5 that what was assumed, resources will have been wasted. Trade-off for any solutions
Use 0.5 if you have no idea, or if you anticipate a prevalence close to 0.5. • In public opinion polls for a 2-candidate election, the prevalence is often near 0.5. So 0.5 is used. (Remember: 95% confidence for media polls.) • If you have a guessed (range of) value(s), use it, but recognize that: an actual result closer to 0.5 will cause you to miss the objective; a result further from 0.5 will cause you to oversample. Reasonable Compromise