The within-group and between-group scatter decomposition separates noise from group separation: measures variation about each group sample mean, and measures separation of those means about the overall sample mean. In linear discriminant analysis, seek a projection maximizing between-group relative to within-group variation,
Normalize by ; a Lagrange multiplier calculation gives the generalized eigenvalue problem . The leading canonical discriminant directions have the largest eigenvalues, and subsequent directions are orthogonal in the inner product. There are at most nonzero separating directions. Projecting observations onto these directions gives a low-dimensional display of group separation.
For classification, estimate the common covariance matrix by and use the linear discriminant analysis scores
where are class prior probabilities. Assign to the largest score. The same within-group scatter sets the noise scale, while between-group scatter selects the directions in which the group means separate most strongly.