View source: R/abundance_plots.R
plot_abundance | R Documentation |
Area and bar plots of sample-level relative abundance at specified taxonomic levels
plot_abundance(
pseq,
top_n = 8,
taxrank = "Phylum",
prop_of = "top_n",
type = "area",
orderby_OTU,
PALETTE
)
plot_abundance_by(
pseq,
brewerpal = "Set1",
by,
type = c("area", "bar"),
ttle = paste0("Relative phylum abundances by ", by)
)
pseq |
An object of class |
top_n |
Integer. Number of taxonomic groups to display, sorted by relative abundance |
taxrank |
Character. Taxonomic rank to display. Should be a column name of the |
prop_of |
Character. Either "top_n" or "total". Indicates whether heights of area/bars should represent the proportion out of the displayed taxonomic groups, or the out of the total. |
type |
Character. Either area or bar, specifying which type of plot. Area displays all samples left to right, whereas bars give mean abundances. |
orderby_OTU |
Character (optional). The OTU name (i.e. rowname in |
PALETTE |
Character of same length |
brewerpal |
Character. Name of RColorBrewer palette to use. |
by |
Character. Variable in |
ttle |
Character. Plot title. |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.