# Simulating some variables
y<-rnorm(mean=100,sd=30,500)
x1<-0.5*y+10+rnorm(mean=20,sd=10,500)
x2<-3*y-45+rnorm(mean=40,sd=150,500)
# Fitting GLMs to those variables to give three models for comparison
m1<-glm(y~x1)
m2<-glm(y~x2)
m3<-glm(y~x1+x2)
# Model selection table using AICc
modSelTab(m1,m2,m3)
# Model selection table using AIC
modSelTab(m1,m2,m3,type="AIC")
# Model selection table using BIC
modSelTab(m1,m2,m3,type="BIC")
Run the code above in your browser using DataLab