|
a |
|
b/man/shaPRS_adjust.Rd |
|
|
1 |
% Generated by roxygen2: do not edit by hand |
|
|
2 |
% Please edit documentation in R/shaPRS.R |
|
|
3 |
\name{shaPRS_adjust} |
|
|
4 |
\alias{shaPRS_adjust} |
|
|
5 |
\title{Create lFDR corrected Q-test statistics for each SNP} |
|
|
6 |
\usage{ |
|
|
7 |
shaPRS_adjust( |
|
|
8 |
inputData, |
|
|
9 |
rho = 0, |
|
|
10 |
thresholds = vector(), |
|
|
11 |
discardAmbiguousSNPs = T |
|
|
12 |
) |
|
|
13 |
} |
|
|
14 |
\arguments{ |
|
|
15 |
\item{inputData}{summary statistics table that has header with the following columns: SNP CHR BP Beta_A SE_A A1.x A2.x Beta_B SE_B A1.y A2.y} |
|
|
16 |
|
|
|
17 |
\item{rho}{estimate of correlation between studies due to shared subjects. 0 for no overlap and 1 for complete overlap. default: 0. Obtain this from shaPRS_rho()} |
|
|
18 |
|
|
|
19 |
\item{thresholds}{vector of thresholds to be used to create list of SNPs (default empty)} |
|
|
20 |
|
|
|
21 |
\item{discardAmbiguousSNPs}{(optional) if ambiguous SNPs (G/C and A/T) should be discarded (default TRUE)} |
|
|
22 |
} |
|
|
23 |
\value{ |
|
|
24 |
returns object with two fields, (1) lFDRTable: a 3 column file with the following signature SNP lFDR Qval (2) hardThresholds list of SNPids that failed the heterogeneity test at each threshold |
|
|
25 |
} |
|
|
26 |
\description{ |
|
|
27 |
it performs: |
|
|
28 |
(1) modified Cochran's Q-test which optionally adjusts for overlapping controls |
|
|
29 |
(2) lFDR estimation on the p-values from the above Cochran's Q-test |
|
|
30 |
(3) lists SNPs that fail the heterogeneity test at specified thresholds (optional) |
|
|
31 |
} |
|
|
32 |
\examples{ |
|
|
33 |
inputDataLoc <- system.file("extdata", "shapersToydata.txt", package = "shaPRS") |
|
|
34 |
inputData= read.table(inputDataLoc, header = TRUE) |
|
|
35 |
results = shaPRS_adjust(inputData, thresholds=c(0.5,0.99)) |
|
|
36 |
|
|
|
37 |
} |