Statistics formula reference

Least-Squares Normal Equation

Computes ordinary least-squares coefficients when XᵀX is invertible.

Open in editor
LaTeX\hat\beta=(X^TX)^{-1}X^Ty

Variables

  • X: design matrix
  • y: response vector
  • β̂: estimated coefficients

How to use this formula

Computes ordinary least-squares coefficients when XᵀX is invertible.

Important notes

  • Numerical software typically uses QR or SVD rather than forming the inverse.
  • Collinearity can make XᵀX singular or poorly conditioned.

Quick example

For a full-rank design matrix, β̂ minimizes ||Xβ−y||².

Applicability, worked calculation, and verification

Assumptions and domain checks

  • Numerical software typically uses QR or SVD rather than forming the inverse.
  • Preserve matrix order and verify dimension compatibility; multiplication and inversion are not generally commutative or always defined.
  • For the Least-Squares Normal Equation, identify whether each quantity is a sample statistic, population parameter, estimator, or model value, and check the method assumptions.

Worked example

Input

Output

For a full-rank design matrix, β̂ minimizes ||Xβ−y||².

Common mistakes

  • Do not reorder factors or mix incompatible dimensions when using Least-Squares Normal Equation; matrix operations are order-sensitive.
  • For the Least-Squares Normal Equation, do not interpret a descriptive statistic as a causal or population conclusion without the sampling and model assumptions.

Continue the workflow

Use Least-Squares Normal Equation in your own work

  1. Check the domainMatch the variables and assumptions to the problem before substituting values.
  2. Copy the exact notationPreserve grouping, signs, and exponents in \hat\beta=(X^TX)^{-1}X^Ty.
  3. Edit or convertOpen the expression in the LaTeX editor, then export it for your document or web page.

Review and verification

Last reviewed: 2026-07-23

Automated quality check: Kept noindex until the missing evidence is supplied.

Formula references

Frequently asked questions

What is the Least-Squares Normal Equation used for?

Computes ordinary least-squares coefficients when XᵀX is invertible.

Can I copy this formula as LaTeX?

Yes. Copy \hat\beta=(X^TX)^{-1}X^Ty or open it in the LaTeX editor.

What should I check before using it?

Confirm that each variable, unit, domain restriction, and assumption matches the problem.

Reuse, attribution, and correction

Share this reference without losing its source

Copy a citation, permanent link, Markdown link, or self-contained embed card. Each reusable format points readers back to the maintained canonical page.

Report an issue

Search the whole reference

Symbols, formulas, guides, tools and commands

Start typing to search.

move · Enter open · Esc close