single_LPM: Fit single_LPM

Description Usage Arguments Details Value Author(s) See Also Examples

View source: R/LPM.R

Description

Fit single_LPM.

Usage

1
single_LPM(data, X = NULL, alpha = 0.1, pi1_ = 0.1, maxiter = 1e4, tol = 1e-8, verbose = FALSE)

Arguments

data

A dataframe which contains SNP IDs and p-values for single GWASs.

X

Design matrix of functional annotations without intercept, where row and column correspond to SNP and annotation, respectively. Default is NULL.

alpha

Initial value of parameter alpha in the Beta distribution which is between 0 and 1 for GWAS. Default is 0.1.

pi1_

Initial value of parameter pi1 which is the proportion that eta equals 1 for GWAS. Default is 0.1.

maxiter

Maximum number of EM iteration. Default is 1000.

tol

Threshold to stop the EM iteration. Default is 1e-08.

verbose

Whether or not to output the estimates of parameters in stage 1. Defalut is FALSE.

Details

It requires to provide SNP IDs and p-values for single GWASs to data, while users can also provide annotation data to X. The number of SNPs for GWASs are required to be the same.

Value

List of parameter estimation, posterior and the value of lower bound of Log-likelihood.

alpha

Estimation of parameter alpha.

alpha_stage1

Estimation of parameter alpha in the Stage 1.

pi1

The posteriors that each SNP is associated with the GWAS.

pi1_stage1

The posteriors that each SNP is associated with the GWAS in Stage 1.

beta

Estimation of parameter beta for each GWAS in each pair.

LL

The value of Log-likelihood.

L_stage1_List

The value of Log-likelihood in Stage 1.

L_stage2_List

The value of Log-likelihood in Stage 2.

Author(s)

Jingsi Ming

See Also

LPM, bLPM

Examples

1
2
3
data(ExampleData)

single_LPMfit <- single_LPM(data = ExampleData$data$P1, X = ExampleData$X)

mingjingsi/LPM documentation built on April 2, 2020, 9:32 a.m.