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 b. Each element of this list should be a (n by K) matrix, where K is the number of PCs of interest, and n is the sample size.

V

a tall (p by n) matrix containing the PCs of the original sample, where n is sample size, and p is sample dimension.

pattern

if V is a class ff object, the returned value will also be a class ff object. pattern is passed to ff in creation of the output.

...

passed to mclapply.

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

[Package bootSVD version 1.1 Index]