The technique of principal component analysis (PCA) is designed for this purpose (Jolliffe 2002). Given a set of points in a space, it seeks out the set of vectors along which the variation in the points is large. As an example, consider two points in a plane parameterized as \((x, y)\): the points \((0, 0)\) and \((1, 1)\). In the \(x\)-direction and in the \(y\)-direction the variation is \(1\), but over the diagonal the variation is maximal, namely \(\sqrt{2}\). The vector on the diagonal is called the principal component of the data. In richer data structures, and using a more general measure of variation among points, we can find the first component in a similar way. Moreover, we can repeat the procedure after subtracting the variation along the last found component, by projecting the data onto the plane perpendicular to that component. This allows us to build up a set of principal components of diminishing importance.