collectResult | R Documentation |
Merge both log
and log.newinds
data for a complete data.frame
with information about progress (both on training data and on
holdout data) and ressource usage.
collectResult( ecr.object, aggregate.perresult = list(domHV = function(x) computeHV(x, ref.point)), aggregate.perobjective = list("min", "mean", "max"), ref.point = smoof::getRefPoint(ecr.object$control$task$fitness.fun), cor.fun = cor )
ecr.object |
|
aggregate.perresult |
|
aggregate.perobjective |
|
ref.point |
|
cor.fun |
|
data.frame
library(mlrCPO) # Setup of optimization problem ps.simple <- pSS( a: numeric [0, 10], selector.selection: logical^10) mutator.simple <- combine.operators(ps.simple, a = mutGauss, selector.selection = mutBitflipCHW) crossover.simple <- combine.operators(ps.simple, a = recSBX, selector.selection = recPCrossover) initials <- sampleValues(ps.simple, 30, discrete.names = TRUE) fitness.fun <- smoof::makeMultiObjectiveFunction( sprintf("simple test"), has.simple.signature = FALSE, par.set = ps.simple, n.objectives = 2, noisy = TRUE, ref.point = c(10, 1), fn = function(args, fidelity = NULL, holdout = FALSE) { pfeat <- mean(args$selector.selection) c(perform = args$a, pfeat = pfeat) }) fitness.fun.single <- smoof::makeMultiObjectiveFunction( sprintf("simple test"), has.simple.signature = FALSE, par.set = ps.simple, n.objectives = 1, noisy = TRUE, ref.point = c(10), fn = function(args, fidelity = NULL, holdout = FALSE) { propfeat <- mean(args$selector.selection) c(propfeat = propfeat) }) # Run NSGA-II results <- slickEcr(fitness.fun = fitness.fun, lambda = 10, population = initials, mutator = mutator.simple, recombinator = crossover.simple, generations = 10) # Collect results colres <- collectResult(results) print(colres)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.