snc {alien} | R Documentation |
Fit a model to discovery records
Description
Fit a model to a time series describing first records of alien species.
If no external data is provided, the function fits the model described in Solow and Costello (2004).
When external data on either \mu_t
or \Pi_{st}
is provided, the function fits the
modified model (sampling-proxy model in the case of \Pi_{st}
) as described in Buba et al (2024).
Usage
snc(
y,
mu = NULL,
pi = NULL,
data = NULL,
init = NULL,
growth = TRUE,
type = "exponential",
...
)
Arguments
y |
either a vector describing the number of discovered alien and invasive species (IAS) over a given time period, or the name (quoted or unquoted) of the corresponding column in the provided data. |
mu |
a formula defining the predictors for |
pi |
a formula defining the predictors for |
data |
a data frame containing the variables in the model(s). |
init |
Optional. Initial values supplied to |
growth |
logical. Should the population growth parameter |
type |
Define whether the mu function should be on "linear" or "exponential" scale. Defaults to "exponential". |
... |
Further arguments passed to |
Details
This function expands on the model described in Solow and Costello (2004) by facilitating the
inclusion of external data to describe either introduction rate \mu_t
or detection probability \Pi_{st}
.
The model with external data for detection probability (sampling-proxy model) is described fully in Buba et al (2024).
The use of external data to describe the introduction rate has not been thoroughly evaluated.
When no formula is defined for either, the function automatically fits the original Solow and Costello (2004)
model using the length of the vector data as the independent variable t
.
All models return estimated parameters for both the introduction rate and the detection probability,
with the parameter of interest usually being the change of introduction rate - \beta_1
.
For more details see the Basic Usage vignette:
vignette("basic_usage", package = "alien")
Value
snc
returns an object of class "snc" containing:
records | the supplied first records data |
convergence | the optim convergence code. |
log-likelihood | the maximum log-likelihood. |
coefficients | a named vector of the ML estimates of the coefficients. |
fitted.values | the fitted mean \lambda values. |
predict | a data frame containing the estimated mean +- Standard error \mu values. |
References
Solow, A. R., & Costello, C. J. (2004). Estimating the rate of species introductions from the discovery record. Ecology, 85(7), 1822–1825. https://doi.org/10.1890/03-3102
Buba, Y., Kiflwai, M., McGeoch, M. A., Belmaker, J. (2024) Evaluating models for estimating introduction rates of alien species from discovery records. https://doi.org/10.1111/geb.13859
Examples
# Solow and Costello (2004) model:
data(sfestuary)
example_model <- snc(sfestuary)
print(example_model)
# Buba et al (2024) sampling-proxy model:
data(medfish)
example_buba <- snc(y = aliens, pi = ~ natives, data = medfish)
print(example_buba)