One-Sample Proportion Test Calculator
Compare one observed proportion with a hypothesized proportion using an exact binomial test. Enter your summarized data as one column: events in the first data row and total trials in the second. Select the column as a metric variable to display the One-Sample Proportion Test above.
Load events and trials exampleCalculate a one-sample proportion test step by step
- Clear the data table and enter one column with your sample name in the header.
- Enter the number of events in the first data row and total trials in the second. Total trials include both events and non-events.
- Select the column under Metric Variables. If necessary, change its measurement level to metric. The column must contain exactly two values.
- Set the hypothesized proportion (%). The default is 50%.
- Choose whether the population proportion differs from, is less than, or is greater than the hypothesized proportion.
Counts must be whole numbers, with total trials greater than zero and events between zero and total trials. Keep events first and trials second; reversed counts are rejected. The exact calculation supports up to 1,000,000 trials.
Example: 42 events out of 100 trials
Load the example above or copy this table into the calculator:
| Sample |
|---|
| 42 |
| 100 |
The observed proportion is 42 / 100 = 42%. There are 58 non-events, but the second row must contain the total of 100. With a hypothesized proportion of 50% and the alternative "differs from", the test asks whether the population event proportion differs from 50%.
Hypotheses and assumptions
For a two-sided test, the null hypothesis is that the population proportion equals the hypothesized value; the alternative is that it differs. A less-than alternative tests for a smaller proportion, and a greater-than alternative tests for a larger proportion. Choose the direction before examining the results.
Use this test for independent trials with two possible outcomes, event and non-event, and the same event probability for every trial. Repeated observations from the same person or clustered observations may violate independence. The exact binomial test does not require a normal approximation or a minimum expected event count.
Understand your results
- Observed proportion: events divided by total trials.
- Exact p-value: the binomial probability of outcomes at least as extreme under the null hypothesis, according to the selected alternative. The two-sided test sums outcomes no more likely than the observed count; one-sided tests use inclusive lower or upper tails.
- 95% confidence interval: a two-sided Clopper-Pearson interval for the population proportion, including when there are zero events or all trials are events.
Compare the p-value with your chosen significance level, commonly 0.05. A smaller p-value provides evidence against the null hypothesis; a larger p-value does not prove that the population proportion equals the hypothesized value. The confidence interval remains two-sided for every alternative and is not an inversion of the probability-ordered two-sided test, so their significance decisions can differ.
Related calculators
If you have one row per observation, such as Yes and No values, use the Binomial Test Calculator for raw data. To compare event proportions in two independent groups, use the Two-Sample Proportion Test Calculator.