update_DI {DImodels}R Documentation

Update DI function call

Description

Update the call to the DI function. This function allows users to update a previous call to the DI function by only updating the relevant arguments from DI, without the need to write out the full DI code again.

Usage

update_DI(object, ...)

Arguments

object

a DI model object

...

other arguments passed to the DI function

Value

A model object of class "glm" including the components detailed in glm, plus the following:

DIcall

the call of the DI function

DIinternalcall

an internal call made within the DI model fitting process

Author(s)

Rafael A. Moral, John Connolly and Caroline Brophy

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, 344-355.

Kirwan L, J Connolly, JA Finn, C Brophy, A Lüscher, D Nyfeler and MT Sebastia (2009) Diversity-interaction modelling - estimating contributions of species identities and interactions to ecosystem function. Ecology, 90, 2032-2038.

See Also

DI

Examples


## Load the Switzerland data
  data(Switzerland)

## Fit the FG DImodel, with factors density and treatment, and with theta = 1
  m1 <- DI(y = "yield", density = "density", prop = 4:7, treat = "nitrogen", 
         FG = c("G","G","L","L"), DImodel = "FG", data = Switzerland)
  summary(m1)

## Fit the FG DImodel, with factors density and treatment, and theta estimated
  m2 <- update_DI(m1, estimate_theta = TRUE)
  summary(m2)

## Fit the FULL DImodel, with factors density and treatment, and theta estimated
  m3 <- update_DI(m1, DImodel = "FULL", estimate_theta = TRUE)
  summary(m3)

[Package DImodels version 1.1 Index]