Statistical method
Factor analysis is a statistical method used to describe variability among observed, correlated variables in terms of a potentially lower number of unobserved variables called factors. For example, it is possible that variations in six observed variables mainly reflect the variations in two unobserved (underlying) variables. Factor analysis searches for such joint variations in response to unobserved latent variables. The observed variables are modelled as linear combinations of the potential factors plus "error" terms, hence factor analysis can be thought of as a special case of errors-in-variables models.
Simply put, the factor loading of a variable quantifies the extent to which the variable is related to a given factor.
A common rationale behind factor analytic methods is that the information gained about the interdependencies between observed variables can be used later to reduce the set of variables in a dataset. Factor analysis is commonly used in psychometrics, personality psychology, biology, marketing, product management, operations research, finance, and machine learning. It may help to deal with data sets where there are large numbers of observed variables that are thought to reflect a smaller number of underlying/latent variables. It is one of the most commonly used inter-dependency techniques and is used when the relevant set of variables shows a systematic inter-dependence and the objective is to find out the latent factors that create a commonality.
Statistical model.
Definition.
The model attempts to explain a set of formula_1 observations in each of formula_2 individuals with a set of formula_3 "common factors" (formula_4) where there are fewer factors per unit than observations per unit ( ;math ;k). Each individual has formula_3 of their own common factors, and these are related to the observations via the factor "loading matrix" (formula_6), for a single observation, according to
 formula_7
where
In matrix notation
 formula_21
where observation matrix formula_22, loading matrix formula_23, factor matrix formula_24, error term matrix formula_25 and mean matrix formula_26 whereby the formula_20th element is simply formula_28.
Also we will impose the following assumptions on formula_29:
Suppose formula_37. Then
 formula_38
and therefore, from conditions 1 and 2 imposed on formula_29 above, formula_40 and formula_41, giving
 formula_42
or, setting formula_43,
 formula_44
For any orthogonal matrix formula_45, if we set formula_46 and formula_47, the criteria for being factors and factor loadings still hold. Hence a set of factors and factor loadings is unique only up to an orthogonal transformation.
Example.
Suppose a psychologist has the hypothesis that there are two kinds of intelligence, "verbal intelligence" and "mathematical intelligence", neither of which is directly observed. Evidence for the hypothesis is sought in the examination scores from each of 10 different academic fields of 1000 students. If each student is chosen randomly from a large population, then each student's 10 scores are random variables. The psychologist's hypothesis may say that for each of the 10 academic fields, the score averaged over the group of all students who share some common pair of values for verbal and mathematical "intelligences" is some constant times their level of verbal intelligence plus another constant times their level of mathematical intelligence, i.e., it is a linear combination of those two "factors". The numbers for a particular subject, by which the two kinds of intelligence are multiplied to obtain the expected score, are posited by the hypothesis to be the same for all intelligence level pairs, and are called "factor loading" for this subject. For example, the hypothesis may hold that the predicted average student's aptitude in the field of astronomy is
{10 × the student's verbal intelligence} + {6 × the student's mathematical intelligence}.
The numbers 10 and 6 are the factor loadings associated with astronomy. Other academic subjects may have different factor loadings.
Two students assumed to have identical degrees of verbal and mathematical intelligence may have different measured aptitudes in astronomy because individual aptitudes differ from average aptitudes (predicted above) and because of measurement error itself. Such differences make up what is collectively called the "error" — a statistical term that means the amount by which an individual, as measured, differs from what is average for or predicted by his or her levels of intelligence (see errors and residuals in statistics).
The observable data that go into factor analysis would be 10 scores of each of the 1000 students, a total of 10,000 numbers. The factor loadings and levels of the two kinds of intelligence of each student must be inferred from the data.
Mathematical model of the same example.
In the following, matrices will be indicated by indexed variables. "Subject" indices will be indicated using letters formula_48,formula_49 and formula_50, with values running from formula_51 to formula_1 which is equal to formula_53 in the above example. "Factor" indices will be indicated using letters formula_1, formula_55 and formula_56, with values running from formula_51 to formula_3 which is equal to formula_59 in the above example. "Instance" or "sample" indices will be indicated using letters formula_9,formula_15 and formula_3, with values running from formula_51 to formula_64. In the example above, if a sample of formula_65 students participated in the formula_66 exams, the formula_9th student's score for the formula_48th exam is given by formula_69. The purpose of factor analysis is to characterize the correlations between the variables formula_70 of which the formula_69 are a particular instance, or set of observations. In order for the variables to be on equal footing, they are normalized into standard scores formula_72:
formula_73
where the sample mean is:
formula_74
and the sample variance is given by:
formula_75
The factor analysis model for this particular sample is then:
formula_76
or, more succinctly:
formula_77
where
In matrix notation, we have
formula_85
Observe that by doubling the scale on which "verbal intelligence"—the first component in each column of formula_29—is measured, and simultaneously halving the factor loadings for verbal intelligence makes no difference to the model. Thus, no generality is lost by assuming that the standard deviation of the factors for verbal intelligence is formula_51. Likewise for mathematical intelligence. Moreover, for similar reasons, no generality is lost by assuming the two factors are uncorrelated with each other. In other words:
formula_88
where formula_89 is the Kronecker delta (formula_90 when formula_91 and formula_51 when formula_93).The errors are assumed to be independent of the factors:
formula_94
Since any rotation of a solution is also a solution, this makes interpreting the factors difficult. See disadvantages below. In this particular example, if we do not know beforehand that the two types of intelligence are uncorrelated, then we cannot interpret the two factors as the two different types of intelligence. Even if they are uncorrelated, we cannot tell which factor corresponds to verbal intelligence and which corresponds to mathematical intelligence without an outside argument.
The values of the loadings formula_95, the averages formula_96, and the variances of the "errors" formula_31 must be estimated given the observed data formula_98 and formula_29 (the assumption about the levels of the factors is fixed for a given formula_29). 
The "fundamental theorem" may be derived from the above conditions:
formula_101
The term on the left is the formula_102-term of the correlation matrix (a formula_103 matrix derived as the product of the formula_104 matrix of standardized observations with its transpose) of the observed data, and its formula_1 diagonal elements will be formula_51s. The second term on the right will be a diagonal matrix with terms less than unity. The first term on the right is the "reduced correlation matrix" and will be equal to the correlation matrix except for its diagonal values which will be less than unity. These diagonal elements of the reduced correlation matrix are called "communalities" (which represent the fraction of the variance in the observed variable that is accounted for by the factors):
formula_107
The sample data formula_108 will not exactly obey the fundamental equation given above due to sampling errors, inadequacy of the model, etc. The goal of any analysis of the above model is to find the factors formula_109 and loadings formula_82 which give a "best fit" to the data. In factor analysis, the best fit is defined as the minimum of the mean square error in the off-diagonal residuals of the correlation matrix:
formula_111
This is equivalent to minimizing the off-diagonal components of the error covariance which, in the model equations have expected values of zero. This is to be contrasted with principal component analysis which seeks to minimize the mean square error of all residuals. Before the advent of high-speed computers, considerable effort was devoted to finding approximate solutions to the problem, particularly in estimating the communalities by other means, which then simplifies the problem considerably by yielding a known reduced correlation matrix. This was then used to estimate the factors and the loadings. With the advent of high-speed computers, the minimization problem can be solved iteratively with adequate speed, and the communalities are calculated in the process, rather than being needed beforehand. The MinRes algorithm is particularly suited to this problem, but is hardly the only iterative means of finding a solution.
If the solution factors are allowed to be correlated (as in 'oblimin' rotation, for example), then the corresponding mathematical model uses skew coordinates rather than orthogonal coordinates.
Geometric interpretation.
The parameters and variables of factor analysis can be given a geometrical interpretation. The data (formula_108), the factors (formula_109) and the errors (formula_114) can be viewed as vectors in an formula_64-dimensional Euclidean space (sample space), represented as formula_116, formula_117 and formula_118 respectively. Since the data are standardized, the data vectors are of unit length (formula_119). The factor vectors define an formula_3-dimensional linear subspace (i.e. a hyperplane) in this space, upon which the data vectors are projected orthogonally. This follows from the model equation 
formula_121
and the independence of the factors and the errors: formula_122. In the above example, the hyperplane is just a 2-dimensional plane defined by the two factor vectors. The projection of the data vectors onto the hyperplane is given by 
formula_123
and the errors are vectors from that projected point to the data point and are perpendicular to the hyperplane. The goal of factor analysis is to find a hyperplane which is a "best fit" to the data in some sense, so it doesn't matter how the factor vectors which define this hyperplane are chosen, as long as they are independent and lie in the hyperplane. We are free to specify them as both orthogonal and normal (formula_124) with no loss of generality. After a suitable set of factors are found, they may also be arbitrarily rotated within the hyperplane, so that any rotation of the factor vectors will define the same hyperplane, and also be a solution. As a result, in the above example, in which the fitting hyperplane is two dimensional, if we do not know beforehand that the two types of intelligence are uncorrelated, then we cannot interpret the two factors as the two different types of intelligence. Even if they are uncorrelated, we cannot tell which factor corresponds to verbal intelligence and which corresponds to mathematical intelligence, or whether the factors are linear combinations of both, without an outside argument.
The data vectors formula_116 have unit length. The entries of the correlation matrix for the data are given by formula_126. The correlation matrix can be geometrically interpreted as the cosine of the angle between the two data vectors formula_116 and formula_128. The diagonal elements will clearly be formula_51s and the off diagonal elements will have absolute values less than or equal to unity. The "reduced correlation matrix" is defined as 
formula_130.
The goal of factor analysis is to choose the fitting hyperplane such that the reduced correlation matrix reproduces the correlation matrix as nearly as possible, except for the diagonal elements of the correlation matrix which are known to have unit value. In other words, the goal is to reproduce as accurately as possible the cross-correlations in the data. Specifically, for the fitting hyperplane, the mean square error in the off-diagonal components 
formula_131
is to be minimized, and this is accomplished by minimizing it with respect to a set of orthonormal factor vectors. It can be seen that 
formula_132
The term on the right is just the covariance of the errors. In the model, the error covariance is stated to be a diagonal matrix and so the above minimization problem will in fact yield a "best fit" to the model: It will yield a sample estimate of the error covariance which has its off-diagonal components minimized in the mean square sense. It can be seen that since the formula_133 are orthogonal projections of the data vectors, their length will be less than or equal to the length of the projected data vector, which is unity. The square of these lengths are