EsaBcv(Y, X = NULL, r.limit = 20, niter = 3, nRepeat = 12, only.r = F,
svd.method = "fast", center = F)c(n, p)c(n, k) if any. Default is NULL (no known predictors).
k is the number of known covariates.nRepeat times. Default is 12.fast.svd function in package corpcor to compute SVD, "propack" is using the propack.svdEsaBcv returns an obejct of class "esabcv"
The function plot plots the cross-validation results and points out the
number of factors estimated
An object of class "esabcv" is a list containing the following components:pc(n, r)rc(p, r)c(k, p).
Return NULL if the argument X is NULL.p. It's an estimate of $\mu$. Return
NULL if the argument center is False.c(nRepeat, (max.r + 1)) storing
the detailed BCV entrywise MSE of each repeat for r from 0 to max.rX is given or centering the data is required (which is essentially
adding a known covariate with all $1$), the method will first use linear regression
to estimate the coefficients of the known covariates, and then estimate the latent factors
from the residuals, whose low-rank part is actually the proportion of the latent factors
that are orthogonal to X minus the noises that are projected to X. Thus,
to make the residuals still low rank, k should be a small number. Even though the
latent factors estimated from the residuals will be biased, the estimate of the whole
signal (factor) matrix S will still be OK.ESA, plot.esabcvY <- matrix(rnorm(100), nrow = 10)
EsaBcv(Y)Run the code above in your browser using DataLab