样本量估算

🔮 Sample Size Estimator

Enter the acceptable margin of error, confidence level and population standard deviation to estimate the minimum sample size for a mean, planning sample counts with sufficient precision.

📐 计算公式 / 原理
均值估计 n = ⌈(z·σ / e)²⌉;比例估计 n = ⌈z²·p(1−p) / e²⌉
按给定置信水平反解 z 后估计最小样本量:均值估计用 n = (z·σ/e)²,其中 σ 为总体标准差估计、e 为允许误差;比例估计用 n = z²·p(1−p)/e²,p 为预期比例。结果向上取整到整数,用于调查与实验的抽样规划。

📐 计算公式与说明

n = (Z · σ / ME)²(均值)
n = Z² · p(1−p) / ME²(比例)

结果向上取整。

📚 深度解析:置信水平与临界值

💡 常见使用场景

95% 临界
双尾 95% 对应 z=1.96(每尾 2.5%);99% 对应 z=2.576(每尾 0.5%)。
权衡
提置信到 99% 区间更宽(更保守但更含糊),是精度与把握的权衡。

❓ 常见问题(FAQ)

置信水平越高越好?
越高区间越宽、越不精确;选 95% 是惯例平衡,特殊领域用 99% 或 90%。
z 和 t 临界区别?
小样本/σ 未知用 t 临界(随 df 变、略大于 z);大样本 t≈z。