A statistical sum of squares measures variation by adding squared deviations. For observations ,
,
...,
with sample mean
, the total sum of squares is
In an analysis of variance, this total is partitioned into sums of squares associated with sources of variation and error. Dividing a source sum of squares by its degrees of freedom gives the corresponding mean square.