adjust_LD {colocPropTest} | R Documentation |
adjust LD for variable sample size
Description
adjust LD for variable sample size
Usage
adjust_LD(S, LD)
Arguments
S |
coloc style dataset, with additional entries n0 and n1 which are *vectors* giving the number of cases and controls genotyped at each SNP |
LD |
matrix of LD, with dimnames given by snps in S$snp |
Value
adjusted LD matrix
Examples
library(coloc)
data(coloc_test_data)
attach(coloc_test_data)
LD=D1$LD
dimnames(LD)=list(D1$snp,D1$snp)
D1$type="cc"
D1$s=.5
D1$n1=D1$N * sample(c(0.25,.5),length(D1$snp), replace=TRUE)
D1$n0=rep(0.5*D1$N,length(D1$snp))
aLD=colocPropTest::adjust_LD(D1,LD)
LD[1:6,1:6]
aLD[1:6,1:6]
detach(coloc_test_data)
[Package colocPropTest version 0.9.1 Index]