Sample Size Calculation For Proportions Including Excel Formulas

0 Comments
Join the Conversation
What Sample Size Is Needed - Clarita
What Sample Size Is Needed - Clarita
Formulas are described to calculate sample size for 1-sample and 2-sample proportions, for one- and two-tailed comparisons. The Excel formula is also shown.

The formula to work out sample sizes for proportions is useful in many instances. There are several versions of the formula needed to cover one-sample and two-sample tests, and one-tailed and two-tailed comparisons. In this article, the formula for each situation is given, along with the Microsoft Excel function that performs the calculations. A separate article on this site gives the Excel sample size formula for means.

A free sample size calculator is being developed, as logged at blogger.com

Sample Size Formula For Proportions: Terms Used

α = Level of acceptability of a false positive result (0.05 is typical)

β = Level of acceptability of a false negative result (0.10 is typical)

δ = Amount of difference that matters (Practical difference)

πo = Proportion of known population

πa = Sample proportion for which sample size needs to be calculated = πo + δ

arcsin(x) = the angle (in radians) whose sine is x

It will be noted that this is for the one-tail version of the formula. The two-tail version of the formula simply substitutes α/2 for α.

Sample Size Formula For One-Sample Proportion

This type of test is used when a sample is to be taken from a population and compared to a known proportion πo.

Sample Size = (Zα + Zβ)² / [2 × arcsin(√πo) - 2 × arcsin(√πa)]²

It will be noted that this is the one-tail version of the formula. The two-tail version of the formula simply substitutes alpha/2 and beta/2 for alpha and beta:

Sample Size = (Zα/2 + Zβ)² / [2 × arcsin(√πo) - 2 × arcsin(√πa)]²

Sample Size Example For One-Sample Proportion

In certain instances there are specialized protocols that must be strictly adhered to. Testing the efficacy of new drugs, for example, normally follows a protocol that includes selecting sample size. Where there are no legal implications to the test, such as an engineering process improvement, it is possible to estimate sample sizes using certain assumptions. It is common, for instance, to use the following values in the sample size calculation:

α = 0.05

β = 0.50

πo = 0.50

δ = 0.05

Using these values, the sample sizes may be estimated as 270 for a one-tailed test, and 383 for a two-tailed test.

Excel Sample Size Formula For One-Sample Proportion

In cell A1, enter the value of α

In cell A2, enter the value for β (0.1 is typical; set to 0.5 to ignore influence)

In cell A3, enter the value for known proportion

In cell A4, enter the value of the difference to be detected

The Excel formula to estimate sample size for a one-sided test is then

=(NORMSINV(1-A1)+NORMSINV(1-A2))^2/(2*ASIN(SQRT(A3+A4))-2*ASIN(SQRT(A3)))^2

For a two-sided test, the formula is

=(NORMSINV(1-A1/2)+NORMSINV(1-A2))^2/(2*ASIN(SQRT(A3+A4))-2*ASIN(SQRT(A3)))^2

Excel Sample Size Formula For Two-Sample Proportion

This type of test is used when samples from two populations need to be compared:

In cell A1, enter the value of α

In cell A2, enter the value for β

In cell A3, enter the value for one proportion

In cell A4, enter the value of the difference between proportions to be detected

The Excel formula to estimate sample size for a one-sided test is then

=(NORMSINV(1-A1)+NORMSINV(1-A2))^2/(2*ASIN(SQRT(A3+A4))-2*ASIN(SQRT(A3)))^2

For a two-sided test, the formula is

=2*(NORMSINV(1-A1/2)+NORMSINV(1-A2))^2/(2*ASIN(SQRT(A3+A4))-2*ASIN(SQRT(A3)))^2

Sample Size For Proportions Summary and Caveat

Sample size calculation methods are described for one- and two-proportions testing, along with the Microsoft Excel functions that will do the actual calculations.

Sample size calculations are estimates, and are subject to certain conditions. The calculation is part of a wider sample size selection method. Very small proportions, for example, need totally different formulas. The version of formulas used here is based on the continuity-corrected arc sine transformation work by Dobson & Gebski. For instances where a sample calculation will have legal or ethical implications, a professional statistician should be consulted.

There are online sample size calculators readily available too, and it often makes sense to check several sources before deciding on a final sample size. A free sample size calculator is being developed, as logged at blogger.com

Sample Size Method For Proportions References

Julious, S.A., (2009), Sample Sizes for Clinical Trials. Boca Raton: CRC Press.

Dobson, A. J. and Gebski, V. J., "Sample sizes for comparing two independent proportions using the continuity-corrected arc sine transformation", The Statistician (1986).

Me at Lake Garda, Summer 2008, Photograph taken by Alison Bell

Martin Bell - Martin holds a B.Sc. degree in chemical engineering, and an M.Sc. degree in electronics and computing. He has spent more than 25 years ...

rss
Advertisement
Leave a comment

NOTE: Because you are not a Suite101 member, your comment will be moderated before it is viewable.
Submit
What is 7+9?
Advertisement
Advertisement