abdistr_ {paleoDiv} | R Documentation |
Count number of entries in occurrence or collection data.frame for specific points in geological time
Description
Count number of entries in occurrence or collection data.frame for specific points in geological time
Usage
abdistr_(
x,
table = NULL,
ab.val = table$abund_value,
ab.val.na = 1,
smooth = 0,
max = table$eag,
min = table$lag,
w = rep(1, length(x))
)
Arguments
x |
A numeric vector giving the times (in ma) at which to determine the number of overlapping records. |
table |
An occurrence or collection dataset |
ab.val |
Abundance value to be used. Default is table$abund_value. If set to 1, each occurrence is treated as representing one specimen. If NULL (e.g. because this column does not exist) or NA, each occurrence is treated as the number of specimens specified under ab.val.na |
ab.val.na |
Value to substitute for missing entries in abundance values. Defaults to 1. Either a single numeric or a function to be applied to all non-missing entries of ab.val (e.g. mean() or median()). |
smooth |
The smoothing margin, in units of ma. Corresponds to the plusminus parameter of rmeana(). Defaults to 0, i.e. no smoothing (beyond the resolution determined by the resolution of x) |
max |
Vector or column containing maximum age of each occurrence or collection |
min |
Vector or column containing minimum age of each occurrence or collection |
w |
A Vector of weights. Must be of same length as x |
Value
A numeric vector of the same length as x, giving the estimated number of occurrence records (if ab.val==FALSE) or specimens (if ab.val==TRUE), or the estimated number of collections (if collection data are used instead of occurrences) overlapping each temporal value given in x
Examples
data(archosauria)
abdistr_(x=c(170:120), table=archosauria$Stegosauria)