[R] PCA loadings differ vastly!

Greg Snow Greg.Snow at imail.org
Wed Jan 14 18:48:44 CET 2009


PCA is only defined up to a multiplicative constant and different programs use different constants.  Without code or output we cannot tell if this is the case, or if something more is going on.  Try rescaling one of the answers to see if you can get the other answer, if so, then it is just a different in constants used, otherwise we need more to go on in order to help.

-- 
Gregory (Greg) L. Snow Ph.D.
Statistical Data Center
Intermountain Healthcare
greg.snow at imail.org
801.408.8111


> -----Original Message-----
> From: r-help-bounces at r-project.org [mailto:r-help-bounces at r-
> project.org] On Behalf Of gregor rolshausen
> Sent: Tuesday, January 13, 2009 8:41 AM
> To: r help
> Subject: [R] PCA loadings differ vastly!
> 
> hi, I have two questions:
> 
> #first (SPSS vs. R):
> 
> I just compared the output of different PCA routines in R (pca, prcomp,
> princomp) with results from SPSS. the loadings of the variables differ
> vastly! in SPSS the variables load constantly higher than in R.
> I made sure that both progr. use the correlation matrix as basis. I
> found the same problem with rotated values (varimax rotation and rtex=T
> rotation).
> 
> can anyone comment ?
> 
> second:
> 
> princomp(data, cor=T, rtex=T)$loadings  vs.  princomp(data, cor=T,
> rtex=F)$loadings
> 
> gives me different loadings (expected because of rotation) with one
> dataset (11 variables)
> but returns the SAME values with another dataset (3 variables).
> 
> comments ??
> 
> thanks for your time!
> 
> cheers,
> gregor
> 
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-
> guide.html
> and provide commented, minimal, self-contained, reproducible code.




More information about the R-help mailing list