Calculators

Sample Size Calculator for Decision Analysis

Estimate the sample size needed to measure a population proportion at a chosen confidence level and margin of error. This planning estimate uses a normal approximation and does not account for finite population size, design effects, or nonresponse.

Loading calculator...

What this Sample Size Calculator for Decision Analysis does

This sample size calculator estimates how many independent observations are needed to estimate a population proportion with a selected margin of error and confidence level. In decision analysis, a proportion might represent the share of customers choosing an option, the fraction of projects meeting a criterion, or the percentage of survey participants favoring a policy. The output, Estimated Sample Size, is a planning estimate in respondents or observations. Because people and observations are whole units, round any fractional result up before using it as a target.

The calculation uses the normal approximation for a proportion: n = z² × p × (1 − p) ÷ e². Here, z is the confidence level expressed as a standard score, p is the anticipated proportion, and e is the margin of error in proportion units. For instance, a five percentage point margin is entered as 0.05. The estimate assumes a random sample and independent responses. It does not automatically adjust for a finite population, clustered or weighted sampling, incomplete responses, or other study design features.

How to use the Sample Size Calculator for Decision Analysis

Enter the confidence level z-score, an estimated proportion, and the margin of error. The defaults use a common planning setup: z = 1.96, p = 0.50, and e = 0.05. Change the values when you have a reason grounded in the decision context or an approved research plan.

  • Confidence level z-score controls the confidence level represented by the normal approximation. For example, 1.96 corresponds approximately to 95% confidence under standard assumptions.
  • Estimated proportion is the expected share with the outcome of interest. If previous evidence does not support a reliable estimate, 0.50 is a conservative planning choice for this formula because it yields the largest variance term among proportions.
  • Margin of error specifies the desired precision in absolute proportion units. Enter 0.05 for five percentage points, or 0.03 for three percentage points.

Read the result as the approximate minimum number of completed, independent observations for the stated precision assumptions. If you expect some people not to respond, the number invited may need to be higher. That adjustment is separate from this calculator and depends on a defensible response-rate estimate.

How the Sample Size Calculator for Decision Analysis formula works

The formula is n = z²p(1 − p)/e². It combines the chosen confidence multiplier with the variability of a binary outcome and the desired precision. Squaring the margin of error in the denominator means that seeking twice the precision, such as moving from 0.05 to 0.025, requires roughly four times as many observations when the other inputs remain fixed.

Worked example: use z = 1.96, p = 0.50, and e = 0.05. Then n = 1.96² × 0.50 × (1 − 0.50) ÷ 0.05². This gives 3.8416 × 0.25 ÷ 0.0025 = 384.16. Since a sample cannot contain a fraction of a respondent, round upward to 385 completed observations. The result is approximate and should be checked against the planned sampling method.

The inputs use proportion units from 0 to 1 rather than percentage numbers from 0 to 100. Thus, an anticipated 40% outcome is 0.40, and a three percentage point margin is 0.03. Keeping both values in the same unit convention is essential. Entering 5 to mean five percentage points would make the formula's result misleading.

Use cases for the Sample Size Calculator in decision analysis

Sample size planning can clarify the evidence behind a decision. An analyst comparing potential service designs may need to estimate the share of users who prefer one approach. A team evaluating whether a process change is acceptable may want a proportion estimate before deciding whether to expand a pilot. A policy group may plan a survey to understand how often a defined condition occurs.

In each case, the estimate helps connect a research plan to a decision threshold. A smaller margin of error requires a larger sample, which may affect the time and resources available. A higher confidence multiplier also increases the estimate. This calculator does not identify which precision or confidence level is appropriate. Those choices should reflect how consequential the decision is and how much uncertainty decision makers can tolerate.

For a binary outcome, the value p represents the anticipated probability of the outcome in the population. If the goal is to estimate a mean, compare groups, measure a rare event, or test a hypothesis, this proportion formula may not fit. Those designs require different calculations and often additional assumptions.

Other factors to consider when calculating a sample size

The formula assumes simple random sampling from a population large enough that a finite population correction is not needed. If a large share of a small known population will be sampled, the required number may differ. Clustering, stratification, weighting, repeated measurements, or unequal selection probabilities can also change precision. Use a method that reflects the actual design when these features matter.

Consider the outcome definition and data collection process as well. Ambiguous survey wording can create measurement error that a larger sample does not fix. Missing responses may differ systematically from completed responses, and simply recruiting more people does not necessarily remove that bias. If response rates are uncertain, plan recruitment separately and explain the assumptions.

For decision analysis, precision is only one part of the evidence. Consider the consequences of incorrect decisions, the costs of gathering information, and whether the result could change the chosen action. Document the input values, source of the anticipated proportion, sampling approach, and rounding rule so others can review the plan.

Frequently asked questions

What does the confidence level z-score mean?

It is the normal-distribution multiplier used for the selected confidence level. A value near 1.96 is commonly associated with 95% confidence for a two-sided interval under standard assumptions. The input is the z-score itself, not the percentage confidence value.

Why is the estimated proportion set to 0.50 by default?

The variance term p(1 − p) is largest at 0.50, so this default generally produces a cautious sample size estimate when no prior proportion is available. Use a different value when relevant prior data or a sound planning assumption supports it.

Should I round the sample size up or down?

Round up to the next whole observation. Rounding down could leave the completed sample below the calculated estimate. Recruitment targets may need a separate increase to account for nonresponse or unusable records.

Does the estimate include nonresponse or survey bias?

No. It estimates the sample needed under its mathematical assumptions. It does not compensate for people who do not respond, selection bias, unclear measurement, or systematic differences between respondents and the target population.

Can I use this for comparing two groups?

This formula estimates one population proportion. A comparison between groups generally depends on the difference you want to detect, group allocation, outcome variability, and testing approach. Use a calculation designed for that comparison and its study design.

Written by

sasqag.org Editorial Team

Editorial team

sasqag.org publishes practical how-to guides and educational articles with clear steps and useful context.