# Deducing Sample Size from Sample Proportion CI

## Homework Statement

Suppose we want to estimate a sample proportion to within 0.05 with 95% confidence, how large will the sample have to be?

There is no other information about the distributions of the population or the sample.

How do I approach this problem?

## Homework Equations

See attempted solution below.

for a proportion problem, sample stddev, sigma x bar = sqrt(pq/n)

## The Attempt at a Solution

No point in trying to solve for n in the equation 1.96 * sqrt(pq / n) = 0.05, because I don't know what pq is.

(This is NOT homework. I'm a 62 year-old brushing up on statistics for professional reasons, but one of your "mentors" with a bike-riding avatar is worried that I might be cheating on a high school exam, so he sent me here. Maybe I'm in my 2nd childhood, which is why I provoke these suspicions. I got some *great* responses to more difficult statistics problems on this forum back in 2012. I do hope your new policies have not rendered this resource useless to me. I will go bug people on the actuarial forums if you force me to, though I'd rather not because I think this is a more appropriate venue - or used to be, anyway.)

Related Calculus and Beyond Homework Help News on Phys.org
Ray Vickson
Homework Helper
Dearly Missed

## Homework Statement

Suppose we want to estimate a sample proportion to within 0.05 with 95% confidence, how large will the sample have to be?

There is no other information about the distributions of the population or the sample.

How do I approach this problem?

## Homework Equations

See attempted solution below.

for a proportion problem, sample stddev, sigma x bar = sqrt(pq/n)

## The Attempt at a Solution

No point in trying to solve for n in the equation 1.96 * sqrt(pq / n) = 0.05, because I don't know what pq is.

(This is NOT homework. I'm a 62 year-old brushing up on statistics for professional reasons, but one of your "mentors" with a bike-riding avatar is worried that I might be cheating on a high school exam, so he sent me here. Maybe I'm in my 2nd childhood, which is why I provoke these suspicions. I got some *great* responses to more difficult statistics problems on this forum back in 2012. I do hope your new policies have not rendered this resource useless to me. I will go bug people on the actuarial forums if you force me to, though I'd rather not because I think this is a more appropriate venue - or used to be, anyway.)
You may not know what $p$ and $q = 1-p$ are, but $pq = p(1-p)$ has a maximum over $0 \leq p \leq 1$ at the point $p = 1/2$, where it equals $1/4$. That is, $p q \leq 1/4$ for all $p \in [0,1]$. If you replace $pq$ in your formula above by $1/4$ and then solve for $n$, that $n$ will be larger (or, at least, not smaller than) the actual $n$ that would go along with $p,q$ if you knew what they were. In other words, you can't go wrong if you solve
$$1.96 \sqrt{0.25/n} = 0.05.$$
You may be using a larger $n$ than you really need, so you may be performing more experiments than you really require. The point is, though, that you will not be performing fewer experiments than you really need.

• pluviosilla
You may not know what $p$ and $q = 1-p$ are, but $pq = p(1-p)$ has a maximum over $0 \leq p \leq 1$ at the point $p = 1/2$, where it equals $1/4$. That is, $p q \leq 1/4$ for all $p \in [0,1]$. If you replace $pq$ in your formula above by $1/4$ and then solve for $n$, that $n$ will be larger (or, at least, not smaller than) the actual $n$ that would go along with $p,q$ if you knew what they were. In other words, you can't go wrong if you solve
$$1.96 \sqrt{0.25/n} = 0.05.$$
You may be using a larger $n$ than you really need, so you may be performing more experiments than you really require. The point is, though, that you will not be performing fewer experiments than you really need.
Great response! Thanks!