Closed huanglukang closed 3 years ago
Rcc consists of LD for ONLY Causal SNPs. However, if you use all the SNPs and perform dmvnorm(Z, mean=rep(0,nrow(R)), R + R %% R) where Z is the Z-score of all m SNPs and R is the LD matrix (mm) then the computation cost is O(m^3) but you can show that we can compute dmvnorm(Zcc, mean=rep(0,nrow(Rcc)), Rcc + Rcc %% Rcc) / dmvnorm(Zcc, rep(0, nrow(Rcc)), Rcc)) instead, where the Rcc matrix is kk and k is the number causal SNPs for a configuration (k << m). Thus, in the second case, we only need to inverse a kk matrix which is much fast than inverting an mm matrix. This new computation was not part of original CAVIAR paper.
Thanks for your patient reply. I want to know what is the true causal SNP for the data "50_LD" and "50_Z"?
From the caviar paper, I don't see this step however. I wonder why I need to computer this not just compute dmvnorm(Zcc, mean=rep(0,nrow(Rcc)), Rcc + Rcc %*% Rcc).