Skip to content

dmitri-zaykin/Total_Decor

Repository files navigation

Total_Decor.r is a R script with sample code to compute the DOT P-value from decorrelated statistics as described in Vsevolozhskaya OA, Shi M, Hu F, Zaykin DV. DOT: "Gene-set analysis by combining decorrelated association statistics." (https://doi.org/10.1101/665133).

The example reproduces TOX3 results in Tables 7,8. The input is the vector of Z-scores and the LD matrix (two CSV files). The Z-scores can be obtained from two-sided P-values (P) as Z = sqrt(qchisq(1-P, df=1)). Next, Z must be multiplied by the sign, i.e., by direction of association of the minor allele with the trait. The LD matrix is the correlation between SNP scores, coded as (0, 1, 2), where the number reflects the number of minor alleles in a genotype. Note that it is not important that the sign for Z-scores and the allele counts are tied to the minor allele, but there must be consistency between the signs of correlations in the LD matrix and the signs of Z-scores.

ART.r is a R sample code for Augmented RTP (ART), Adaptive ART (ART-A) and RTP via Equ. 2 from Vsevolozhskaya OA, Hu F, Zaykin DV. "Detecting weak signals by combining small P-values in genetic association studies." (https://doi.org/10.1101/667238). The code uses the TOX3 data.

Check_Discrete_X.r is R code for checking equivalency of theoretical and empirical power of Tq and DOT. Empirical power is obtained via simulating regressions of Y on each Xi where X is discrete (with values 1, 2, 3) with a given correlation matrix and Y ~ Beta X + error.

Power_Tq_DOT.r script is to check equivalency of theoretical and empirical power of Tq and DOT. Empirical power is obtained via simulating regressions of Y on each Xi where X is MVN and Y ~ Beta X + error. Errors have Laplace distribution with variance 1. Correlation matrices are generated as symmetric matrices of random numbers and then converted to positive definite ones.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages