One Proportion Z-Test Calculator
Test if proportion differs from a value.
Number of successes must be a non-negative integer
Enter sample data and hypothesized proportion to test
What Is a One-Proportion Z-Test?
The one-proportion z-test determines whether a sample proportion differs significantly from a hypothesized population proportion.
Question answered: "Is the true proportion different from this specific value?"
Examples:
- "Is our conversion rate different from the industry standard of 3%?"
- "Is the defect rate below the acceptable threshold of 2%?"
- "Is voter approval above 50%?"
The Hypotheses
Null hypothesis (Hβ): p = pβ (population proportion equals hypothesized value)
Alternative hypothesis (Hβ):
- Two-tailed: p β pβ (proportion is different)
- Right-tailed: p > pβ (proportion is greater)
- Left-tailed: p < pβ (proportion is less)
The Test Statistic
Where:
- = sample proportion (x/n)
- = hypothesized proportion
- = sample size
The denominator is the standard error under the null hypothesis.
Example Calculation
Scenario: A company claims 20% of customers repurchase. We observe 85 repurchases in 500 customers. Is this different from 20%?
Data:
- x = 85 repurchases
- n = 500 customers
- pΜ = 85/500 = 0.17
- pβ = 0.20
Calculation: SE = β[0.20 Γ 0.80 / 500] = β[0.00032] = 0.0179
z = (0.17 - 0.20) / 0.0179 = -1.68
P-value: For two-tailed test, p = 0.093
Conclusion: The repurchase rate (17%) is not significantly different from 20% at Ξ± = 0.05 (p = 0.093).
Sample Proportion and Count
The test can be formulated two ways:
Proportion form: pΜ = x/n
Count form: Test whether x differs from npβ
Both give identical results. Use whichever is more natural for your problem.
Assumptions
Adequate Sample Size
Both npβ and n(1-pβ) should be β₯ 10 (some sources say β₯ 5).
This ensures the normal approximation to the binomial is valid.
Example: n = 100, pβ = 0.05
- npβ = 5 (borderline)
- Consider exact binomial test instead
Independence
Each observation is independent. One outcome doesn't affect another.
Random Sampling
Sample represents population of interest.
Simple Random Sample
Or at least a sampling design that approximates it.
When to Use Exact Binomial Test
Use one-proportion z-test when:
- n is large (β₯ 30)
- npβ β₯ 10 and n(1-pβ) β₯ 10
- Quick approximation is acceptable
Use binomial test when:
- Sample is small
- Proportion is near 0 or 1
- Exact p-value is required
Continuity Correction
The z-test approximates a discrete distribution (binomial) with a continuous one (normal).
Corrected z: z = (|pΜ - pβ| - 1/(2n)) / β[pβ(1-pβ)/n]
Effect: Makes the test slightly more conservative (higher p-values).
Modern view: Often unnecessary with adequate sample sizes.
Confidence Interval
A related calculation is the confidence interval for a proportion:
If falls outside the 95% CI, you'd reject at Ξ± = 0.05.
Applications
Quality Control
Is defect rate at or below target?
Hβ: p = 0.02 (2% defect rate) Observed: 15 defects in 600 items (2.5%)
Marketing
Is conversion rate above baseline?
Hβ: p = 0.03 (3% conversion) Observed: 45 conversions in 1200 visitors (3.75%)
Political Polling
Does candidate have majority support?
Hβ: p = 0.50 (50% support) Observed: 525 supporters in 1000 respondents (52.5%)
Medical Research
Is treatment success rate above standard?
Hβ: p = 0.70 (70% historical success) Observed: 82 successes in 100 patients (82%)
A/B Testing
Is new variant's rate different from control?
Note: For comparing two variants, use two-proportion z-test.
One-Tailed Tests
Right-tailed (p > pβ): Testing if proportion exceeds threshold. "Is success rate above 80%?"
Left-tailed (p < pβ): Testing if proportion is below threshold. "Is defect rate below 1%?"
P-value: For one-tailed, divide two-tailed p-value by 2 (in the predicted direction).
Effect Size: Cohen's h
For proportions:
| h | Interpretation |
|---|---|
| 0.2 | Small |
| 0.5 | Medium |
| 0.8 | Large |
This transformation stabilizes variance, making h comparable across different baseline proportions.
Relationship to Chi-Square
For one proportion against expected:
zΒ² = ΟΒ² (with df = 1)
The one-proportion z-test is equivalent to a chi-square goodness-of-fit test with two categories.
Common Mistakes
Using Wrong Standard Error
The SE formula uses pβ (hypothesized), not pΜ (observed).
For confidence intervals, use pΜ. For hypothesis test, use pβ.
Ignoring Sample Size Requirements
If npβ < 10, the normal approximation is poor. Use exact binomial test.
One-Tailed Without Justification
One-tailed tests require prior directional hypothesis. Don't choose after seeing data.
Interpreting Non-Significance as Equality
p > 0.05 doesn't prove p = pβ. It only means you can't rule out equality.
Power and Sample Size
For planning studies:
Minimum n = [zββΞ±/β Γ β(pβqβ) + zββΞ² Γ β(pβqβ)]Β² / (pβ - pβ)Β²
Use sample size calculator for proportions for proper planning.
Reporting Results
APA format:
"A one-sample z-test for proportions indicated that the observed repurchase rate (17%, n = 500) did not differ significantly from the hypothesized 20%, z = -1.68, p = .093."
Include:
- Sample proportion and n
- Hypothesized value
- z-statistic
- P-value
- Confidence interval (optional)
Historical Context
The one-proportion z-test emerged from the general framework of large-sample theory developed in the late 19th and early 20th centuries.
The test applies the Central Limit Theorem to proportions: with sufficient n, sample proportions are approximately normally distributed around the true proportion.
Abraham de Moivre (1733) and Pierre-Simon Laplace (1812) established the theoretical foundations. The modern formulation became standard in mid-20th century statistical practice.
Related Calculations
- Two-Proportion Z-Test β Compare two proportions
- Binomial Test β Exact test for proportions
- Confidence Interval for Proportion β Interval estimate
- Sample Size for Proportions β Study planning
- Chi-Square Goodness-of-Fit β Equivalent test
Summary
The one-proportion z-test determines whether a sample proportion differs from a hypothesized value by calculating z = (pΜ - pβ) / SE, where SE uses the null hypothesis proportion. The test requires npβ β₯ 10 and n(1-pβ) β₯ 10 for valid normal approximation; otherwise use exact binomial test. Report the sample proportion, hypothesized value, z-statistic, and p-value. For small samples or extreme proportions, the binomial test provides exact p-values without relying on the normal approximation.