DI Models

Deep Dive

Welcome to the Diversity-Interactions (DI) models deep dive. Here you will find some more complex examples of how to fit Generalised DI models to data with repeated measures, multiple community level responses, multiple sites, and more, including details of the models, code to fit the models, and how to interpret the results.

The DI Models Deep Dive

The Non-Linear Parameter Theta

The inclusion of the non-linear parameter theta in a DI model allows for the shape of the BEF relationship being studied to vary.


Theta value of 1 vs 0.79, BEF shape

Figure 1: A plot showing an example of the change in the shape of the BEF relationship for different values of the non-linear parameter theta. Credit: Connolly et al., 2013


This parameter was introduced to the DI modelling framework in Connolly et al., 2013 and is applied as an exponent to the species interaction components of a DI model.

Here we go into coding examples

Example

What will I learn from looking at this example?

In this example, we describe how to implement the non-linear parameter theta in DI models (Kirwan et al., 2009) using R (version 4.1.2) for a blank species system using a simulated dataset consisting of blank. The models described could be used to answer research questions like a univariate DI model and about the shape of the BEF relationship.



Coming Soon!


Installing and Loading the DImodelsMulti R Package

Before you look at more complex DI models, we recommend you install and load the DImodelsMulti R package.

As the DImodelsMulti package is available on CRAN, installing it is simple. We use the install.packages() function, specifying DImodelsMulti (with the quotes), to install the latest version of the package.

install.packages("DImodelsMulti")

Next, in order to have the functions in the package available to our current R session, we load the installed package using the library() function, specifying DImodelsMulti (this time without the quotes).

library(DImodelsMulti)

And now the package is ready for use!

You should only have to install the package once (and again if an updated version is available on CRAN) but will have to load the package each time you start a new R session. It is good coding practice to load all required libraries/packages at the start of any R file that you make.

Multivariate DI Model

Multifunctionality refers to the simultaneous provision of goods/services from an ecosystem. Data containing readings for multiple ecosystem function responses from a set of experimental units (e.g. plots) can be used to study multifunctionality. The multivariate DI model (Dooley et al., 2015) enables the simultaneous prediction of multiple ecosystem function responses, while accounting for any existing covariance between the functions.



Example

This model can now be fit using the new R package DImodelsMulti.

Coming Soon!



Repeated Measures DI Model

When data has a single ecosystem function response read from a set of experimental units (e.g. plots) at multiple time points, we say that data contains a repeated measure or is longitudinal. The repeated measures DI model (Finn et al., 2013) enables the simultaneous prediction of an ecosystem function response over multiple time points, while accounting for any existing covariance between readings from the same experimental unit.



Example

This model can now be fit using the new R package DImodelsMulti.

Coming Soon!