identify_env: Identify the environment from new samples of community...

View source: R/identify_env.R

identify_envR Documentation

Identify the environment from new samples of community species

Description

This function uses the result of [select_indicator_species()] to identify a new set of samples from the community

Usage

identify_env(com.to.identify, indicator.species, group, alfa = 0.05)

Arguments

com.to.identify

A new sample or group of samples to identify the environment that they belong to.

indicator.species

The indicator species such as that returned by [select_indicator_species()]

group

vector of the sample grouping of the original community.

alfa

Significance level used for the test.

Value

A list with two components: a data.frame with the environment estimation value for each group and a vector with the belonging environment estimated. If two environments coincides in the max value then returns NA.

Examples


data(soilandfauna)
 
# Select community (species) data

com <- soilandfauna[,18:60]

# Select grouping factor

group <- soilandfauna[,1]

# Select a subset of samples belonging to the same environment

subcom <- com[3:10,]

# Estimate the indicator species present

indicator.species <- select_indicator_species(com, group)

# Estimate the environment or group the samples belongs

identify_env(subcom, indicator.species, group)


lsaravia/EcoIndicators documentation built on Sept. 19, 2024, 11:07 p.m.