calculateRPKM: Caculate RPKM for each transcripts based on exon read counts.

Description Usage Arguments Details Value Author(s) Examples

Description

Normalized expression level based on exon read counts. The default output is a vector containing RPKMs for each transcript. vector name is the transcript name. calculate the RPKMs by chromosome. If proteincodingonly=TRUE, vetor name will be set to protein name, and only output RPKMs for the protein coding transcripts.

Usage

1
calculateRPKM(bamFile, exon, proteincodingonly = TRUE, ids = NULL, ...)

Arguments

bamFile

a the input BAM file name.

exon

a dataframe of exon annotations.

proteincodingonly

if TRUE only output RPKMs for protein coding transcripts, the name of output vector will be protein id. if FALSE, output the RPKM for all transcripts.

ids

a dataframe containing gene/transcript/protein id mapping information.

...

additional arguments

Details

caculate RPKM from a BAM file based on exon read counts

Value

RPKM value for all transcripts or protein coding transcripts.

Author(s)

Xiaojing Wang

Examples

1
2
3
4
5
##test1.bam file is part of the whole bam file. 
load(system.file("extdata/refseq", "exon_anno.RData", package="customProDB"))
bamFile <- system.file("extdata/bams", "test1_sort.bam", package="customProDB")
load(system.file("extdata/refseq", "ids.RData", package="customProDB"))
RPKM <- calculateRPKM(bamFile,exon,proteincodingonly=TRUE,ids)

chambm/customProDB documentation built on May 31, 2019, 12:08 p.m.