Module genevo::selection::proportionate
source · [−]Expand description
The proportionate
module provides operator::SelectionOp
s that implement
stochastic fitness proportionate selection strategies. Individuals are
randomly selected. Individuals with a higher genetic::Fitness
value are
having a higher probability to be selected.
How is this achieved? In fitness proportionate selection each individual gets assigned a weight that is equal to its fitness value plus the sum of fitness values of all individuals in the list before him (cumulative weight distribution). Then a uniform random number between 0 and the sum of all weights is used to select a candidate.
The provided fitness proportionate selection operators are:
RouletteWheelSelector
- no bias - does not guarantee minimal spread.UniversalSamplingSelector
- no bias - minimal spread.
Structs
The RouletteWheelSelector
implements stochastic fitness proportionate
selection. Each candidate is picked randomly with a probability of being
picked that is proportional to its fitness value.
The UniversalSamplingSelector
implements stochastic fitness proportionate
selection. The first candidate is picked randomly. All other candidates are
picked by equidistant jumps.