View source: R/xegaNextPopulation.R
xegaNextPopulation | R Documentation |
xegaNextPopulation()
builds the next population by repeatedly
calling ReplicateGene()
.
xegaNextPopulation(pop, fit, lF)
pop |
Population of genes. |
fit |
Fitness. |
lF |
Local configuration. |
Generating the next population is sequential.
However, in order to shift more computations
into the evaluation step, genetic operator pipelines
have been implemented by
lF$ReplicateGene()
.
xegaNextPopulation()
only has to convert
elitist solutions into function closures.
For adaptive genetic operators, population statistics and
the current generation are stored as constant functions
in lF
.
Population of genes.
Other Population Layer:
xegaBestGeneInPopulation()
,
xegaBestInPopulation()
,
xegaEvalPopulation()
,
xegaInitPopulation()
,
xegaLogEvalsPopulation()
,
xegaObservePopulation()
,
xegaRepEvalPopulation()
,
xegaSummaryPopulation()
lFxegaGaGene$cGeneration<-function() {0}
lFxegaGaGene$MutationRate<-MutationRateFactory(method="Const")
lFxegaGaGene$ReplicateGene<-ReplicateGene
lFxegaGaGene$Accept<-AcceptFactory(method="All")
pop10<-xegaInitPopulation(10, lFxegaGaGene)
epop10<-xegaEvalPopulation(pop10, lFxegaGaGene)
newpop<-xegaNextPopulation(epop10$pop, epop10$fit, lFxegaGaGene)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.