MuMIn
contains functions to streamline model selection and
perform model averaging based on information criteria (AIC, AICc and alike).Model selection can be done according to any information criterion, such as
AIC
, AICc
, BIC
, QAIC
,
ICOMP
or Mallows' Cp.
AIC
, step
or stepAIC
for stepwise
model selection by AIC.data(Cement)
fm1 <- lm(y ~ ., data = Cement)
ms1 <- dredge(fm1)
confset.d4 <- get.models(ms1, subset = delta < 4)
model.avg(confset.d4)
confset.95p <- get.models(ms1, cumsum(weight) <= .95)
avgmod.95p <- model.avg(confset.95p)
summary(avgmod.95p)
confint(avgmod.95p)
Run the code above in your browser using DataLab