Statistical functions
CONFIDENCE.NORM
Close: 1 of 5 recorded answers differ in the last bits, worst 2 ULP
Everything else matches (5 workbook cells). Last-bit means a finite number within 16 ULP of Excel's. How we measure this · See the Rust code
Local names in 40 languages
| Language | Name in Excel |
|---|---|
| Arabic | CONFIDENCE.NORM |
| Bulgarian | CONFIDENCE.NORM |
| Czech | CONFIDENCE.NORM |
| Danish | KONFIDENS.NORM |
| German | CONFIDENCE.NORM |
| Greek | CONFIDENCE.NORM |
| English (Australia) | CONFIDENCE.NORM |
| English (United Kingdom) | CONFIDENCE.NORM |
| English (United States) | CONFIDENCE.NORM |
| Spanish | INTERVALO.CONFIANZA.NORM |
| Estonian | CONFIDENCE.NORM |
| Finnish | LUOTTAMUSVÄLI.NORM |
| French | INTERVALLE.CONFIANCE.NORMAL |
| Hebrew | CONFIDENCE.NORM |
| Croatian | CONFIDENCE.NORM |
| Hungarian | MEGBÍZHATÓSÁG.NORM |
| Indonesian | CONFIDENCE.NORM |
| Italian | CONFIDENCE.NORM |
| Japanese | CONFIDENCE.NORM |
| Korean | CONFIDENCE.NORM |
| Lithuanian | CONFIDENCE.NORM |
| Latvian | CONFIDENCE.NORM |
| Norwegian | CONFIDENCE.NORM |
| Dutch | VERTROUWELIJKHEID.NORM |
| Polish | UFNOŚĆ.NORM |
| Portuguese (Brazil) | CONFIANÇA.NORMA |
| Portuguese (Portugal) | INT.CONFIANÇA.NORM |
| Romanian | CONFIDENCE.NORM |
| Russian | ДОВЕРИТ.НОРМ |
| Slovak | CONFIDENCE.NORM |
| Slovenian | CONFIDENCE.NORM |
| Serbian (Latin) | CONFIDENCE.NORM |
| Swedish | KONFIDENCE.NORM |
| Thai | CONFIDENCE.NORM |
| Turkish | GÜVENİLİRLİK.NORM |
| Ukrainian | CONFIDENCE.NORM |
| Vietnamese | CONFIDENCE.NORM |
| Chinese (Simplified) | CONFIDENCE.NORM |
| Chinese (Hong Kong) | CONFIDENCE.NORM |
| Chinese (Traditional) | CONFIDENCE.NORM |
Names from Microsoft's support site.
What it does
CONFIDENCE.NORM(alpha, standard_dev, size)
CONFIDENCE.NORM(alpha, standard_dev, size) returns the half-width of a two-sided confidence
interval for a population mean, under the assumption that the population standard deviation is
known and the sampling distribution of the mean is normal.
Writing Φ for the standard normal cumulative distribution function and z_q = Φ⁻¹(q) for its
quantile,
CONFIDENCE.NORM(α, σ, n) = z_{1 − α/2} · σ / √n
and the interval Microsoft's page states is
x̄ ± CONFIDENCE.NORM(α, σ, n)
where x̄ is the sample mean. The confidence level is 100·(1 − α)%, so α = 0.05 gives the
familiar 95% interval and z_{0.975} ≈ 1.959963985….
Three things follow from the formula and are worth stating plainly:
- The function never sees your data. It takes a spread and a count, not a sample. It is a
scaling of one normal quantile — the entire mathematical content is
Φ⁻¹. - It returns a half-width, not an interval. Readers who expect a pair of endpoints get a single number; the endpoints have to be assembled by hand.
σis treated as known. That is the modelling assumption that separates this function from CONFIDENCE.T, which uses a Student's t quantile withn − 1degrees of freedom because the spread was estimated from the sample.
Domain and range. The mathematical function is defined for α ∈ (0, 1), σ > 0, n ≥ 1, and is
positive on all of it. It is decreasing in α (a higher confidence level widens the interval),
linear and increasing in σ, and decreasing in n like n^(−1/2) — the familiar square-root law
that makes halving an interval cost four times the sample. As α → 0⁺ the value diverges, because
Φ⁻¹(q) → +∞ as q → 1⁻; as α → 1⁻ it tends to 0.
Arguments
| Argument | Meaning (as documented) | Admissible values |
|---|---|---|
alpha | "The significance level used to compute the confidence level. The confidence level equals 100*(1 - alpha)%" | 0 < alpha < 1, per the documented error rule |
standard_dev | "The population standard deviation for the data range and is assumed to be known" | standard_dev > 0, per the documented error rule |
size | "The sample size" | size ≥ 1 after truncation, per the documented error rule |
The commonly misunderstood position is the first. alpha is the significance level, not the
confidence level: a reader who wants 95% must pass 0.05, and passing 0.95 silently produces the
90%-two-tailed half-width instead of an error. Nothing in the value or the type catches that
mistake.
All three are numeric slots subject to ordinary to-number coercion; see Coercion and lifting.
Try it
Quirks
Result and edge cases
Returns Number — a positive half-width.
Documented boundary behaviour, from Microsoft's page:
- Non-numeric argument →
#VALUE!. alpha ≤ 0oralpha ≥ 1→#NUM!. Both ends are closed against you:alpha = 0would be an infinite interval andalpha = 1a degenerate one, and neither is admitted.standard_dev ≤ 0→#NUM!. A zero spread is rejected rather than returning a zero width.sizenon-integer → truncated;size < 1→#NUM!.
Errors
As documented on Microsoft's CONFIDENCE.NORM page:
| Error | Condition |
|---|---|
#VALUE! | Any argument is nonnumeric |
#NUM! | alpha ≤ 0 or alpha ≥ 1 |
#NUM! | standard_dev ≤ 0 |
#NUM! | size < 1 (after truncation) |
How to implement
Numerical notes
The whole numerical difficulty is Φ⁻¹, and it is a genuinely hard function to evaluate well.
- Why it is hard.
Φ⁻¹(q)has infinite slope at both ends of(0,1)and the naive route — inverterfby iteration on a series forΦ— loses relative accuracy in the tails, where the quantity of interest is large and the probability that determines it is tiny. Every digit ofqnear1is worth a great deal ofz, so cancellation in forming1 − α/2is a real hazard. - The literature. Abramowitz & Stegun chapter 26 gives the classical rational approximations
(26.2.22, 26.2.23) with their absolute-error bounds — good enough for tables, not for double
precision. The modern standard is Wichura's AS 241 (
PPND16), accurate to about 16 significant digits over the whole open interval; Moro's and Acklam's approximations are the usual fast alternatives, and Cephes and Boost both carry well-testedndtri/erfc_invroutines. Anyone implementing this function is really choosing among those. - The rest is trivial and still worth care.
σ/√nis one square root and one division. Formingz · σ / √nas(z * σ) / sqrt(n)and asz * (σ / sqrt(n))differ in the last bit; a compatibility implementation has to pick the same association Excel picks, and the Handbook does not know which that is. - Truncation before the square root. Because
sizeis truncated first, the divisor is√⌊n⌋, not√n. An implementation that truncates after taking the root would agree on integer inputs and disagree everywhere else — a bug that hides from every integer test case.
Do not read any of this as a claim about Excel's internal algorithm. What the Handbook can say is that this surface's accuracy is exactly the accuracy of whatever normal quantile sits underneath it, and that nobody has measured that here.
Rust code
Show the CalcFunc source of this function
Quoted from the public repository DnaCalc/DnaCalc, crates calc-func and calc-fml, at commit 9e1884369a67. Comments are the source's own. A kernel shared with other functions appears once, on its module page.
CONFIDENCE.NORM · 4 lines · calc-func/src/catalogue/distributions.rs on GitHub14 confidence_norm "CONFIDENCE.NORM" (3, 3) [V "alpha", V "standard_dev", V "size"] |s, a, sv| {
let [alpha, sd_, n] = nums::<3>(s, a)?;
out(s, nl::confidence_norm_kernel(alpha, sd_, n))
}
Kernels shared with other functions
numscatalogue/distributionsbinary_withported/excel_numericexcel_x87_mulported/excel_numericmulported/excel_numeric/x87phi_kernelported/normal_dist_commonvalidate_probability_open_unitported/normal_log_familyinverse_standard_normal_acklam_refinedported/normal_log_familyinverse_standard_normalported/normal_log_familyconfidence_norm_kernelported/normal_log_family
Argument and result plumbing
No implementation has been published with a Handbook test suite for this function.
Version differences
No comparison between specific Excel builds is recorded here yet. This does not establish that all builds behave alike.
Alternatives
Relationships
- CONFIDENCE.T — the sibling for an estimated standard deviation. The
two differ by exactly one substitution:
z_{1−α/2}becomest_{1−α/2, n−1}. Becauset_{q,ν} > z_qfor every finiteν,CONFIDENCE.Tis always the wider of the two on the same inputs, converging toCONFIDENCE.NORMasn → ∞. Choosing the normal form when the spread came from the sample understates the interval, and for smallnit understates it badly. - NORM.S.INV — the quantile this function calls.
CONFIDENCE.NORM(α, σ, n)andNORM.S.INV(1 − α/2) * σ / SQRT(n)are the same expression; the second is the one to use when you want to see the pieces. - Z.TEST — the hypothesis test that pairs with this interval.
- Confused with:
CONFIDENCE.NORMis not a margin of a proportion. Applying it to a proportion requiresσ = √(p(1−p)), which the function will not compute for you.
Named variants
No named variants are recorded yet.
Suggest a correction or contribute an implementation · For agents