ces.table | R Documentation |
Runs a specified set of models (see details) for a list of species and present the results in a table.
ces.table(cesobj, species=NA, columns=c("A-1", "P-1", "S-1"), base=100, plots=NULL, min.n=100, min.ch=50, ndigits=2, year=-1, change=FALSE, visit.corr=TRUE, save.results=FALSE)
cesobj |
a CES dataframe typically generated by |
species |
a numeric vector of Euring species codes, these can be checked using |
columns |
a character vector specifying which models should be applied to each species, see details. |
base |
which number should indicate no change: 0, 1, or 100? |
plots |
an object containing plot coverage data created by |
min.n |
if species is not specified, include all species with more than this number of captures. |
min.ch |
for survival models, how many individuals need to be captured for a site to be included, see |
ndigits |
numeric, how many decimal places to round the results to, see note. |
year |
the reference year for the comparisons if not the last. |
change |
logical, for comparison models return the change or the relative value (e.g. +0.2 or 1.2); for trend models TRUE gives the overall change, FALSE the (annual) slope. |
visit.corr |
logical, include an offset for missed visits in the models, see |
save.results |
logical, save the full model results, or only the annual values. Setting this to TRUE can result in a quite a large object, so it may be helpful to skip these. |
Models are specified using three characters: (i) the parameter ('A'dult and 'J'uvenile numbers, 'P'roductivity and 'S'urvival, (ii) the model type, currently either '-' to compare to previous years or '/' for a trend, and (iii) the number of (previous) years over which the comparison or trend should be calculated. Thus, for example. "A-5" would compare the current year's estimate of adult captures to the previous 5 years, see index
for more details on this. The default is to compare with the previous year ("-1").
For change ('-') models the estimates will be either be the index relative to the base value (so -0.15, 0.85, or 85.0 for base = 0, 1, 100 respectively) or the relevant change (if change=TRUE then -0.15, -0.15, 15.0 in those instances). For trend ('/') models the estimate will be a slope (mean annual change), on either the log (abundance) or logit (survival/productivity) scale (and might be expressed as either 0.07 or 7.00, for example, depending on whether or not base=100).
A simple table will be printed with the change/trend estimate (along with confidence limits and an indication of significance) for each model (columns) and species (rows). These numbers are returned as a dataframe, see 'value' below.
a list with three components: table - a dataframe that mimics the printed table, so in 'wide' format; estimates - a dataframe in 'long' format, one row per entry; results - a named list of the model objects, in the form "T_xxxxx_mmm", where xxxxx is the Euring code number, mmm the model specification.
ndigits is strict, the returned 'estimates' dataframe will be rounded to this level as well.
Rob Robinson
index
## Not run:
# compare adult numbers in the current yaer to the previous year,
# survival with the previous five years and a 10-year trend in productivity
results <- ces.table(ukdata, columns=c('A-0', 'S-5', 'P/10'))
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.