Learn R Programming

sars (version 1.0.0)

gdm: Fit the General Dynamic Model of Island Biogeography

Description

Fit the general dynamic model (GDM) of island biogeography using a variety of SAR models. Functions are provided to compare the GDM fitted using different SAR models, and also, for a given SAR model, to compare the GDM with alternative nested candidate models (e.g. S ~ A + T).

Usage

gdm(data, model = "linear", mod_sel = FALSE, AST = c(1, 2, 3))

Arguments

data

A dataframe or matrix with at least three columns, where one column should include island area values, one island richness values and one island age values.

model

Name of the SAR model to be used to fit the GDM. Can be any of 'expo', 'linear', 'power', or 'all'.

mod_sel

Logical argument specifying whether, for a given SAR model, a model comparison of the GDM with other nested candidate models should be undertaken.

AST

The column locations in data for the area, richness and time values (in that order).

Value

An object of class 'gdm'. If model is one of "expo", "linear" or "power" the returned object is a nls model fit object. If model == "all", the returned object is a list with three elements; each element being a nls fit object.

If mod_sel == TRUE and model != "all", a list with four elements is returned; each element being a lm or nls fit object. When model == "all", a list with three elements is returned; each element being a list of the four model fits for a particular SAR model.

Details

The GDM models island species richness as a function of island area and island age, and takes the general form: S ~ A + T + T^2, where S = richness, A =area, and T = island age. The T^2 term is included as the GDM predicts a hump-shaped relationship between island richness and island age. However, a variety of different SAR models have been used to fit the GDM and three options are available here: the exponential, linear and power SAR model. Model fitting follows the procedure in Cardoso et al. (2015). For example, when the linear SAR model is used, the GDM can be fitted using the expression: S ~ c + z*Area + k*T + j*T^2, where c,z,k,j are free parameters to be estimated.

For all three SAR models, the GDM is fitted using non-linear regression and the nls function. For ease of fitting, the exponential and power SAR models are included in their logarithmic form, e.g. the exponential model is fitted using: S ~ c + x*log(A), where c and x are parameters to be estimated.

For each model fit, the residual standard error (RSE) and AIC values are reported. However, as the model fit object is returned, it is possible to calculate or extract various other measures of goodness of fit (see nls).

If mod_sel == TRUE, the GDM (using a particular SAR model) is fitted and compared with three other (nested) candidate models: area and time (i.e. no time^2 term), just area, and an intercept only model. The intercept only model is fitted using lm rather than nls. If model == "all", the GDM is fitted three times (using the power, expo and linear SAR models), and the fits compared using AIC.

References

Whittaker, R. J., Triantis, K. A., & Ladle, R. J. (2008). A general dynamic theory of oceanic island biogeography. Journal of Biogeography, 35, 977-994.

Borregaard, M. K. et al. (2017). Oceanic island biogeography through the lens of the general dynamic model: assessment and prospect. Biological Reviews, 92, 830-853.

Cardoso, P., Rigal, F., & Carvalho, J. C. (2015). BAT<U+2013>Biodiversity Assessment Tools, an R package for the measurement and estimation of alpha and beta taxon, phylogenetic and functional diversity. Methods in Ecology and Evolution, 6, 232-236.

Examples

Run this code
# NOT RUN {
#create an example dataset and fit the GDM using the exponential SAR model
data(galap)
galap$t <- rgamma(16, 5, scale = 2)
g <- gdm(galap, model = "expo", mod_sel = FALSE)

#Compare the GDM (using the exponential model) with other nested candidate models
g2 <- gdm(galap, model = "expo", mod_sel = TRUE)

#compare the GDM fitted using the linear, exponential and power SAR models
g3 <- gdm(galap, model = "all", mod_sel = FALSE)
# }

Run the code above in your browser using DataLab