This function plots histograms of the various per-read summary statistics
calculated by addReadStats
.
Usage
plotReadStats(
se,
readInfoCol = "readInfo",
qcCol = "QC",
minQscore = 0,
maxEntropy = Inf,
maxFracLowConf = 1,
minReadLength = 0,
minAlignedLength = 0,
minAlignedFraction = 0
)
Arguments
- se
A
RangedSummarizedExperiment
, typically generated byaddReadStats
.- readInfoCol
A character scalar providing the name of the column in
colData
that contains read info. Can beNULL
if no such column exists.- qcCol
A character scalar providing the name of the column in
colData
that contains quality metrics (calculated bycalcReadStats
). Can beNULL
if no such column exists.- minQscore, maxEntropy, maxFracLowConf, minReadLength, minAlignedLength, minAlignedFraction
Numeric scalars representing possible threshold values used in
filterReads
, for illustration in the plot panels.
Examples
library(SummarizedExperiment)
modbamfiles <- system.file("extdata",
c("6mA_1_10reads.bam", "6mA_2_10reads.bam"),
package = "footprintR")
se <- readModBam(bamfile = modbamfiles, regions = "chr1:6940000-6955000",
modbase = "a", verbose = TRUE)
#> ℹ extracting base modifications from modBAM files
#> ℹ finding unique genomic positions...
#> ✔ finding unique genomic positions... [43ms]
#>
#> ℹ collapsed 17739 positions to 7967 unique ones
#> ✔ collapsed 17739 positions to 7967 unique ones [870ms]
#>
se <- addReadStats(se)
plotReadStats(se)