Message-ID: <48C780FD.70705@csse.unimelb.edu.au>
Date: 2008-09-10T08:10:37Z
From: Gad Abraham
Subject: PCA and % variance explained
In-Reply-To: <19388970.post@talk.nabble.com>
pgseye wrote:
> After doing a PCA using princomp, how do you view how much each component
> contributes to variance in the dataset. I'm still quite new to the theory of
> PCA - I have a little idea about eigenvectors and eigenvalues (these
> determine the variance explained?). Are the eigenvalues related to loadings
> in R?
You can plot the princomp object using screeplot() and you can get the
percentage of explained variance from the princomp object p using
p$sdev^2 / sum(p$sdev^2)
--
Gad Abraham
Dept. CSSE and NICTA
The University of Melbourne
Parkville 3010, Victoria, Australia
email: gabraham at csse.unimelb.edu.au
web: http://www.csse.unimelb.edu.au/~gabraham