Description Usage Arguments Details Value
View source: R/plot_group_panel.R
plot_group_panel
plots boxplots of log10 relative abundances, sorted
by their median and facetted by 1 feature. In each plot, the top
cutoff
OTUs are plotted, as well as a line connecting the medians from
the base_group
. Any increases or decreases in the other groups,
relative to the base group, are colored. The main inputs are a
metadata
data.frame
, and a matrix for the OTU table. The
metadata should be in long format, with one row corresponding to one
sample. The OTU table should have the OTUs as the rows, and the samples as
the columns.
1 2 3 |
metadata |
Data frame of metadata, like the one returned by readPCL. |
otu_tab_matrix |
matrix of relative abundance, like the one returned by readPCL. Each row should be an OTU, and each column should be a sample. |
group |
The grouping variable in the metadata. |
base_group |
The reference level for the grouping variable
|
cutoff |
Only display the top |
alpha |
alpha level to conduct each hypothesis test. |
notch |
Whether to have notched boxplots. |
sep |
Character(s) separating different levels of taxonomic
classification in the OTU labels (rows of |
title |
Title for the graph. |
plot_group_panel
plots boxplots of log10 relative abundances, sorted
by their median and facetted by 1 feature. In each plot, the top
cutoff
OTUs are plotted, as well as a line connecting the medians from
the base_group
. Any increases or decreases in the other groups,
relative to the base group, are colored. The main inputs are a
metadata
data.frame
, and a matrix for the OTU table. The
metadata should be in long format, with one row corresponding to one
sample. The OTU table should have the OTUs as the rows, and the samples as
the columns.
The main inputs are a metadata
data.frame
, and a matrix
for the OTU table. The metadata should be in long format, with one row
corresponding to one sample. The OTU table should have the OTUs as the rows,
and the samples as the columns.
The coloring is determined by the results of hypothesis_test
,
which currently uses a Mann-Witney U test as implemented in
wilcox.test
.
ggplot2 plotting object. This function does not automatically display
the plot, so you need to call print
on its output to display
the plot.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.