M4.als: Fourth-order Alternating Least Square (ALS) algorithm

View source: R/M4.als.R

M4.alsR Documentation

Fourth-order Alternating Least Square (ALS) algorithm

Description

Estimating the latent factors using Alternating Least Square (ALS) algorithm based on fourth-order multi-cumulant.

Usage

M4.als(X, scale = FALSE, gamma = NULL, rh, rg, eps = 10^-8, ...)

Arguments

X

A matrix or data frame with t rows (samples) and n columns (variables).

scale

logical. If TRUE, the variance of columns of X are normalized to 1 before factor estimation.

gamma

A weighted vector, defualt to (0,0,1).

rh

The number of non-Gaussian factors.

rg

The number of Gaussian factors.

eps

The iteration error, default to 10^-8.

...

Any other parameters.

Value

Estimated factors, factor loadings and errors.

Examples

n = 100
t = 200
k = 2
par_f = list(rep(1,k),rep(0.8,k),rep(1,k),rep(Inf,k))
par_e = list(1,0,2,Inf)
rho_f = c(0.5,0.2)
par_cove = list(beta = 0.2,J = n/10,rho = 0.2,msig_e = c(1,5))
data = hofa.DGP2(n,t,k,par_f,par_e,par_cove,rho_f)$X
M4.als(data,rh = 1, rg = 1)

GuanglinHuang/hofa documentation built on Sept. 3, 2023, 7:01 a.m.