This help topic is for R version 1.6.1. For the current version of R, try https://stat.ethz.ch/R-manual/R-patched/library/mva/html/factanal.html
factanal {mva}R Documentation

Factor Analysis

Description

Perform maximum-likelihood factor analysis on a covariance matrix or data matrix.

Usage

factanal(x, factors, data = NULL, covmat = NULL, n.obs = NA,
         subset, na.action,
         start = NULL, scores = c("none", "regression", "Bartlett"),
         rotation = "varimax", control = NULL, ...)

Arguments

x

Either a formula or a numeric matrix or an object that can be coerced to a numeric matrix.

factors

The number of factors to be fitted.

data

A data frame.

covmat

A covariance matrix, or a covariance list as returned by cov.wt. Of course, correlation matrices are covariance matrices.

n.obs

The number of observations, used if covmat is a covariance matrix.

subset

A specification of the cases to be used, if x is used as a matrix or formula.

na.action

The na.action to be used if x is used as a formula.

start

NULL or a matrix of starting values, each column giving an initial set of uniquenesses.

scores

Type of scores to produce, if any. The default is none, "regression" gives Thompson's scores, "Bartlett" given Bartlett's weighted least-squares scores. Partial matching allows these names to be abbreviated.

rotation

character. "none" or the name of a function to be used to rotate the factors: it will be called with first argument the loadings matrix, and should return a list with component loadings giving the rotated loadings, or just the rotated loadings.

control

A list of control values,

nstart

The number of starting values to be tried if start = NULL. Default 1.

trace

logical. Output tracing information? Default FALSE.

lower

The lower bound for uniquenesses during optimization. Should be > 0. Default 0.005.

opt

A list of control values to be passed to optim's control argument.

rotate

a list of additional arguments for the rotation function.

...

Components of control can also be supplied as named arguments to factanal.

Details

The factor analysis model is

x = \Lambda f + e

for a p–element row-vector x, a p \times k matrix of loadings, a k–element vector of scores and a p–element vector of errors. None of the components other than x is observed, but the major restriction is that the scores be uncorrelated and of unit variance, and that the errors be independent with variances \Phi, the uniquenesses. Thus factor analysis is in essence a model for the covariance matrix of x,

\Sigma = \Lambda^\prime\Lambda + \Psi

There is still some indeterminacy in the model for it is unchanged if \Lambda is replaced by G\Lambda for any orthogonal matrix G. Such matrices G are known as rotations (although the term is applied also to non-orthogonal invertible matrices).

If covmat is supplied it is used. Otherwise x is used if it is a matrix, or a formula x is used with data to construct a model matrix, and that is used to construct a covariance matrix. (It makes no sense for the formula to have a response.) Once a covariance matrix is found or calculated from x, it is converted to a correlation matrix for analysis. The correlation matrix is returned as component correlation of the result.

The fit is done by optimizing the log likelihood assuming multivariate normality over the uniquenesses. (The maximizing loadings for given uniquenesses can be found analytically: Lawley & Maxwell (1971, p. 27).) All the starting values supplied in start are tried in turn and the best fit obtained is used. If start = NULL