fadlad {divDyn} | R Documentation |
FAD - LAD matrix from occurrence data
Description
Function to generate range data from an occurrence dataset.
Usage
fadlad(
x,
tax,
bin = NULL,
age = NULL,
revtime = FALSE,
na.rm = TRUE,
diffbin = TRUE
)
Arguments
x |
(data.frame) : Occurrence data.
|
tax |
(character) : Column name of taxon names.
|
bin |
(character) : Column name(s) of the discreet bin variable(s). If two column names are entered, then they will interpreted as minimum and maximum uncertainty (see examples) By default, time flows from lower to higher numbers. You can change this behavior by setting revtime=FALSE . Either a bin or age argument is mandatory.
|
age |
(character) : Column name(s) of the continuous age variable(s). If two column names are entered, then they will interpreted as the minimum and maximum age uncertainty. (see examples) By default, time flows from higher to lower numbers. You can change this behavior by setting revtime=FALSE . Either a bin or age argument is mandatory.
|
revtime |
(logical) : Should time be reversed?
|
na.rm |
(logical) : Should taxa that have no valid FADs or LADs (due to NA entries) be removed from the output?
|
diffbin |
(logical) : Difference-based duration for discreet time (only applicabble to cases when bin is provided). If set to TRUE , single-interval taxa will 0 durations. Setting this argument to FALSE will add 1 to the durations of all taxa.
|
Details
The function will output First and Last Appearance Dates of the taxa in the dataset. Keep in mind that incomplete sampling will influence these data and will make the ranges appear shrunken.
The following variables are produced:
row.names
attribute: The names of the taxa.
FAD
: First appearance dates in time bin nmbers or ages.
LAD
: Last appearance dates in time bin numbers or ages.
duration
: The durations of taxa in bin numbers or ages.
Value
A data.frame, with rows corresponding to tax
entries.
Examples
data(corals)
# binned data
flBinned <- fadlad(corals, tax="genus", bin="stg")
# using basic bin lengths
flDual <- fadlad(corals, tax="genus", age=c("max_ma", "min_ma"))
# single age esimate
data(stages)
corals$mid <- stages$mid[corals$stg]
flSingle <- fadlad(corals, tax="genus", age="mid")
[Package
divDyn version 0.8.3
Index]