ranked_models: Fit the models and rank them by their fitness.

Description Usage Arguments Value Examples

View source: R/fitness.R

Description

Fit the models and rank them by their fitness.

Usage

1
2
ranked_models(index, X, y, fit_func = AIC, family = gaussian,
  cluster = NA)

Arguments

index

A list of indices of selected variables.

X

Data frame of all features

y

Dependent variable

fit_func

Function for fitness measurement. Default is AIC.

family

A description of the family of distributions to be used.

Value

a data frame containing index list and their respective fitness, sorted by fitness in ascending order

Examples

1
2
3
4
X <- mtcars[-1]
y <- unlist(mtcars[1])
index <-initialize_parents(10,20)$index
ranked_models(index, X, y)

kunaljaydesai/GA documentation built on May 28, 2019, 7:38 a.m.