xQTLanalyze_getSentinelSnp
R/analyze.R
xQTLanalyze_getTraits.Rd
Identify trait genes using sentinel SNPs generated from xQTLanalyze_getSentinelSnp
xQTLanalyze_getTraits(
sentinelSnpDF,
detectRange = 1e+06,
tissueSiteDetail = "",
genomeVersion = "grch38",
grch37To38 = FALSE,
overlapWithEGene = TRUE,
egeneDF = NULL
)
A data.table. Better be the results from the function "xQTLanalyze_getSentinelSnp", seven columns are required, including "rsid", "chr", "position", "pValue", "maf", "beta" and "se".
A integer value. Trait genes that harbor sentinel SNPs located in the 1kb range upstream and downstream of gene. Default: 1e6 bp
(character) details of tissues in GTEx can be listed using tissueSiteDetailGTExv8
or tissueSiteDetailGTExv7
"grch38" or "grch37". Default: "grch38"
TRUE or FALSE, we recommend converting grch37 to grch38, or using a input file of grch38 directly. Package rtracklayer
is required.
TRUE(default) of FALSE. take the intersection with eGenes, egene data.frame will be automatically download from GTEx, or can be provided by the parameter egeneDF
specified the data.frame of one column of genecode ID. Default:TRUE
A data.table object of one column of gencode ID. requiring overlapWithEGene is TRUE.
A data.table object
# \donttest{
# without a customized egene file,
URL1<-"https://gitee.com/stronghoney/exampleData/raw/master/gwas/GLGC_CG0052/sentinelSnpDF.txt"
sentinelSnpDF <- data.table::fread(URL1)
traitsAll <- xQTLanalyze_getTraits(sentinelSnpDF, detectRange=1e4,"Brain - Cerebellum",
genomeVersion="grch37", grch37To38=TRUE)
# with a egene file:
egeneFile <- "http://bioinfo.szbl.ac.cn/xQTL_biolinks/xqtl_data/egeneDF.txt"
egeneDF <- data.table::fread(egeneFile)
traitsAll <- xQTLanalyze_getTraits(sentinelSnpDF, detectRange=1e4,"Brain - Cerebellum",
genomeVersion="grch37", grch37To38=TRUE, egeneDF=egeneDF)
# }