sim0 {DImodels}  R Documentation 
The Simulated "sim0" Dataset
Description
The sim0
dataset was simulated. There are four replicates and three species that vary in proportions (p1  p3
). There are 16 unique sets of proportions identified by the variable community
. The response was simulated assuming that there were species identity effects and separate pairwise interactions effects.
Usage
data(sim0)
Format
A data frame with 64 observations on the following six variables:
community
A numeric vector identifying each unique community, i.e., two rows with the same community value also share the same set of p1 to p3 values.
richness
A numeric vector indicating the number of species in the initial composition, i.e., the number of proportions from p1 to p3 that are >0.
p1
A numeric vector indicating the initial proportion of species 1.
p2
A numeric vector indicating the initial proportion of species 2.
p3
A numeric vector indicating the initial proportion of species 3.
response
A numeric vector giving the simulated response variable.
Details
What are DiversityInteractions (DI) models?
DiversityInteractions (DI) models (Kirwan et al 2009) are a set of tools for analysing and interpreting data from experiments that explore the effects of species diversity on communitylevel responses. We strongly recommend that users read the short introduction to DiversityInteractions models (available at: DImodels
). Further information on DiversityInteractions models is also available in Kirwan et al 2009 and Connolly et al 2013.
Parameter values for the simulation
DI models take the general form of:
y = Identities + Interactions + Structures + \epsilon
where y is a communitylevel response, the Identities are the effects of species identities and enter the model as individual species proportions at the beginning of the time period, the Interactions are the interactions among the species proportions, while Structures include other experimental structures such as blocks, treatments or density.
The dataset sim0
was simulated with:
identity effects for the four species with values = 25, 20, 15
all 3 pairwise interaction effects with values: 30, 20, 40 (for pairs of species 12, 13, and 23, respectively).

\epsilon
assumed normally distributed with mean 0 and standard deviation 2.
References
Connolly J, T Bell, T Bolger, C Brophy, T Carnus, JA Finn, L Kirwan, F Isbell, J Levine, A Lüscher, V Picasso, C Roscher, MT Sebastia, M Suter and A Weigelt (2013) An improved model to predict the effects of changing biodiversity levels on ecosystem function. Journal of Ecology, 101, 344355.
Kirwan L, J Connolly, JA Finn, C Brophy, A Lüscher, D Nyfeler and MT Sebastia (2009) Diversityinteraction modelling  estimating contributions of species identities and interactions to ecosystem function. Ecology, 90, 20322038.
Examples
## load the sim0 dataset
data(sim0)
## Find the best DI model using autoDI and Ftest selection
auto1 < autoDI(y = "response", prop = c("p1","p2","p3"), data = sim0,
selection = "Ftest")
summary(auto1)
## Fit the FULL model using DI and the ID tag
m1 < DI(y = "response", prop = c("p1","p2","p3"), DImodel = "FULL",
data = sim0)
summary(m1)
plot(m1)
## Check goodnessoffit using a halfnormal plot with a simulated envelope
library(hnp)
hnp(m1)