|
|
|
||||
|
|
|||||
The fautil package contains six factor analysis utilities:We will demonstrate their use with the hsb6 dataset containing 600 observations from the High School and Beyond survey. You can download this family of programs written by ATS by typing findit fautil (see How can I use the findit command to search for programs and get additional help? for more information about using findit).
- facom is used to display the communalities after using the factor command.
- faform is used to transform the factor loadings to canonical form after using factor with the ml option.
- favar computes variance of rotated factors.
- fapara computes parallel analysis for eigenvalues comparing the eigenvalues of the factor analysis with eigenvalues of randomly generated variables to assist in determining the number of factors.
use http://www.ats.ucla.edu/stat/stata/faq/hsb6, clear
factor locus concept mot read write math sci ss, pf
(obs=600)
(principal factors; 3 factors retained)
Factor Eigenvalue Difference Proportion Cumulative
------------------------------------------------------------------
1 3.26431 2.81286 1.0136 1.0136
2 0.45145 0.38003 0.1402 1.1538
3 0.07142 0.12435 0.0222 1.1760
4 -0.05293 0.00925 -0.0164 1.1596
5 -0.06218 0.04246 -0.0193 1.1403
6 -0.10464 0.02665 -0.0325 1.1078
7 -0.13129 0.08446 -0.0408 1.0670
8 -0.21575 . -0.0670 1.0000
Factor Loadings
Variable | 1 2 3 Uniqueness
-------------+-------------------------------------------
locus | 0.45240 0.23874 0.02028 0.73793
concept | 0.10452 0.42593 0.08342 0.80070
mot | 0.28873 0.42664 -0.06357 0.73057
read | 0.83028 -0.06557 0.05675 0.30312
write | 0.76978 -0.02423 -0.13154 0.38955
math | 0.79117 -0.07648 0.04239 0.36640
sci | 0.76408 -0.12571 0.14442 0.37952
ss | 0.68823 -0.06691 -0.12974 0.50503
facom
communalities
locus 0.2621
concept 0.1993
mot 0.2694
read 0.6969
write 0.6104
math 0.6336
sci 0.6205
ss 0.4950
fapara, seed(123456789)
(obs=600)
Parallel Analysis for Eigenvalues
Eigen Random Dif
c1 3.2643 0.1713 3.0930
c2 0.4515 0.1351 0.3164
c3 0.0714 0.0809 -0.0095
c4 -0.0529 0.0358 -0.0888
c5 -0.0622 -0.0331 -0.0291
c6 -0.1046 -0.0352 -0.0694
c7 -0.1313 -0.1204 -0.0109
c8 -0.2157 -0.1423 -0.0735
faplot 1 2 ld
rotate, promax(4) fac(2)
(promax rotation)
Rotated Factor Loadings
Variable | 1 2 Uniqueness
-------------+--------------------------------
locus | 0.28686 0.31079 0.73793
concept | -0.15801 0.48900 0.80070
mot | 0.01717 0.50696 0.73057
read | 0.83119 0.00359 0.30312
write | 0.74850 0.04447 0.38955
math | 0.80051 -0.01233 0.36640
sci | 0.80447 -0.07025 0.37952
ss | 0.69659 -0.01116 0.50503
favar
fac1 fac2 fac3
3.1319 0.5999 0.0714
factor locus concept mot read write math sci ss, ml
(obs=600)
number of factors adjusted to 4
Iteration 0: log likelihood = -44.498916
Iteration 1: log likelihood = -12.948465
Iteration 2: log likelihood = -7.1820399
Iteration 3: log likelihood = -.5545783
Iteration 4: log likelihood = -.4870617
Iteration 5: log likelihood = -.43017792
Iteration 6: log likelihood = -.43001638
Iteration 7: log likelihood = -.43000977
(maximum likelihood factors; 4 factors retained)
Factor Variance Difference Proportion Cumulative
------------------------------------------------------------------
1 2.65567 1.52252 0.5770 0.5770
2 1.13315 0.45423 0.2462 0.8232
3 0.67892 0.54423 0.1475 0.9707
4 0.13470 . 0.0293 1.0000
Test: 4 vs. no factors. Chi2( 32) = 1820.21, Prob > chi2 = 0.0000
Test: 4 vs. more factors. Chi2( 2) = 0.85, Prob > chi2 = 0.6534
Factor Loadings
Variable | 1 2 3 4 Uniqueness
-------------+------------------------------------------------------
locus | 0.35888 0.24486 0.24389 0.00936 0.75168
concept | 0.01945 0.12649 0.55691 -0.20927 0.62960
mot | 0.25425 0.07879 0.54745 0.15110 0.60664
read | 0.62857 0.58298 -0.01051 0.10096 0.25465
write | 1.00000 -0.00000 -0.00000 -0.00000 0.00000
math | 0.63267 0.47960 -0.02118 0.01493 0.36905
sci | 0.56916 0.60055 -0.09418 -0.16371 0.27975
ss | 0.58527 0.34705 -0.01263 0.17541 0.50614
faform
Factor Loadings in Canonical Form
1 2 3 4
r1 0.44850 0.21540 0.02576 0.01052
r2 0.10975 0.56299 0.11882 -0.16491
r3 0.30008 0.51942 -0.10106 0.15272
r4 0.83637 -0.06503 0.17560 0.10347
r5 0.86330 -0.06744 -0.48482 -0.12294
r6 0.78471 -0.07021 0.10123 0.00349
r7 0.77946 -0.13073 0.27029 -0.15024
r8 0.68355 -0.06534 -0.01858 0.14851
UCLA Researchers are invited to our Statistical Consulting Services
We recommend others to our list of Other Resources for Statistical Computing Help
These pages are Copyrighted (c) by UCLA Academic Technology Services