source_biplot: Create Biplot

Description Usage Arguments Value Examples

View source: R/plots.R

Description

Create a biplot for group means and standard deviations with an option to shift by trophic discrimination factor means and standard deviations. Function is built for plotting source data

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
source_biplot(
  data,
  group,
  var1,
  var2,
  tdf1 = c(mean = 0, sd = 0),
  tdf2 = c(mean = 0, sd = 0),
  x_lab = "",
  y_lab = ""
)

Arguments

data

A data frame

group

Groups of sources to be plotted

var1

X-axis isotope

var2

Y-axis isotope

tdf1

trophic discrimination factor for var 1 entered as tdf1 = c(mean, sd)

tdf2

trophic discrimination factor for var 1 entered as tdf1 = c(mean, sd)

x_lab

X-axis label

y_lab

Y-axis label

Value

Plot

Examples

1
2
3
4
5
iso_data <- data.frame(iso_a = c(2.2, 4.4, 3.3, 5.1, 3.4),
iso_b = c(1.6, 3.9, 5.2, 4.2, 3.7),
prot = c("bug", "bug", "bug", "plant", "plant"))
source_biplot(iso_data, prot, iso_a, iso_b, tdf1 = c(2, 1), tdf2 = c(1, 1),
             x_lab = "A", y_lab = "B")

mncube/mxsrquick documentation built on Dec. 21, 2021, 8:07 p.m.