【发布时间】:2018-06-18 10:52:22
【问题描述】:
我想使用 dredge::MuMIn 来探索我的数据。如果变量和GISalt 之间也存在交互,我只想包含I(GISalt^2) 和其他环境变量之一之间的交互。
例如我想保留:
(GISalt * Forest) AND (I(GISalt^2) * Forest)
mod1 <- glm(MLE2017 ~ MLE200405 + (GISalt * Forest) + Scrub + I(GISalt^2) * Forest)
和
(GISalt * Forest) but NOT I(GISalt^2) * Forest)
mod2 <- glm(MLE2017 ~ MLE200405 + (GISalt * Forest) + Scrub)
并排除:
I(GISalt^2) * Forest) 但不是 GISalt * Forest) mod3
包含dredge() 的所有变量的全局模型
globmod <- glm(MLE2017 ~ MLE200405 + GISalt * Forest + GISalt * Scrub
+ GISalt * Meadow + GISalt * RiverLgthm + GISalt * DailySunHrs +
I(GISalt^2) * Forest + I(GISalt^2) * Scrub + I(GISalt^2) * Meadow +
I(GISalt^2) * RiverLgthm + I(GISalt^2) * DailySunHrs,
data = GLMdata, family = x.quasipoisson(link = "log"))
【问题讨论】:
标签: r variables subset interaction mumin