Factor Analysis Class
Definition
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 9.0.4
public class FactorAnalysis : TransformationModel<double>
- Inheritance
- Object → Model → TransformationModel<Double> → FactorAnalysis
Remarks
Use the FactorAnalysis class to perform a factor analysis on a set of variables or directly on a correlation matrix or a covariance matrix.
The number of factors can be set in advance, or may be determined automatically based on the eigenvalues of the correlation matrix.
The ExtractionMethod property determines the algorithm for determining the factors. It is of type FactorExtractionMethod. A variety of factor extraction methods is available: principal components, principal axis, maximum likelihood, unweighted least squares (ULS), generalized least squares (GLS), alpha factoring, and image factoring. Several extraction methods use an iterative process. You can set the tolerance and iteration limit for this phase using the ExtractionPhaseTolerance and ExtractionPhaseMaxIterations properties, respectively.
After the factors have been determined, they may be rotated. Again, a number of methods are available, including orthogonal (varimax, equamax, quartimax) and oblique (promax). The default is varimax. The method is specified by the RotationMethod property, which is of type FactorRotationMethod. Factor rotation is usually an iterative process. You can set the tolerance and iteration limit for this phase using the RotationPhaseTolerance and RotationPhaseMaxIterations properties, respectively.
Once the analysis is complete, the Communalities property contains the communalities of the variables, while the Uniqueness property contains its complement. The LoadingsMatrix property returns a matrix whose columns are the correlations of the factor with the corresponding variables before rotation. The FactorScoreCoefficientMatrix contains the coefficients of the factor scores.
Depending on whether the rotation is orthogonal or oblique, a number of properties are available. For orthogonal rotations, the RotatedLoadingsMatrix returns the loadings matrix after rotation. For oblique rotations, the PatternMatrix property contains the matrix of contributions of each factor to the variance of each variable. The StructureMatrix contains the matrix of correlations between factors and variables. For orthogonal rotations, both these matrices are equal and the same as the RotatedLoadingsMatrix.
Constructors
Factor | Constructs a new factor analysis object. |
Factor | Constructs a new factor analysis object. |
Factor | Constructs a new FactorAnalysis. |
Factor | Constructs a new FactorAnalysis. |
Factor | Constructs a new factor analysis object. |
Properties
Base |
Gets an index containing the keys of the columns
that are required inputs to the model.
(Inherited from Model) |
Communalities | Gets a vector containing the proportion of the common variance of each variable associated with the factors. |
Computed |
Gets whether the model has been computed.
(Inherited from Model) Obsolete. |
Cumulative | Gets a vector containing the variance explained by each factor. |
Data |
Gets an object that contains all the data used as input to the model.
(Inherited from Model) |
Eigenvalues | Gets a vector containing the eigenvalues corresponding to the factors. |
Extraction | Gets or sets the method for extracting factors. |
Extraction | Gets or sets the maximum number of iterations allowed for factor extraction. |
Extraction | Gets or sets the difference in successive approximations of the communalities that signals convergence when extracting the factors. |
Factor | Gets a matrix that contains the correlations between the factors. |
Factor | Gets or sets a value that specifies how the number of factors is determined. |
Factor | Gets the matrix of factor score coefficients. |
Factor | Gets or sets the method for computing factor score coefficients. |
Factor | Gets or sets the threshold value for automatically determining the number of factors to be extracted. |
Factor | Gets the matrix that transforms the original factors to the rotated factors. |
Features |
Gets a matrix that contains the features.
(Inherited from TransformationModel<T>) |
Fitted |
Gets whether the model has been computed.
(Inherited from Model) |
Initial | Gets a vector containing the initial values of the communalities. |
Input |
Gets the schema for the features used for fitting the model.
(Inherited from Model) |
IsOblique | Gets whether the factor rotation is oblique. |
IsOrthogonal | Gets whether the factor rotation is orthogonal. |
Loadings | Gets the matrix of unrotated factor loadings. |
Max |
Gets or sets the maximum degree of parallelism enabled by this instance.
(Inherited from Model) |
Method | Gets or sets whether the factor analysis is based on a correlation matrix or a covariance matrix. |
Model |
Gets the collection of variables used in the model.
(Inherited from Model) |
Number | Gets or sets the number of factors to be extracted. |
Number |
Gets the number of observations the model is based on.
(Inherited from Model) |
Parallel |
Gets or sets an object that specifies how the calculation of the model should be parallelized.
(Inherited from Model) |
Pattern | Gets the matrix of contributions of each factor to the variance of each variable. |
Promax | Gets or sets the exponent used in promax rotation. |
Rotated | Gets the matrix of rotated factor loadings, the correlations between factors and variables after rotation. |
Rotation | Gets or sets the method for rotating factors. |
Rotation | Gets or sets the maximum number of iterations allowed for factor rotation. |
Rotation | Gets or sets the threshold value of the convergence measure for factor rotations. |
Standardize | Gets or sets whether the variables should be standardized before the clustering is computed. |
Status |
Gets the status of the model, which determines which information is available.
(Inherited from Model) |
Structure | Gets the matrix of the correlations between factors and variables. |
Supports |
Indicates whether the model supports case weights.
(Inherited from Model) |
Uniqueness | Gets a vector containing the proportion of the common variance of each variable not associated with the factors. |
Variance | Gets a vector containing the variance explained by each factor. |
Weights |
Gets or sets the actual weights.
(Inherited from Model) |
Methods
Compute() |
Computes the model.
(Inherited from Model) Obsolete. |
Compute( |
Computes the model.
(Inherited from Model) Obsolete. |
Equals | Determines whether the specified object is equal to the current object. (Inherited from Object) |
Finalize | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object) |
Fit() |
Fits the model to the data.
(Inherited from Model) |
Fit( |
Fits the model to the data.
(Inherited from Model) |
Fit |
Computes the factor analysis.
(Overrides Model.FitCore(ModelInput, ParallelOptions)) |
Get | Serves as the default hash function. (Inherited from Object) |
Get | Gets a read-only collection of the factors after rotation. |
Get | Gets the Type of the current instance. (Inherited from Object) |
Get | Gets a read-only collection of the factors before rotation. |
Inverse |
Applies the inverse transformation to a set of observations.
(Inherited from TransformationModel<T>) |
Inverse |
Applies the inverse transformation to a set of observations.
(Inherited from TransformationModel<T>) |
Inverse |
Applies the inverse transformation to a set of observations.
(Inherited from TransformationModel<T>) |
Inverse |
Applies the inverse transformation to a set of observations.
(Overrides TransformationModel<T>.InverseTransformInto(Vector<Double>, Vector<Double>)) |
Memberwise | Creates a shallow copy of the current Object. (Inherited from Object) |
Reset |
Clears all fitted model parameters.
(Inherited from Model) Obsolete. |
Reset |
Clears all fitted model parameters.
(Inherited from Model) |
Set |
Uses the specified data frame as the source for all input variables.
(Inherited from Model) |
Summarize() |
Returns a string containing a human-readable summary of the object using default options.
(Inherited from Model) |
Summarize( |
Returns a string containing a human-readable summary of the object using the specified options.
(Inherited from Model) |
ToString | Returns a string that represents the current object. (Inherited from Model) |
Transform( |
Applies the transformation to a set of observations.
(Inherited from TransformationModel<T>) |
Transform( |
Applies the transformation to a single observation.
(Inherited from TransformationModel<T>) |
Transform |
Applies the transformation to a set of observations.
(Inherited from TransformationModel<T>) |
Transform |
Applies the transformation to a single observation.
(Overrides TransformationModel<T>.TransformInto(Vector<Double>, Vector<Double>)) |