coverageRates {ribosomeProfilingQC} | R Documentation

## Calculate coverage rate

### Description

Coverage is a measure as percentage of position with reads along the CDS. Coverage rate calculate coverage rate for RPFs and mRNAs in gene level. Coverage will be calculated based on best P sites for RPFs and 5'end for RNA-seq.

### Usage

    coverageRates(cvgs, RPFsampleOrder, mRNAsampleOrder)

### Arguments

`cvgs` | Output of coverageDepth
`RPFsampleOrder, mRNAsampleOrder` | Sample order of RPFs and mRNAs. The parameters are used to make sure that the order of RPFs and mRNAs in cvgs is corresponding samples.

### Value

A list with coverage rate.

### Examples

    path <- system.file("extdata", package="ribosomeProfilingQC")
    RPFs <- dir(path, "RPF.*?\\.[12].bam$", full.names=TRUE)
    gtf <- file.path(path, "Danio_rerio.GRCz10.91.chr1.gtf.gz")
    cvgs <- coverageDepth(RPFs[1], gtf=gtf, level="gene")
    cr <- coverageRates(cvgs)

[Package ribosomeProfilingQC version 1.6.1 Index]