validate: Function to validate output from lassosum.pipeline with...

Description Usage Arguments Details

View source: R/validate.R

Description

Function to validate output from lassosum.pipeline with external phenotype

Usage

1
2
3
4
5
6
7
8
validate(...)

## S3 method for class 'lassosum.pipeline'
validate(ls.pipeline, test.bfile = NULL,
  keep = NULL, remove = NULL, pheno = NULL, covar = NULL,
  validate.function = function(x, y) cor(x, y, use = "complete"),
  trace = 1, destandardize = F, plot = T, exclude.ambiguous = T,
  cluster = NULL, rematch = !is.null(test.bfile), ...)

Arguments

...

parameters to pass to sd.bfile

ls.pipeline

A lassosum.pipeline object

test.bfile

The (PLINK bfile for the test dataset

keep

Participants to keep (see lassosum for more details)

remove

Participants to remove

pheno

A vector of phenotype OR a data.frame with 3 columns, the first 2 columns being headed "FID" and "IID", OR a filename for such a data.frame

covar

A matrix of covariates OR a data.frame with 3 or more columns, the first 2 columns being headed "FID" and "IID", OR a filename for such a data.frame

validate.function

Function with which to perform validation

trace

Controls amount of output

destandardize

Should coefficients from lassosum be destandardized using test dataset standard deviations before being returned?

plot

Should the validation plot be plotted?

exclude.ambiguous

Should ambiguous SNPs (C/G, A/T) be excluded?

cluster

A cluster object from the parallel package for parallel computing

rematch

Forces a rematching of the ls.pipline beta's with the new .bim file

Details

Chooses the best lambda and s by validating polygenic score against an external phenotype in the testing dataset. If pheno is not specified, then the sixth column in the testing dataset .fam.fam file is used.


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