statsmodels.multivariate.factor.FactorResults

class statsmodels.multivariate.factor.FactorResults(factor)[source]

Factor results class

For result summary, scree/loading plots and factor rotations

Parameters

factor (Factor) – Fitted Factor class

uniqueness

The uniqueness (variance of uncorrelated errors unique to each variable)

Type

ndarray

communality

1 - uniqueness

Type

ndarray

loadings

Each column is the loading vector for one factor

Type

ndarray

loadings_no_rot

Unrotated loadings, not available under maximum likelihood analyis.

Type

ndarray

eigenvalues

The eigenvalues for a factor analysis obtained using principal components; not available under ML estimation.

Type

ndarray

n_comp

Number of components (factors)

Type

int

nbs

Number of observations

Type

int

fa_method

The method used to obtain the decomposition, either ‘pa’ for ‘principal axes’ or ‘ml’ for maximum likelihood.

Type

string

df

Degrees of freedom of the factor model.

Type

int

Notes

Under ML estimation, the default rotation (used for loadings) is condition IC3 of Bai and Li (2012). Under this rotation, the factor scores are iid and standardized. If G is the canonical loadings and U is the vector of uniquenesses, then the covariance matrix implied by the factor analysis is GG’ + diag(U).

Status: experimental, Some refactoring will be necessary when new

features are added.

Methods

factor_score_params([method])

compute factor scoring coefficient matrix

factor_scoring([endog, method, transform])

factor scoring: compute factors for endog

fitted_cov()

Returns the fitted covariance matrix.

get_loadings_frame([style, sort_, …])

get loadings matrix as DataFrame or pandas Styler

load_stderr()

The standard errors of the loadings.

plot_loadings([loading_pairs, plot_prerotated])

Plot factor loadings in 2-d plots

plot_scree([ncomp])

Plot of the ordered eigenvalues and variance explained for the loadings

rotate(method)

Apply rotation, inplace modification of this Results instance

summary()

uniq_stderr([kurt])

The standard errors of the uniquenesses.