phyloseq_long_treemap: Do a treemap based on the long version of a phyloseq file

Description Usage Arguments Value Examples

View source: R/phyloseq.R

Description

Plot the treemaps and returns a list with a ggplot and a df with the summary of the data

Usage

1
2
3
4
5
6
7
8
phyloseq_long_treemap(
  df,
  group1,
  group2,
  title,
  colors = NULL,
  label_group1 = TRUE
)

Arguments

df

Data frame obtained from a phyloseq file using the function phyloseq_transform_to_long

group1

first grouping level (do not quote)

group2

second grouping level (do not quote)

title

Title for the treemap

colors

If NULL then the default viridis palette is used. If named vectors then the colors

label_group1

If true, the higher level is labeled. If false, only boundaries are marked

Value

Plot the treemap Returns a list made of 2 elements

Examples

1
2
my_list <- phyloseq_long_treemap(phyloseq_long, division, class, "Singapore strait", colors=
                                 structure(c("black", "white"),.Names="Mamiellophyceae", "Dinophyceae"))

vaulot/dvutils documentation built on Nov. 20, 2021, 11:01 a.m.