Learn R Programming

HDMFA (version 0.1.1)

KPE: Estimating the Pair of Factor Numbers via Eigenvalue Ratios Corresponding to PE

Description

The function is to estimate the pair of factor numbers via eigenvalue ratios corresponding to PE method.

Usage

KPE(X, kmax, c = 0)

Value

\(k_1\)

The estimated row factor number.

\(k_2\)

The estimated column factor number.

Arguments

X

Input an array with \(T \times p_1 \times p_2\), where \(T\) is the sample size, \(p_1\) is the the row dimension of each matrix observation and \(p_2\) is the the column dimension of each matrix observation.

kmax

The user-supplied maximum factor numbers. Here it means the upper bound of the number of row factors and column factors.

c

A constant to avoid vanishing denominators. The default is 0.

Author

Yong He, Changwei Zhao, Ran Zhao.

Details

The function KPE uses the eigenvalue-ratio idea to estimate the number of factors. First, obtain the initial estimators \(\hat{\bold{R}}\) and \(\hat{\bold{C}}\). Second, define $$\hat{\bold{Y}}_t=\frac{1}{p_2}\bold{X}_t\hat{\bold{C}}, \hat{\bold{Z}}_t=\frac{1}{p_1}\bold{X}_t^\top\hat{\bold{R}},$$ and $$\tilde{\bold{M}}_1=\frac{1}{Tp_1}\hat{\bold{Y}}_t\hat{\bold{Y}}_t^\top, \tilde{\bold{M}}_2=\frac{1}{Tp_2}\sum_{t=1}^T\hat{\bold{Z}}_t\hat{\bold{Z}}_t^\top,$$ the number of factors \(k_1\) is estimated by $$\hat{k}_1 = \arg \max_{j \leq k_{max}} \frac{\lambda_j (\tilde{\bold{M}}_1)}{\lambda _{j+1} (\tilde{\bold{M}}_1)},$$ where \(k_{max}\) is a predetermined upper bound for \(k_1\). The estimation of \(k_2\) is defined similarly with respect to \(\tilde{\bold{M}}_2\). For details, see Yu et al. (2022).

References

Yu, L., He, Y., Kong, X., & Zhang, X. (2022). Projected estimation for large-dimensional matrix factor models. Journal of Econometrics, 229(1), 201-217.

Examples

Run this code
   set.seed(11111)
   T=20;p1=20;p2=20;k1=3;k2=3
   R=matrix(runif(p1*k1,min=-1,max=1),p1,k1)
   C=matrix(runif(p2*k2,min=-1,max=1),p2,k2)
   X=array(0,c(T,p1,p2))
   Y=X;E=Y
   F=array(0,c(T,k1,k2))
   for(t in 1:T){
     F[t,,]=matrix(rnorm(k1*k2),k1,k2)
     E[t,,]=matrix(rnorm(p1*p2),p1,p2)
     Y[t,,]=R%*%F[t,,]%*%t(C)
   }
   X=Y+E
   
   KPE(X, 8, c = 0)

Run the code above in your browser using DataLab