Learn R Programming

mglmn (version 0.1.0)

best.vars: Best variables

Description

Returns variables for the best model based on AIC

Usage

best.vars(x)

Arguments

x

A list of results of `maglm` and `mamglmg`

Value

A vector of terms of the best model.

See Also

maglm, mamglm

Examples

Run this code
# NOT RUN {
#load species composition and environmental data
data(capcay)
adj.sr <- capcay$adj.sr
env_sp <- capcay$env_sp

#to fit a poisson regression model:
res <- maglm(data = env_sp, y = "adj.sr", family = "gaussian")

best.vars(res)
# }

Run the code above in your browser using DataLab