PTscore: Promoter/Transcript body (PT) score

Description Usage Arguments Value Author(s) Examples

View source: R/PTscore.R

Description

PT score is calculated for coverage of promoter divided by the coverage of transcripts body. PT score will show if the signal is enriched in promoters.

Usage

1
2
3
4
5
6
7
PTscore(
  obj,
  txs,
  seqlev = intersect(seqlevels(obj), seqlevels(txs)),
  upstream = 2000,
  downstream = 500
)

Arguments

obj

an object of GAlignments

txs

GRanges of transcripts

seqlev

A vector of characters indicates the sequence levels.

upstream

numeric(1) or integer(1). Start position of promoter. Default is 2000

downstream

numeric(1) or integer(1). End position of promoter. Default is 500

Value

A object of GRanges with PT scores

Author(s)

Jianhong Ou

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
 
library(GenomicRanges)
bamfile <- system.file("extdata", "GL1.bam", 
                       package="ATACseqQC", mustWork=TRUE)
gal1 <- readBamFile(bamFile=bamfile, tag=character(0), 
                    which=GRanges("chr1", IRanges(1, 1e6)), 
                    asMates=FALSE)
library(TxDb.Hsapiens.UCSC.hg19.knownGene)
txs <- transcripts(TxDb.Hsapiens.UCSC.hg19.knownGene)
pt <- PTscore(gal1, txs)

ATACseqQC documentation built on Nov. 8, 2020, 11 p.m.