MTcoverage: Mitochondrial genome coverage and plots for MAlignments or...

Description Usage Arguments Details Value Examples

View source: R/MTcoverage.R

Description

We co-opted the 'coverage' method to retrieve approximate coverage depth across the mitochondrial genome in MAlignments[List] and MVRanges[list], so this function gives back what it was supposed to do (provide an Rle) and can allow for some subsetting (e.g. variant-supporting-read coverage) that may be of interest when interpreting results.

Usage

1
2
3
4
5

Arguments

x

an MAlignments or MVRanges

...

other arguments to pass to GenomicAlignments::coverage()

Details

The plotting functions can handle MAlignments or MVRanges objects directly.

plotMTCoverage does what one might expect, and plots (read or call) coverage.

plotStrandedMTCoverage does the same thing, but keeps track of which strand.

Value

an RleList (or, invisibly for plot functions, a result list)

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
library(MTseekerData)

data(RONKSreads)
MTcoverage(RONKSreads$RO_1)
plotMTCoverage(RONKSreads$RO_1)

data(RONKSvariants)
MTcoverage(RONKSvariants$RO_1)
plotMTCoverage(RONKSvariants$RO_1)

par(mfrow=c(1,2))
plotMTCoverage(RONKSreads$NKS_1)
title("Read coverage for normal kidney sample 1") 
plotMTCoverage(RONKSreads$RO_1)
title("Read coverage for renal oncocytoma sample 1") 

par(mfrow=c(1,2))
plotStrandedMTCoverage(RONKSreads$NKS_1)
title("Stranded read coverage for normal kidney sample 1") 
plotStrandedMTCoverage(RONKSreads$RO_1)
title("Stranded read coverage for renal oncocytoma sample 1") 

MTseeker documentation built on Oct. 31, 2019, 3:20 a.m.