Generate a Sankey diagram from an OTU table with taxonomic information

abundance_sankey_plot(
  table,
  output_file = "sankey.html",
  maxn = 25,
  taxRanks = c("D", "K", "P", "C", "O", "F", "G", "S"),
  taxonomy_db = "gg"
)

Arguments

table

Data frame with one column for taxonomy and the other columns correspond to samples.

output_file

Output HTML file name (default: "sankey.html").

maxn

Maximum number of taxa per level to include in the diagram (default: 25).

taxRanks

Taxonomic levels to display (default: c("D","K","P","C","O","F","G","S")).

taxonomy_db

Database to which the taxonomy in the table corresponds, e.g., "gg" or "kraken2" (default: "gg").

Examples

abundance_sankey_plot(table= table_taxa,
                                output_file <- file.path(getwd(), "sankey_scel_gg2.html"),
                                maxn = 10,
                                taxRanks = c("P", "C", "G", "S"),
                                taxonomy_db = "silva")
#> Error in abundance_sankey_plot(table = table_taxa, output_file <- file.path(getwd(),     "sankey_scel_gg2.html"), maxn = 10, taxRanks = c("P", "C",     "G", "S"), taxonomy_db = "silva"): could not find function "abundance_sankey_plot"