lme_var.part: variation partitioning for linear mixed model

View source: R/variation_partitioning.R

lme_var.partR Documentation

variation partitioning for linear mixed model

Description

variation partitioning for linear mixed model

Usage

lme_var.part(full_mod)

Arguments

full_mod

a model results returned by **nlme::lme**

Details

see https://www.pnas.org/doi/abs/10.1073/pnas.1608980113 for details of how this algorithm works. "The function r.squaredGLMM from the MuMIn-package (67) was used to calculate the marginal (fixed effects) and conditional (full model) R2 for all optimal and beyond-optimal models. We then followed a variation partitioning procedure to determine the relative proportion of variation for each response variable in the models with elevation, GDD, and plot productivity. To perform our variation partitioning, we constructed a series of models with (i) only one focal variable, (ii) all variables except that focal variable, or (iii) the full model with all explanatory variables. The proportion of variation explained by each fixed factor was represented by calculating the difference between the marginal R2 of the full model and of the model without the focal variable and dividing it by the marginal R2 of the full model (68). For all factors in all models, the variation explained by the model without the focal variable (R2 of full model minus R2 of model with only the focal variable, divided by full model) and the shared variance (R2 of model of focal variable plus R2 of model without focal variable minus R2 of full model, divided by R2 of full model) were calculated as well (SI Appendix, Tables S7–S9). This variance partitioning could not be performed for the models of probability of flower production, because this probability was zero in the undisturbed subplots in the Scandes."

Value

a data frame containing explained variation by each variable


kun-ecology/ecoloop documentation built on Jan. 9, 2025, 10:20 a.m.