Description Usage Arguments Details Value Examples
Draw a barplot of read totals
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 | plotReadTotals(
x,
usePlotly = FALSE,
labels,
duplicated = TRUE,
bars = c("stacked", "adjacent"),
barCols = c("red", "blue"),
expand.x = expansion(mult = c(0, 0.02)),
...
)
## S4 method for signature 'ANY'
plotReadTotals(
x,
usePlotly = FALSE,
labels,
duplicated = TRUE,
bars = c("stacked", "adjacent"),
barCols = c("red", "blue"),
expand.x = expansion(mult = c(0, 0.02)),
...
)
## S4 method for signature 'character'
plotReadTotals(
x,
usePlotly = FALSE,
labels,
duplicated = TRUE,
bars = c("stacked", "adjacent"),
barCols = c("red", "blue"),
expand.x = expansion(mult = c(0, 0.02)),
...
)
## S4 method for signature 'FastqcDataList'
plotReadTotals(
x,
usePlotly = FALSE,
labels,
duplicated = TRUE,
bars = c("stacked", "adjacent"),
barCols = c("red", "blue"),
expand.x = expansion(mult = c(0, 0.02)),
...
)
|
x |
Can be a |
usePlotly |
|
labels |
An optional named vector of labels for the file names. All filenames must be present in the names. File extensions are dropped by default. |
duplicated |
|
bars |
If |
barCols |
Colours for duplicated and unique reads. |
expand.x |
Output from |
... |
Used to pass additional attributes to theme() |
Draw a barplot of read totals using the standard ggplot2 syntax.
The raw data from readTotals
can otherwise be used to manually
create a plot.
Duplication levels are based on the value shown on FASTQC reports at the
top of the DeDuplicatedTotals plot, which is known to be inaccurate.
As it still gives a good guide as to sequence diversity it is included as
the default. This can be turned off by setting duplicated = FALSE
.
Returns a ggplot or plotly object
1 2 3 4 5 6 7 8 9 10 11 12 | # Get the files included with the package
packageDir <- system.file("extdata", package = "ngsReports")
fl <- list.files(packageDir, pattern = "fastqc.zip", full.names = TRUE)
# Load the FASTQC data as a FastqcDataList object
fdl <- FastqcDataList(fl)
# Plot the Read Totals showing estimated duplicates
plotReadTotals(fdl)
# Plot the Read Totals without estimated duplicates
plotReadTotals(fdl, duplicated = FALSE)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.