xPierTrack | R Documentation |
xPierTrack
is supposed to visualise prioritised genes using
track plot. Priority for the gene in query is displayed on the data
track and nearby genes on the annotation track. Genomic locations on
the X-axis are indicated on the X-axis, and the gene in query is
highlighted.
xPierTrack(pNode, priority.top = NULL, target.query = NULL, window = 1e+06, nearby = NULL, query.highlight = TRUE, GR.Gene = c("UCSC_knownGene", "UCSC_knownCanonical"), verbose = TRUE, RData.location = "http://galahad.well.ox.ac.uk/bigdata")
pNode |
an object of class "pNode" (or "pTarget" or "dTarget") |
priority.top |
the number of the top targets used for track plot. By default, it is NULL meaning all targets are used |
target.query |
which gene in query will be visualised. If NULL, the target gene with the top priority will be displayed |
window |
the maximum distance defining nearby genes around the target gene in query. By default it is 1e6 |
nearby |
the maximum number defining nearby genes around the target gene in query. By default it is NULL. If not NULL, it will overwrite the parameter 'window' |
query.highlight |
logical to indicate whether the gene in query will be highlighted |
GR.Gene |
the genomic regions of genes. By default, it is 'UCSC_knownGene', that is, UCSC known genes (together with genomic locations) based on human genome assembly hg19. It can be 'UCSC_knownCanonical', that is, UCSC known canonical genes (together with genomic locations) based on human genome assembly hg19. Alternatively, the user can specify the customised input. To do so, first save your RData file (containing an GR object) into your local computer, and make sure the GR object content names refer to Gene Symbols. Then, tell "GR.Gene" with your RData file name (with or without extension), plus specify your file RData path in "RData.location" |
verbose |
logical to indicate whether the messages will be displayed in the screen. By default, it sets to false for no display |
RData.location |
the characters to tell the location of built-in
RData files. See |
an object of class "ggplot", appended by an GR object called 'gr'
none
xMLrandomforest
## Not run: # Load the library library(Pi) ## End(Not run) RData.location <- "http://galahad.well.ox.ac.uk/bigdata_dev" # a) provide the SNPs with the significance info ## get lead SNPs reported in AS GWAS and their significance info (p-values) #data.file <- "http://galahad.well.ox.ac.uk/bigdata/AS.txt" #AS <- read.delim(data.file, header=TRUE, stringsAsFactors=FALSE) ImmunoBase <- xRDataLoader(RData.customised='ImmunoBase', RData.location=RData.location) gr <- ImmunoBase$AS$variants AS <- as.data.frame(GenomicRanges::mcols(gr)[, c('Variant','Pvalue')]) ## Not run: # b) perform priority analysis pNode <- xPierSNPs(data=AS, include.eQTL="JKng_mono", include.HiC='Monocytes', network="PCommonsUN_medium", restart=0.7, RData.location=RData.location) # c) track plot library(Gviz) #pdf(file="Gene_tracks.pdf", height=4, width=10, compress=TRUE) xPierTrack(pNode, RData.location=RData.location) #dev.off() xPierTrack(pNode, priority.top=1000, nearby=20, RData.location=RData.location) ## End(Not run)