ArticleslgStudy

mathematics

Chi-squared distribution

Chi-squared distribution is a mathematics topic covered in the lgStudy science library. This page brings together a partial reference excerpt, illustrations, worked examples, real-world applications and a short study plan, so you can understand Chi-squared distribution rather than just read about it. In short: In probability theory and statistics, the χ2-distribution with k degrees of freedom is the distribution of a sum of the squares of k independent standard normal random variables. The chi-squared distribution χk2 is a special case of the gamma distribution and the univariate Wishart distribution.

Chi-squared distribution — main illustration
Chi-squared distribution — illustration

Key takeaways

  • Chi-squared distribution belongs to mathematics; place it in that map before memorising details.
  • Learn the definition first, then one example that makes the definition concrete.
  • Connect Chi-squared distribution to a quantity you can measure, compute or draw — that is where exam questions come from.
  • Reproduce the core statement of Chi-squared distribution from memory before moving on to harder problems.

Reference excerpt

In probability theory and statistics, the χ2-distribution with k degrees of freedom is the distribution of a sum of the squares of k independent standard normal random variables. The chi-squared distribution χk2 is a special case of the gamma distribution and the univariate Wishart distribution. Specifically if X∼χk2 then X∼Gamma(α=k2,θ=2) (where α is the shape parameter and θ the scale parameter of the gamma distribution) and X∼W1(1,k). The scaled chi-squared distribution s2χk2 is a reparametrization of the gamma distribution and the univariate Wishart distribution. Specifically if X∼s2χk2 then X∼Gamma(α=k2,θ=2s2) and X∼W1(s2,k). The chi-squared distribution is one of the most widely used probability distributions in inferential statistics, notably in hypothesis testing and in construction of confidence intervals. This distribution is sometimes called the central chi-squared distribution, a special case of the more general noncentral chi-squared distribution. The chi-squared distribution is used in the common chi-squared tests for goodness of fit of an observed distribution to a theoretical one, the independence of two criteria of classification of qualitative data, and in finding the confidence interval for estimating the population standard deviation of a normal distribution from a sample standard deviation. Many other statistical tests also use this distribution, such as Friedman's analysis of variance by ranks.

Definitions If Z1, ..., Zk are independent, standard normal random variables, then the sum of their squares, X =∑i=1kZi2, is distributed according to the chi-squared distribution with k degrees of freedom. This is usually denoted as X ∼ χ2(k) or X ∼ χk2. The chi-squared distribution has one parameter: a positive integer k that specifies the number of degrees of freedom (the number of random variables Zi being summed).

Introduction The chi-squared distribution is used primarily in hypothesis testing, and to a lesser extent for confidence intervals for population variance when the underlying distribution is normal. Unlike more widely known distributions such as the normal distribution and the exponential distribution, the chi-squared distribution is not as often applied in the direct modeling of natural phenomena. It arises in the following hypothesis tests, among others:

Chi-squared test of independence in contingency tables Chi-squared test of goodness of fit of observed data to hypothetical distributions Likelihood-ratio test for nested models Log-rank test in survival analysis Cochran–Mantel–Haenszel test for stratified contingency tables Wald test Score test It is also a component of the definition of the t-distribution and the F-distribution used in t-tests, analysis of variance, and regression analysis. The primary reason for which the chi-squared distribution is extensively used in hypothesis testing is its relationship to the normal distribution. Many hypothesis tests use a test statistic, such as the t-statistic in a t-test. For these hypothesis tests, as the sample size, n, increases, the sampling distribution of the test statistic approaches the normal distribution (central limit theorem). Because the test statistic (such as t) is asymptotically normally distributed, provided the sample size is sufficiently large, the distribution used for hypothesis testing may be approximated by a normal distribution. Testing hypotheses using a normal distribution is well understood and relatively easy. The simplest chi-squared distribution is the square of a standard normal distribution. So wherever a normal distribution could be used for a hypothesis test, a chi-squared distribution could be used. Suppose that Z is a random variable sampled from the standard normal distribution, where the mean is 0 and the variance is 1: Z∼N(0,1). Now, consider the random variable X=Z2. The distribution of the random variable X is an example of a chi-squared distribution: X ∼ χ12. The subscript 1 indicates that this particular chi-squared distribution is constructed from only 1 standard normal distribution. A chi-squared distribution constructed by squaring a single standard normal distribution is said to have 1 degree of freedom. Thus, as the sample size for a hypothesis test increases, the distribution of the test statistic approaches a normal distribution. Just as extreme values of the normal distribution have low probability (and give small p-values), extreme values of the chi-squared distribution have low probability. An additional reason that the chi-squared distribution is widely used is that it turns up as the large sample distribution of generalized likelihood ratio tests (LRT). LRTs have several desirable properties; in particular, simple LRTs commonly provide the highest power to reject the null hypothesis (Neyman–Pearson lemma) and this leads also to optimality properties of generalised LRTs. However, the normal and chi-squared approximations are only valid asymptotically. For this reason, it is preferable to use the t distribution rather than the normal approximation or the chi-squared approximation for a small sample size. Similarly, in analyses of contingency tables, the chi-squared approximation will be poor for a small sample size, and it is preferable to use Fisher's exact test. Ramsey shows that the exact binomial test is always more powerful than the normal approximation. Lancaster shows the connections among the binomial, normal, and chi-squared distributions, as follows. De Moivre and Laplace established that a binomial distribution could be approximated by a normal distribution. Specifically they showed the asymptotic normality of the random variable χ=m−NpNpq where m is the observed number of successes in N trials, where the probability of success is p, and q=1−p. Squaring both sides of the equation gives χ2=(m−Np)2Npq Using N=Np+N(1−p), N=m+(N−m), and q=1−p, this equation can be rewritten as χ2=(m−Np)2Np+(N−m−Nq)2Nq The expression on the right is of the form that Karl Pearson would generalize to the form χ2=∑i=1n(Oi−Ei)2Ei where

… excerpt ends here. Continue reading the full article.

Illustrations

Chi-squared distribution illustration
Chi-squared distribution illustration
Chi-squared distribution: Chernoff bound for the CDF and tail (1-CDF) of a chi-squared random variable with ten degrees of freedom (k=10)
Chernoff bound for the CDF and tail (1-CDF) of a chi-squared random variable with ten degrees of freedom (k=10)
Chi-squared distribution: Approximate formula for median (from the Wilson–Hilferty transformation) compared with numerical quantile (top); and difference (blue) and relative difference (red) between numerical quantile and approximate formula (bottom). For the chi-squared distribution, only the positive integer numbers of degrees of freedom (circles) are meaningful.
Approximate formula for median (from the Wilson–Hilferty transformation) compared with numerical quantile (top); and difference (blue) and relative difference (red) between numerical quantile and approximate formula (bottom). For the chi-squared distribution, only the positive integer numbers of degrees of freedom (circles) are meaningful.

Worked examples

Example 1 — a first encounter with Chi-squared distribution

Start with the simplest possible case. Write down what Chi-squared distribution claims or describes in one sentence, then invent the smallest concrete situation in which that sentence is true. In mathematics, the smallest case is usually a single object, a single equation or a single measurement. Check that every symbol or term in your sentence has a meaning in that case.

Example 2 — changing one variable

Take the situation from Example 1 and change exactly one quantity: double it, halve it, or set it to zero. Predict what should happen to Chi-squared distribution before you calculate. Comparing your prediction with the result is the fastest way to find out whether you understand the idea or only the words.

Example 3 — an exam-style question

Typical questions about Chi-squared distribution ask you to (a) state it precisely, (b) apply it to given data, and (c) explain a limitation. Practise writing all three answers in under five minutes; the third part is what separates a full-mark answer from an average one.

Applications of Chi-squared distribution

In research
Chi-squared distribution appears in mathematics research whenever the underlying quantities have to be modelled precisely. Papers usually cite it as a starting assumption and then explore where it breaks down.
In technology and industry
Engineering practice reuses Chi-squared distribution in design rules, simulations and safety margins. Knowing the idea lets you read a specification sheet and understand why the numbers look the way they do.
In the classroom
Chi-squared distribution is common in secondary-school and first-year university syllabi. It links to neighbouring topics Exponential family distributions, Infinitely divisible probability distributions, Normal distribution, so understanding it makes those chapters shorter.
In everyday life
Look for Chi-squared distribution outside the textbook — in sport, cooking, traffic, electronics or the sky above you. An example you found yourself is remembered far longer than one you were given.
Ask Teacher Smith questions about this articleOpens your AI tutor with a question about “Chi-squared distribution” →

How to study Chi-squared distribution in 20 minutes

  1. Read the reference excerpt below once, without taking notes.
  2. Close the page and write down what Chi-squared distribution means in your own words.
  3. Compare your version with the excerpt and mark what you missed.
  4. Work through the three examples above with pen and paper.
  5. Explain Chi-squared distribution out loud to somebody else — or to Teacher Smith in the lgStudy chat.

Frequently asked questions

What is Chi-squared distribution in simple terms?

In probability theory and statistics, the χ2-distribution with k degrees of freedom is the distribution of a sum of the squares of k independent standard normal random variables. The chi-squared distribution χk2 is a special case of the gamma distribution and the univariate Wishart distribution.

Why does Chi-squared distribution matter?

Because it connects several mathematics ideas at once: it gives you a definition you can apply, a quantity you can calculate, and a way to check whether a result is plausible.

How should I study Chi-squared distribution?

Read the excerpt, restate it from memory, then work through the examples and applications listed on this page. The five-step study plan above takes about twenty minutes.

What does this page cover?

It gives you a compact reference excerpt plus original lgStudy explanations, examples, applications and study material on Chi-squared distribution.

Tags

  • Exponential family distributions
  • Infinitely divisible probability distributions
  • Normal distribution

Keep exploring