[R] Streamlining Prcomp Data

Bjørn-Helge Mevik bhs2 at mevik.net
Fri Aug 3 12:28:33 CEST 2007


Try this

result <- summary(prcomp(USArrests))
names(result)
M <- result$importance
M[2,]

The "labels" are the dimnames of the "importance" matrix.  They only
"show up" when the matrix is printed.  If you wish, you can remove
them with dimnames(M) <- NULL.

-- 
Bjørn-Helge Mevik



More information about the R-help mailing list