Top Leaderboard
Markets

Z Test

Ad — article-top

A Z‑test is a hypothesis test that uses the standard normal (Z) distribution to determine whether a sample statistic (most commonly a sample mean or proportion) differs significantly from a hypothesized population value. It reports a Z‑statistic that measures how many standard deviations the sample estimate lies from the hypothesized value.

Key concepts
– Test statistic (Z): Z = (observed − hypothesized) / standard error.
– Null hypothesis (H0): usually that a population parameter equals a specified value (e.g., μ = μ0).
– Alternative hypothesis (H1): can be two‑sided (≠) or one‑sided (>, μ0 or μ critical value (or p‑value 1.96 → reject H0 at α = 0.05.
– Two‑tailed p‑value ≈ 0.0047; very small, so result is statistically significant.
Interpretation: The sample provides evidence that the average daily return is different from (in this case, less than) 3%.

Confidence interval (with known σ)
A (1 − α)100% CI for μ when σ is known:
x̄ ± z_(1−α/2) * (σ / √n)

For the example:
0.02 ± 1.96 * 0.0035355 ≈ 0.02 ± 0.00693 → (0.01307, 0.02693) or about (1.31%, 2.69%), which does not include 3%.

Other common Z‑tests
– Two‑sample Z‑test for difference of means (σ1 and σ2 known):
Z = (x̄1 − x̄2 − Δ0) / √(σ1^2/n1 + σ2^2/n2), where Δ0 is the null difference (often 0).
– Z‑test for proportions:
Z = (p̂ − p0) / √(p0(1 − p0)/n) for one proportion.
For comparing two proportions under H0: pooled p̂ is used in the denominator.
– Paired difference Z‑test: apply one‑sample Z to the differences if σd is known.

Z‑test vs T‑test — what’s the difference?
– Z‑test assumes the population standard deviation σ is known (rare in practice). If σ is unknown and the sample is small, use a t‑test, which uses the sample standard deviation s and the Student t distribution.
– For large samples (n ≥ ~30), the t distribution ≈ standard normal, so the difference between Z and t becomes negligible; many practitioners use the t‑test by default when σ is unknown.
Rule of thumb: If σ is known → Z; if σ unknown and n small → t; if n large and σ unknown → t or Z will give similar results.

When to use a Z‑test (practical guidance)
– You know the population standard deviation σ, or you have a very large sample so σ can be approximated by s.
– Sample size is large enough (commonly n ≥ 30) so CLT applies and the sampling distribution of the mean is approximately normal.
– Data are independent and reasonably free of extreme outliers.
If these conditions are not met, prefer a t‑test, bootstrap, or nonparametric method.

Central Limit Theorem (CLT) — why it matters
The CLT states that, for independent samples of size n from any population with finite mean and variance, the sampling distribution of the sample mean approaches a normal distribution as n increases. This justifies using Z (or t) tests for means even when the population distribution is non‑normal, provided n is sufficiently large (commonly n ≥ 30 as a rough rule).

Limitations and alternatives
– Knowing population σ is rare; using the sample s and a t‑test is more typical.
– Z‑tests are sensitive to non‑independence (time series, clustering) and outliers.
– For small samples from nonnormal populations, consider t‑tests (with normality checks), bootstrap confidence intervals, or permutation tests.
– For complex data structures (heteroskedasticity, correlated observations), use robust methods or model‑based inference (e.g., regression with robust standard errors).

Reporting best practices
– State H0 and H1, α, test type (one‑/two‑tailed).
– Report the test statistic, degrees of freedom (if relevant), p‑value, and confidence interval.
– Give practical interpretation (effect size, economic significance), not just statistical significance.

Bottom line
A Z‑test is a straightforward hypothesis test that compares a sample mean (or proportion) to a hypothesized population value using the standard normal distribution. It is most appropriate when the population standard deviation is known or the sample is large enough for CLT to apply. In practice, t‑tests and resampling methods are often used when σ is unknown or assumptions are in doubt.

Sources
– Investopedia, “Z‑Test” (Julie Bang):
– Newcastle University, “Z‑Test” (course material): / (search “Z‑Test”)

Editor’s note: The following topics are reserved for upcoming updates and will be expanded with detailed examples and datasets.

Ad — article-mid