calculate_fitness: Calculate the fitness of a given model.

Description Usage Arguments Value Examples

Description

Calculate the fitness of a given model.

Usage

1
calculate_fitness(index, X, y, fit_func, family = gaussian)

Arguments

index

A vector of indices of selected variables.

X

Data frame containing all available features

y

Response variable

fit_func

Fitness function, with the default being AIC

family

description of the family of distributions to be used.

Value

A fitness value of the provided model, based on the provided fitness function.

Examples

1
fitness <- calculate_fitness(1:3, data.frame(replicate(10,sample(0:1,1000,rep=TRUE))), 1:1000, fit_func=AIC)

kunaljaydesai/GA2 documentation built on May 30, 2019, 2:15 p.m.