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,
BPPARAM = BiocParallel::SerialParam())
#> ℹ extracting base modifications from modBAM files
#> ⠙ 0.0 thousand records processed (16.6 /s) [61ms]
#> ⠙ 0.000 Mio. genomic positions processed (0.002 Mio./s) [1ms]
#> ℹ finding unique genomic positions...
#> ✔ finding unique genomic positions... [21ms]
#>
#> ⠙ 0.000 Mio. genomic positions processed (0.002 Mio./s) [1ms]
#> ℹ collapsed 17739 positions to 7967 unique ones
#> ✔ collapsed 17739 positions to 7967 unique ones [143ms]
#>
#> ⠙ 0.000 Mio. genomic positions processed (0.002 Mio./s) [1ms]
se <- addReadStats(se, BPPARAM = BiocParallel::SerialParam())
plotReadStats(se)