Line 57: |
Line 57: |
| [16] "19:42912244" "19:42912441" "19:42914568" "19:42914587" "19:42914626" | | [16] "19:42912244" "19:42912441" "19:42914568" "19:42914587" "19:42914626" |
| [21] "19:42914665" "19:42914668" "19:42914682" "19:42914703" "19:42914772" | | [21] "19:42914665" "19:42914668" "19:42914682" "19:42914703" "19:42914772" |
− | > print(res$p.value) ###the P-value of the first 25 position### | + | > print(res$p.value) ###the P-value of the first 25 position### |
| [1] NA 0.311755625 NA 0.793836855 0.292744822 0.393802545 | | [1] NA 0.311755625 NA 0.793836855 0.292744822 0.393802545 |
| [7] NA 0.175761040 0.106303677 NA 0.217054457 NA | | [7] NA 0.175761040 0.106303677 NA 0.217054457 NA |
Line 63: |
Line 63: |
| [19] NA 0.364595966 NA 0.482571300 NA 0.434685495 | | [19] NA 0.364595966 NA 0.482571300 NA 0.434685495 |
| [25] NA | | [25] NA |
− |
| |
| | | |
| '''Function Detail:''' | | '''Function Detail:''' |
Line 78: |
Line 77: |
| == Meta-analysis of Gene-level Association == | | == Meta-analysis of Gene-level Association == |
| | | |
| + | '''A Simple Tutorial for Using the rareMETALS2.range function''' |
| + | |
| + | '''Example''': |
| + | res1 <- rareMETALS2.range(score.stat.file,cov.file,range="19:42906914-45854919",range.name="LDLR",test = "GRANVIL",maf.cutoff = 0.05,alternative = c("two.sided"),ix.gold = 1,out.digits = 4,callrate.cutoff = 0,hwe.cutoff = 0,max.VT = NULL) |
| + | > print(res1$res.out) |
| + | gene.name.out p.value.out statistic.out no.site.out beta1.est.out |
| + | [1,] "LDLR" "0.5575" "0.344" "332" "-0.01899" |
| + | beta1.sd.out maf.cutoff.out direction.burden.by.study.out |
| + | [1,] "0.03237" "0.05" "+-" |
| + | direction.meta.single.var.out |
| + | [1,] "++--+++-+--++-++-++---++-++-+----++-+++-++-++--+--++-++----++-++++++++---+++-------+++--++-++---++----++--+--+-+-++--+++++++-++-++-- |
| + | --+-+++----+++----++---+---+---++++---+-+--+--+++--+--+-++--++-+-+++---+++++-----++--+-++---+----++-+-++--+-+++-++-+++-+--++---+--- |
| + | +++++-+----+++ -+--++---+---++++---+++---+-+++++----+---+-+----+++-++-" |
| + | top.singlevar.pos top.singlevar.refalt top.singlevar.pval top.singlevar.af |
| + | [1,] "19:45662295" "G/A" "7.804e-15" "0.02303" |
| + | pos.ref.alt.out |
| + | [1,] "19:42907064/A/G,19:42909626/C/T,19:42909645/C/T,19:42910407/C/T,19:42910454/C/T,19:42911617/T/C,19:42911869/C/T,19:42912216/C/T,19:42912223/C/T, |
| + | 19:42912229/C/T,19:42914626/C/T,19:42914668/G/A,19:42914703/C/T,19:42914880/C/T,19:42930652/C/T,19:42930721/G/A,19:42931022/C/T,19:43013329/G/T,19:43031219/T/C, |
| + | 19:43093001/G/A,19:43093011/C/T,19:43093026/T/C,19:43097692/C/T,19:43097788/C/T,19:43243059/C/T,19:43268142/G/T,19:43411959/C/G,19:43411997/G/A,19:43420322/C/T, |
| + | 19:43420408/G/C,19:43420415/G/A,19:43420565/C/T,19:43433773/C/T,19:43439628/A/G, |
| + | |
| + | '''Function Detail:''' |
| rareMETALS2.range <- function(score.stat.file,cov.file,range,range.name,test='GRANVIL',maf.cutoff=1,alternative=c('two.sided','greater','less'), | | rareMETALS2.range <- function(score.stat.file,cov.file,range,range.name,test='GRANVIL',maf.cutoff=1,alternative=c('two.sided','greater','less'), |
| ix.gold=1,out.digits=4,callrate.cutoff=0,hwe.cutoff=0,hwe.ctrl.cutoff=0,max.VT=NULL) | | ix.gold=1,out.digits=4,callrate.cutoff=0,hwe.cutoff=0,hwe.ctrl.cutoff=0,max.VT=NULL) |
Line 96: |
Line 117: |
| | | |
| == Conditional Meta-analysis == | | == Conditional Meta-analysis == |
− |
| + | |
| + | '''A Simple Tutorial for Using the conditional.rareMETALS2.single''' |
| + | |
| + | '''Example''' |
| + | |
| + | res2<-conditional.rareMETALS2.single(candidate.variant.vec=c("19:42906914","19:45854819"), score.stat.file, cov.file,known.variant.vec=c("19:43995275","19:44047839","19:44084155"), maf.cutoff=0.05, no.boot =1000, |
| + | alternative = c("two.sided"), ix.gold = 1,out.digits = 4, callrate.cutoff = 0, hwe.cutoff = 0,p.value.known.variant.vec = NA, anno.known.variant.vec = NA,anno.candidate.variant.vec = NA) |
| + | > print(res2$res.out) |
| + | POS REF ALT N:N_CASE:N_CTRL PVALUE AF:AF_CASE:AF_CTRL BETA_EST |
| + | [1,] "19:42906914" "G" "T" "4012:2008:2004" "NaN" "0:0:0" "NaN" |
| + | [2,] "" "" "" "4012:2008:2004" NA "0:NA:NA" NA |
| + | BETA_SD DIRECTION_BY_STUDY ANNO |
| + | [1,] "Inf" "==" "N/A" |
| + | [2,] NA NA "" |
| + | POS_REF_ALT_ANNO_KNOWN |
| + | [1,] "0" |
| + | [2,] "19:43995275/NA/NA,19:44047839/C/T,19:44084155/NA/NA" |
| + | |
| + | |
| + | '''Function Detail:''' |
| + | |
| conditional.rareMETALS2.single <- function(candidate.variant.vec,score.stat.file,cov.file,known.variant.vec,maf.cutoff,no.boot=10000,alternative=c('two.sided','greater','less'), | | conditional.rareMETALS2.single <- function(candidate.variant.vec,score.stat.file,cov.file,known.variant.vec,maf.cutoff,no.boot=10000,alternative=c('two.sided','greater','less'), |
| ix.gold=1,out.digits=4,callrate.cutoff=0,hwe.cutoff=0,hwe.ctrl.cutoff=0,p.value.known.variant.vec=NA,anno.known.variant.vec=NA,anno.candidate.variant.vec=NA) | | ix.gold=1,out.digits=4,callrate.cutoff=0,hwe.cutoff=0,hwe.ctrl.cutoff=0,p.value.known.variant.vec=NA,anno.known.variant.vec=NA,anno.candidate.variant.vec=NA) |