Learn R Programming

trps (version 0.1.0)

add_alpha: Calculate and add \(\alpha\)

Description

Calculate \(\alpha\) for a two source trophic position model using equations from Post 2002.

Usage

add_alpha(data, abs = FALSE)

Value

a data.frame that has alpha, min_alpha, and max_alpha added.

Arguments

data

data.frame of stable isotope samples with mean values for two baselines. For aquatic ecosystems, baseline one needs to come from a benthic source and baseline two needs to come from a pelagic source. Baseline \(\delta^{13}\)C columns need to be named c1 and c2, with the consumer's \(\delta^{13}\)C column named d13c.

abs

logical that controls whether the absolute value is taken for the numerator and denominator. Default is FALSE meaning that the absolute value is not taken.

Details

$$\alpha = (\delta^{13}C_c - \delta ^{13}C_2) / (\delta ^{13}C_1 - \delta ^{13}C_2)$$

where \(\delta^{13}C_c\) is the isotopic value for consumer, \(\delta^{13}C_1\) is the mean isotopic value for baseline 1 and \(\delta^{13}C_2\) is the mean isotopic value for baseline 2.

Examples

Run this code
combined_iso |>
  add_alpha()

Run the code above in your browser using DataLab