12.07.2015 Views

Jolliffe I. Principal Component Analysis (2ed., Springer, 2002)(518s)

Jolliffe I. Principal Component Analysis (2ed., Springer, 2002)(518s)

Jolliffe I. Principal Component Analysis (2ed., Springer, 2002)(518s)

SHOW MORE
SHOW LESS
  • No tags were found...

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

A.1. Numerical Calculation of <strong>Principal</strong> <strong>Component</strong>s 411There is one problem with shifting the origin that has not yet beenmentioned. This is the fact that to choose efficiently the values of ρ thatdetermine the shifts, we need some preliminary idea of the eigenvaluesof T. This preliminary estimation can be achieved by using the methodof bisection, which in turn is based on the Sturm sequence property oftridiagonal matrices. Details will not be given here (see Wilkinson, 1965,pp. 300–302), but the method provides a quick way of finding approximatevalues of the eigenvalues of a tridiagonal matrix. In fact, bisection could beused to find the eigenvalues to any required degree of accuracy, and inverseiteration implemented solely to find the eigenvectors.Two major collections of subroutines for finding eigenvalues and eigenvectorsfor a wide variety of classes of matrix are the EISPACK package(Smith et al., 1976), which is distributed by IMSL, and parts of the NAGlibrary of subroutines. In both of these collections, there are recommendationsas to which subroutines are most appropriate for various types ofeigenproblem. In the case where only a few of the eigenvalues and eigenvectorsof a real symmetric matrix are required (corresponding to finding justa few of the PCs for a covariance or correlation matrix) both EISPACKand NAG recommend transforming to tridiagonal form using Householdertransformations, and then finding eigenvalues and eigenvectors using bisectionand inverse iteration respectively. NAG and EISPACK both base theirsubroutines on algorithms published in Wilkinson and Reinsch (1971), asdo the ‘Numerical Recipes’ for eigensystems given by Press et al. (1992,Chapter 11).The QL AlgorithmIf all of the PCs are required, then methods other than those just describedmay be more efficient. For example, both EISPACK and NAG recommendthat we should still transform the covariance or correlation matrix to tridiagonalform, but at the second stage the so-called QL algorithm should nowbe used, instead of bisection and inverse iteration. Chapter 8 of Wilkinson(1965) spends over 80 pages describing the QR and LR algorithms (whichare closely related to the QL algorithm), but only a very brief outline willbe given here.The basic idea behind the QL algorithm is that any non-singular matrixT can be written as T = QL, where Q is orthogonal and L is lowertriangular. (The QR algorithm is similar, except that T is written insteadas T = QR, where R is upper triangular, rather than lower triangular.) IfT 1 = T and we write T 1 = Q 1 L 1 , then T 2 is defined as T 2 = L 1 Q 1 .Thisis the first step in an iterative procedure. At the next step, T 2 is writtenas T 2 = Q 2 L 2 and T 3 is defined as T 3 = L 2 Q 2 . In general, T r is writtenas Q r L r and T r+1 is then defined as L r Q r ,r=1, 2, 3,..., where Q 1 , Q 2 ,Q 3 ,... are orthogonal matrices, and L 1 , L 2 , L 3 ,... are lower triangular. Itcan be shown that T r converges to a diagonal matrix, with the eigenvalues

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!