plotAnnot: Plot annotation statistics

Description Usage Arguments Details See Also Examples

Description

Using a data frame containing mapping statistics in counts, plot the data as percentages in stacked barplots.

Usage

1
2
plotAnnot(LIBS, SCOPE, TITLE, GROUP = "default", customScope = NULL,
  normalise = TRUE)

Arguments

LIBS

A table with columns named promoter, exon, intron, mapped, extracted, rdna, and tagdust, that will be passed to the mapStats function. The table will be coerced to a data frame, so that Bioconductor's DataFrame objects can be used.

SCOPE

The value on which to normalise (see the plotAnnot vignette).

TITLE

The title of the plot.

customScope

A function passed to mapStats for the definition of custom scopes

normalise

Whether to normalise or not. Default: TRUE.

Details

Stacked barplots with error bars inspired from <http://stackoverflow.com/questions/10417003/stacked-barplot-with-errorbars-using-ggplot2>. See <http://www.biomedcentral.com/1471-2164/14/665/figure/F1> for example.

See Also

loadLogs

Other smallCAGEqc annotation functions: hannot, hierarchAnnot, mapStats, ranges2annot, ranges2genes

Examples

1
2
3
4
5
6
7
8
9
example(loadMoiraiStats)
p <- plotAnnot(libs, 'qc', 'Here is the title')
print(p)
p + ggplot2::theme_bw()
ggplot2::theme_set(ggplot2::theme_bw()) ; p
plotAnnot(libs, 'qc', 'Same, non-normalised', normalise = FALSE)
# Test coercion to data frame
if(require("S4Vectors"))
  plotAnnot(DataFrame(libs), 'qc', 'Here is the title')

charles-plessy/smallCAGEqc documentation built on May 13, 2019, 3:31 p.m.