Extracting information from factanal()
For the loadings, please use the loadings() accessor function. It is "loadings" print method that is giving you the "proportion var", not factanal(). So to use a reproducible example
example(factanal) fit <- factanal(m1, factors = 3) (ld <- loadings(fit))
Loadings:
Factor1 Factor2 Factor3
v1 0.944 0.182 0.267
v2 0.905 0.235 0.159
v3 0.236 0.210 0.946
v4 0.180 0.242 0.828
v5 0.242 0.881 0.286
v6 0.193 0.959 0.196
Factor1 Factor2 Factor3
SS loadings 1.893 1.886 1.797
Proportion Var 0.316 0.314 0.300
Cumulative Var 0.316 0.630 0.929
and look at S3method("print", "loadings") to see how it does that. (It
calculates the summary table, not extracts the values.)
On Fri, 24 Feb 2006, Smit, R. (Robin) wrote:
Dear list members, I apologize for putting this (probably) very basic question on the mailing list. I have scanned through the R website (using search) but did not found an answer. (code included below) A factor matrix is simply extracted (which can then subsequently be exported using write.table) by FACT$loadings[1:6,]. I would also like to specifically extract and export "proportion var", but unfortunately are not succesful after attempting different ways (str(FACT) did not help me). Any suggestions/comments are appreciated. Kind regards, Robin Smit
FACT <- factanal(HATCO, 2, rotation = "none") FACT
Call:
factanal(x = HATCO, factors = 2, rotation = "none")
Uniquenesses:
x1 x2 x3 x4 x6 x7
0.498 0.568 0.477 0.111 0.298 0.526
Loadings:
Factor1 Factor2
x1 0.709
x2 0.326 -0.570
x3 -0.166 0.704
x4 0.941
x6 0.829 0.118
x7 0.267 -0.634
Factor1 Factor2
SS loadings 1.778 1.743
Proportion Var 0.296 0.291
Cumulative Var 0.296 0.587
Test of the hypothesis that 2 factors are sufficient.
The chi square statistic is 3.98 on 4 degrees of freedom.
The p-value is 0.409
This e-mail and its contents are subject to the DISCLAIMER at http://www.tno.nl/disclaimer/email.html
[[alternative HTML version deleted]]
______________________________________________ R-help at stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
Brian D. Ripley, ripley at stats.ox.ac.uk Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/ University of Oxford, Tel: +44 1865 272861 (self) 1 South Parks Road, +44 1865 272866 (PA) Oxford OX1 3TG, UK Fax: +44 1865 272595