View source: R/xegaOperatorPipelines.R
newCross2Pipeline | R Documentation |
The pipeline is evaluate(accept(crossover, gene, gene1))
.
The execution of this pipeline produces two genes.
newCross2Pipeline(g, g1, lF)
g |
A gene. |
g1 |
A gene. |
lF |
The local function configuration. |
Closure of genetic operator pipeline
with crossover only.
The argument of the closure lF
configures the behavior of the pipeline.
Other Genetic Operator Pipelines:
newCross2Mut1Pipeline()
,
newCross2Mut2Pipeline()
,
newCrossMut2Pipeline()
,
newCrossMutPipeline()
,
newCrossPipeline()
,
newMutPipeline()
,
newPipeline()
lFxegaGaGene$CrossGene<-xegaGaCross2Gene
lFxegaGaGene$MutationRate<-function(fit, lF) {0.5}
lFxegaGaGene$CrossRate<-function(fit, lF) {0.5}
lFxegaGaGene$Accept<-function(OpPipeline, gene, lF) {OpPipeline(gene, lF)}
g<-xegaGaInitGene(lFxegaGaGene)
g1<-xegaGaInitGene(lFxegaGaGene)
a<-newCross2Pipeline(g, g1, lFxegaGaGene)
print(a)
a(lFxegaGaGene)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.