get_best_nn: Calculates the best neural network architecture that fixes a...

Description Usage Arguments Value Examples

View source: R/get_best_nn.R

Description

Calculates the best neural network architecture that fixes a given problem

Usage

1
2
3
get_best_nn(data, input, output, train = 0.7, validation = 0.2,
  test = 0.1, train_mode = 0, train_final_nn = FALSE, seed = 123,
  population_size = 30, generation_number = 30)

Arguments

data

entry dataset

input

number of inputs within the dataset

output

number of outputs within the dataset

train

proportion of data that is used to train each individual

validation

proportion of data that is used to validate each individual

test

proportion of data that is used to evaluate the final individual if option train_final_nn is TRUE

train_mode

mode of the training. 0: multi-class, 1: regression

train_final_nn

if the final individual is evaluated or not

seed

seed

population_size

size of the population

generation_number

number of generations

Value

List with both architecture and final loss

Examples

1
2
3
4
5
6
{
  data <- data.frame(X1 = c(1:10), X2 = c(11:20), X3 = c(1:10), Y1 = c(0:9),
                     stringsAsFactors = FALSE)
  get_best_nn(data, 3, 1, train_mode = 1, population_size = 5,
              generation_number = 2)
}

cvazquezlos/NNEvol documentation built on Nov. 4, 2019, 9:20 a.m.