OhMyCalc

Hypothesis Testing Calculator (One-sample z-test)

Compute the z-score and approximate two-tailed p-value for a one-sample z-test from sample mean, population mean, population standard deviation and sample size.

How to Use the Hypothesis Testing Calculator (One-sample z-test)

  1. Enter the sample mean and population mean.
  2. Enter the population standard deviation and sample size.
  3. Click Calculate to see z, p-value and significance verdict.

使用例

計算式

z = (x̄ − μ) / (σ/√n). Two-tailed p ≈ 2·(1 − Φ(|z|)), approximated as 2·exp(−0.717·|z| − 0.416·z²).

よくある質問

How accurate is the p-value approximation?
The closed-form used here is accurate to about ±0.002 for |z| ≤ 3.5, which is enough for teaching and sanity checks. Use dedicated stats software for publication-grade values.
When is a z-test appropriate?
When the population standard deviation is known and the sample size is large enough (roughly n ≥ 30) for the central limit theorem to apply. Otherwise use a t-test.
Is this one- or two-tailed?
Two-tailed. For a one-tailed test, halve the reported p-value.