plot_alpha_diversity: Plot alpha diversity

View source: R/plot_alpha_diversity.R

plot_alpha_diversityR Documentation

Plot alpha diversity

Description

This function calculates alpha diversity of provided community data using selected method(s). It performs paired wilcox or t-test of diversity measures between groups and outputs a plot for each of the selected methods(indices) annotated with significance levels.

Usage

plot_alpha_diversity(alphares)

Arguments

alphares

(Required). A result from alpha_diversity function sample data including the measured variables and categorical information of the samples.

method

(Required). A list of character strings specifying method to be used to calculate for alpha diversity in the data. Available methods are: "t.test", "wilcox.test".

Details

22/01/2020 ShenZhen China

Value

Returns a ggplot object

Author(s)

Huahui Ren, zouhua

Examples

library(dplyr)
library(ggplot2)
source("R/config.R")
data(physeq_data)
alphares <- alpha_diversity(physeq_data)
plot_alpha_diversity(physeq_data, method, grouping_column, pid)


rusher321/microbiotaPair documentation built on July 24, 2024, 8:40 p.m.