mm_nearestGene | R Documentation |
Annotate peaks using nearest gene mode, which means every peak only have one related gene.
mm_nearestGene(peak_GR, Txdb, reportGeneInfo = FALSE, verbose = TRUE, ...)
peak_GR |
peak GRange with a column named feature_id representing you peak name |
Txdb |
Txdb |
reportGeneInfo |
whether you want to report full gene info |
verbose |
whether you want to report detailed running message |
... |
additional arguments in distanceToNearest |
Granges object with annotated info
if (require(TxDb.Athaliana.BioMart.plantsmart28)) {
Txdb <- TxDb.Athaliana.BioMart.plantsmart28
seqlevels(Txdb) <- paste0("Chr", c(1:5, "M", "C"))
peak_path <- system.file("extdata", "ChIP.bed.gz", package = "FindIT2")
peak_GR <- loadPeakFile(peak_path)
peakAnno <- mm_nearestGene(peak_GR, Txdb)
peakAnno
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.