Learn R Programming

GrFA (version 0.2.2)

FA: Factor Analysis

Description

Performs Factor Analysis using Principal Component Analysis (PCA) to extract factors and loadings.

Usage

FA(X, r)

Value

A list containing:

F

The estimated factors matrix of dimension \(T \times r\).

L

The estimated factor loadings matrix of dimension \(N \times r\).

Arguments

X

The observation data matrix of dimension \(T \times N\).

r

The number of factors to estimate.

Author

Jiaqi Hu

References

Bai, J., & Ng, S. (2002). Determining the number of factors in approximate factor models. Econometrica, 70(1), 191-221.

Examples

Run this code
X <- matrix(rnorm(100*20), 100, 20)
res <- FA(X, r = 2)
head(res$F)
head(res$L)

Run the code above in your browser using DataLab