This function allows for ordination (which helps us to distinguish beta diversity relationships) to be plotted as well as for the corresponding data to be returned.

ordination_plot(obj, method = "PCoA", distance = "wunifrac",
  color = "TreatmentGroup", title = NULL, only_data = FALSE)

Arguments

obj

An object to be converted to a taxmap object with create_taxmap.

method

Choose an ordination method from 'PCoA', 'CCA', 'NMDS' or 'DPCoA', Default: 'PCoA'

distance

Choose a distance method or use a pre-computed dist-class object, Default: 'wunifrac'

color

Choose the group or factor of which colors will be mapped to, Default: 'TreatmentGroup'

title

The title of the plot, Default: NULL

only_data

Allows for only ordination data to be generated, Default: FALSE

Value

By default, it returns an ordination plot.

See also

Examples

# NOT RUN {
if (interactive()) {
  # An example ordination plot
  library(MicrobiomeR)
  data <- analyzed_silva
  plot <- ordination_plot(obj = data)
  plot
}
# }