if (FALSE) {
require(mgcv)
ms1 <- dredge(glm(Prop ~ dose + I(dose^2) + log(dose) + I(log(dose)^2),
data = Beetle, family = binomial, na.action = na.fail))
fm2 <- gam(Prop ~ s(dose, k = 3), data = Beetle, family = binomial)
merge(ms1, model.sel(fm2))
}
Run the code above in your browser using DataLab