View source: R/calcFossilDivTT.R
calcFossilDivTT | R Documentation |
calcFossilDivTT
calculates fossil diversity through time using
different methods.
calcFossilDivTT(
data,
tax.lvl = "species",
method = "rangethrough",
bin.reso = 1
)
data |
A |
tax.lvl |
A |
method |
A |
bin.reso |
A |
A data.frame
containing the diversity (column div
) of
the chosen taxonomic level through time, with calculation based on
method
. If "method = rangethrough"
, the time moments are the
layer boundaries given in data
.
If "method = stdmethod"
, the time moments are evenly-space bins with
length equal to bin.reso
, starting at the earliest bound in the
dataset.
Matheus Januario, Jennifer Auler
Foote, M., Miller, A. I., Raup, D. M., & Stanley, S. M. (2007). Principles of paleontology. Macmillan.
# Loading data
data("dinos_fossil")
# Using function:
div1 <- calcFossilDivTT(dinos_fossil, method = "stdmethod")
div2 <- calcFossilDivTT(dinos_fossil, method = "stdmethod", bin.reso = 10)
# Comparing different bins sizes in the standard method
plot(x=div1$age, y=div1$div, type="l",
xlab = "Time (Mya)", ylab = "Richness",
xlim=rev(range(div1$age)), col="red")
lines(x=div2$age, y=div2$div, col="blue")
# Comparing different methods:
div3 <- calcFossilDivTT(dinos_fossil, method = "rangethrough")
plot(x=div1$age, y=div1$div, type="l",
xlab = "Time (Mya)", ylab = "Richness",
xlim=rev(range(div1$age)), col="red")
lines(x=div3$age, y=div3$div, col="blue")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.