we have seen what jolliffe did with a correlation matrix. now jolliffe presents the eigenstructure of the covariance matrix of his data, rather than of the correlation matrix. in order for us to confirm his work, he must give us some additional information: the standard deviations of each variable. (recall that he did not give us the data.)

we have to figure how to recover the covariance matrix c from the correlation matrix r, when for each and every ith variable we have its standard deviation .

it’s easy: multiply the (i,j) entry in the correlation matrix r by both and

the diagonal entries , which are 1, become variances , and each off-diagonal correlation becomes a covariance. maybe it would have been more recognizable if i’d written

which says that we get from covariances to correlations by dividing by two standard deviations.

here are the standard deviations he gives:

we should expect an interesting result because of the huge variation in values. the standard deviation of the 2nd variable is 10 times that of the 6th, 20 times that of the 4th, 15 times that of the 7th, and 100-1000 times that of the others. the 2nd variable should dominate the results. that’s an understatement: it will completely overwhelm them.

back to business. my correlation matrix is r; let c be the covariance matrix. i have it to machine accuracy, but i am going to round it off in order to display it relatively compactly.

now get the eigenstructure of the covariance matrix. as before, he rounded eigenvectors to the nearest .2, and ony showed the first four eigenvectors, for the four largest eigenvalues.

here’s what i get when i select the first 4 eigenvectors and round them off to the nearest .2 .

as before, to match his numbers i need to take the negatives of the 1st and 3rd columns. i multiply by a diagonal matrix with entries and get:

this matches jolliffe’s table 3.3. it is very significant that there is a 1 in each column, and no other number larger than .2. and sure enough, the first column says use the original 2nd variable for our first new variable. you remember, that old variable with darn near all the variance.

and these four vectors bear no resemblence to the previous four eigenvectors, which we got from the correlation matrix. here’s what they were:

we get the % variation explained as before. here are the eigenvalues…

their sum is 1729.55 and their average is 216.194 .

now divide each eigenvalue by their sum, and round off, and write it as a percentage…

one new variable accounts for just about all the variation, and it’s essentially the second old variable. any of the ad hoc rules would tell us to keep exactly one new variable – and in fact that one new variable almost the same as the second old variable. this is what happens when one variance dominates.

what do we actually have, if we don’t round off so harshly? let’s look at that first columnwith no rounding…

well, with a little rounding…

that first eigenvector is still almost entirely the 2nd original data variable, with extremely small contributions from the 3rd, 6th, and 7th original variables, and even less from the others.

it’s important to realize that the transformation between correlation matrix and covariance matrix is not a nice one, and the eigenstructures can be significantly different depending on which we use. to put that more starkly, our eigenvalues and eigenvectors can be significantly different depending on which matrix we analyze.

to state it in a way that we will see again: our choice of the initial preprocessing of the data may be the most significant modeling we do.

jolliffe strongly recommends using the correlation matrix.

since we’ve seen the methods for deciding how many PCs to keep, let’s quickly run thru them as a refresher, and because jolliffe and i stated them for a correlation matrix rather than for a covariance matrix.

method 1 was to keep enough eigenvectors so that the corresponding eigenvalues accounted for 70-90% of the cumulative variation. well, the first eigenvector corresponds to 98%. keep just one, and it’s overkill.

method 2 was to keep an eigenvector if its eigenvalue was greater than .7, except that’s .7 compared to an average variance of 1. in this case the average variance is 216.194 and .7 times it is 151.336. since the 2nd eigenvalue is 15.0561, one tenth our cutoff, once more we are told to keep only the first eigenvector.

method 3 was either a scree graph or an LEV diagram, and the LEV is supposedly more appropriate for these eigenvalues. (a scree graph plots the eigenvalues, an LEV plots their logarithms, in order.)

that doesn’t do much for me. a scree graph, by contrast, would sure as heck show a “leveling off”. this doesn’t really tell us anything we didn’t already know, but, boy oh boy, it’s in our faces and impossible to miss.

finally, i can’t resist computing the broken sticks. we already have them for a stick of length 1 broken into 8 pieces; we want to change the total length from 1 to the sum of the eigenvalues, which was 1729.55.

here are the eigenvalues again:

here are the 8 expected broken lengths for total length 1…

and for total length 1729.55…

and also the running cumulative lengths of the broken pieces….

so the stick of length 1730 would have its two largest pieces with lengths 588 and 371; and the sum of the first 7 broken pieces (1702) is still less than the value of the first eigenvalue alone (1705) !

we would keep only the first eigenvector. not a surprise.

next, we will move on to a statistics in geology book (davis) and see what he has to say about PCA / FA. that will be quite a bit.

Advertisements
(function(g,$){if("undefined"!=typeof g.__ATA){
g.__ATA.initAd({collapseEmpty:'after', sectionId:26942, width:300, height:250});
g.__ATA.initAd({collapseEmpty:'after', sectionId:114160, width:300, height:250});
}})(window,jQuery);
var o = document.getElementById('crt-1576651414');
if ("undefined"!=typeof Criteo) {
var p = o.parentNode;
p.style.setProperty('display', 'inline-block', 'important');
o.style.setProperty('display', 'block', 'important');
Criteo.DisplayAcceptableAdIfAdblocked({zoneid:388248,containerid:"crt-1576651414",collapseContainerIfNotAdblocked:true,"callifnotadblocked": function () {var o = document.getElementById('crt-1576651414'); o.style.setProperty('display','none','important');o.style.setProperty('visbility','hidden','important'); }
});
} else {
o.style.setProperty('display', 'none', 'important');
o.style.setProperty('visibility', 'hidden', 'important');
}

## Leave a Reply

Fill in your details below or click an icon to log in:

You are commenting using your WordPress.com account. ( Log Out / Change )

You are commenting using your Twitter account. ( Log Out / Change )

You are commenting using your Facebook account. ( Log Out / Change )

You are commenting using your Google+ account. ( Log Out / Change )

Connecting to %s