plot_heatmap {omu} | R Documentation |
Create a heatmap
Description
Takes a metabolomics count data frame and creates a heatmap. It is recommended to either subset, truncate, or agglomerate by metabolite metadata to improve legibility.
Usage
plot_heatmap(
count_data,
metadata,
Factor,
response_variable,
log_transform = FALSE,
high_color,
low_color,
aggregate_by
)
Arguments
count_data |
A metabolomics count data frame. |
metadata |
The descriptive meta data for the samples. |
Factor |
The column name for the independent variable in your metadata. |
response_variable |
The response variable for the data, i.e. "Metabolite" |
log_transform |
TRUE or FALSE. Recommended for visualization purposes. If true data is transformed by the natural log. |
high_color |
Color for high abundance values |
low_color |
Color for low abundance values |
aggregate_by |
Hierarchical metadata value to sum metabolite values by, i.e. "Class" |
Examples
c57_nos2KO_mouse_countDF <- assign_hierarchy(c57_nos2KO_mouse_countDF, TRUE, "KEGG")
plot_heatmap(count_data = c57_nos2KO_mouse_countDF, metadata = c57_nos2KO_mouse_metadata,
log_transform = TRUE, Factor = "Treatment", response_variable = "Metabolite",
aggregate_by = "Subclass_2", high_color = "darkgoldenrod1", low_color = "dodgerblue2")
[Package omu version 1.1.2 Index]