diversity_beta_test: Perform a beta diversity test

View source: R/diversity_beta_test.R

diversity_beta_testR Documentation

Perform a beta diversity test

Description

Perform a beta diversity test

Usage

diversity_beta_test(
  MAE,
  tax_level,
  input_beta_method,
  input_select_beta_condition,
  input_select_beta_stat_method,
  input_num_permutation_permanova = 999
)

Arguments

MAE

A Multi-Assay Experiment object. Required.

tax_level

The taxon level at which organisms should be grouped. Req'd.

input_beta_method

Can be either "bray" or "jaccard". Required.

input_select_beta_condition

Condition to group samples Should be a character string of a colData column name. Required.

input_select_beta_stat_method

The test to be used. Can be one of either "PERMANOVA", "Wilcoxon rank sum test", or "Kruskal-Wallis". Required.

input_num_permutation_permanova

The number of permutations to be used.

Value

A plotly object.

Examples

data_dir <- system.file("extdata/MAE.rds", package = "animalcules")
toy_data <- readRDS(data_dir)
p <- diversity_beta_test(toy_data,
  tax_level = "genus",
  input_beta_method = "bray",
  input_select_beta_condition = "DISEASE",
  input_select_beta_stat_method = "Wilcoxon rank sum test",
  input_num_permutation_permanova = 999
)
p


compbiomed/animalcules documentation built on Feb. 7, 2024, 12:13 p.m.