pgs: Computes polygenic scores as a genotype matrix multiplied by...

Description Usage Arguments Details Value Note

View source: R/pgs.R

Description

Note that this is a low-level command. For applying estimated betas to new bfiles, refer to https://github.com/tshmak/lassosum#apply-validated-betas-to-new-data

Usage

1
2
3
4
5
6
7
8
pgs(bfile, weights, ...)

.pgs(...)

## Default S3 method:
.pgs(weights, bfile, keep = NULL, extract = NULL,
  exclude = NULL, remove = NULL, chr = NULL, cluster = NULL,
  trace = 0, sparse = TRUE)

Arguments

bfile

A plink bfile stem

weights

The weights for the SNPs (β)

keep

samples to keep (see parseselect)

extract

SNPs to extract (see parseselect)

exclude

SNPs to exclude (see parseselect)

remove

samples to remove (see parseselect)

chr

a vector of chromosomes

cluster

A cluster object from the parallel package. For parallel processing.

trace

Level of output

sparse

Assumes sparse weights matrix

Details

A function to calculate where X is the genotype matrix in the plink bfile.

Value

A matrix of Polygenic Scores

Note


tshmak/lassosum documentation built on Sept. 24, 2020, 9:41 a.m.