As2Vs {bootSVD} | R Documentation |
Convert low dimensional bootstrap components to high dimensional bootstrap components
Description
Let B
be the number of bootstrap samples, indexed by b=1,2,...B
.
As2Vs
is a simple function converts the list of principal component (PC) matrices for the bootstrap scores to a list of principal component matrices on the original high dimensional space. Both of these lists, the input and the output of As2Vs
, are indexed by b
.
Usage
As2Vs(AsByB, V, pattern = NULL, ...)
Arguments
AsByB |
a list of the PCs matrices for each bootstrap sample, indexed by |
V |
a tall ( |
pattern |
if |
... |
passed to |
Value
a B
-length list of (p
by K
) PC matrices on the original sample coordinate space (denoted here as V^b
). This is achieved by the matrix multiplication V^b=VA^b
. Note that here, V^b
denotes the b^{th}
bootstrap PC matrix, not V
raised to the power b
. This notation is the same as the notation used in (Fisher et al., 2014).
References
Aaron Fisher, Brian Caffo, and Vadim Zipunnikov. Fast, Exact Bootstrap Principal Component Analysis for p>1 million. 2014. http://arxiv.org/abs/1405.0922
Examples
#use small n, small B, for a quick illustration
set.seed(0)
Y<-simEEG(n=100, centered=TRUE, wide=TRUE)
svdY<-fastSVD(Y)
DUt<- tcrossprod(diag(svdY$d),svdY$u)
bInds<-genBootIndeces(B=50,n=dim(DUt)[2])
bootSVD_LD_output<-bootSVD_LD(DUt=DUt,bInds=bInds,K=3,verbose=interactive())
Vs<-As2Vs(As=bootSVD_LD_output$As,V=svdY$v)
# Yields the high dimensional bootstrap PCs (left singular
# vectors of the bootstrap sample Y),
# indexed by b = 1,2...B, where B is the number of bootstrap samples