Skip to content

Commit

Permalink
cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
jakobbossek committed Aug 24, 2015
1 parent b76fb7d commit 8bbc47c
Showing 1 changed file with 0 additions and 10 deletions.
10 changes: 0 additions & 10 deletions R/selectForSurvival.R
Original file line number Diff line number Diff line change
Expand Up @@ -31,24 +31,14 @@ selectForSurvival = function(population, offspring, STORAGE, n.population, strat
new.population = NULL
survivalSelector = control$survival.selector
if (strategy == "plus") {
# print(population)
# print(offspring)
# stop()
source.population = mergePopulations(population, offspring)
# print(source.population)
# stop()
new.population = survivalSelector(source.population, STORAGE, n.population, control)
# source.individuals = source.population$individuals
# source.fitness = source.population$fitness
# to.survive = order(source.fitness)[seq(n.population)]
} else if (strategy == "comma") {
source.population = offspring
elite = list()

if (n.elite > 0L) {
#catf("Elitism with %i candidates out of %i", n.elite, n.population)
#FIXME: this is principally done already in the "greedy" selector. We could
# use it here
parent.individuals = population$individuals
parent.fitness = population$fitness
to.be.elite = order(parent.fitness)[seq(n.elite)]
Expand Down

0 comments on commit 8bbc47c

Please sign in to comment.