ind_val {ecan}R Documentation

Helper function for Indicator Species Analysis

Description

Calculating diversity indices such as species richness (s), Shannon's H' (h), Simpson' D (d), Simpson's inverse D (i).

Usage

ind_val(
  df,
  stand = NULL,
  species = NULL,
  abundance = NULL,
  group = NULL,
  row_data = FALSE
)

Arguments

df

A data.frame, which has three cols: stand, species, abundance. Community matrix should be converted using table2df().

stand, species, abundance

A text to specify each column. If NULL, 1st, 2nd, 3rd column will be used.

group

A text to specify group column.

row_data

A logical. TRUE: return row result data of labdsv::indval().

Value

A data.frame.

Examples


library(dplyr)
library(tibble)
data(dune, package = "vegan")
data(dune.env, package = "vegan")
df <- 
  dune %>%
  table2df(st = "stand", sp = "species", ab = "cover") %>%
  dplyr::left_join(tibble::rownames_to_column(dune.env, "stand"))
ind_val(df, abundance = "cover", group = "Moisture")



[Package ecan version 0.2.1 Index]