bed_fastGrmEVs: Computation of the k leading eigenvectors of the genomic...

View source: R/locStra.r

bed_fastGrmEVsR Documentation

Computation of the k leading eigenvectors of the genomic relationship matrix, defined in Yang et al. (2011), directly from a bed+bim+fam file.

Description

Computation of the k leading eigenvectors of the genomic relationship matrix, defined in Yang et al. (2011), directly from a bed+bim+fam file.

Usage

bed_fastGrmEVs(f, k, robust = TRUE, q = 2)

Arguments

f

The filename of the bed file (including its extension). The bim and fam files need to be in the same folder and have the same base filename.

k

The number of leading eigenvectors.

robust

Flag to indicate if the classic (robust=FALSE) or robust (robust=TRUE) version of the genomic relationship matrix is desired. Default is robust=TRUE.

q

The number of power iteration steps (default is q=2).

Value

The k leading eigenvectors of the genomic relationship matrix of m as a column matrix.

References

Yang J, Lee SH, Goddard ME, Visscher PM (2011). GCTA: a tool for genome-wide complex trait analysis. Am J Hum Genet, 88(1):76-82.

N. Halko, P.G. Martinsson, and J.A. Tropp (2011). Finding Structure with Randomness: Probabilistic Algorithms for Constructing Approximate Matrix Decompositions. SIAM Review: 53(2), pp. 217–288.

F. Prive, M. Blum, H. Aschard, B.J. Vilhjalmsson (2022). bigsnpr: Analysis of Massive SNP Arrays. https://cran.r-project.org/package=bigsnpr

Examples

require(locStra)


locStra documentation built on April 13, 2022, 1:07 a.m.