xegaGaGeneMapFactory: Configure the gene map function of a genetic algorithm.

View source: R/xegaGaDecode.R

xegaGaGeneMapFactoryR Documentation

Configure the gene map function of a genetic algorithm.

Description

xegaGaGeneMapFactory() implements the selection of one of the GeneMap functions in this package by specifying a text string. The selection fails ungracefully (produces a runtime error) if the label does not match. The functions are specified locally.

Current support:

  1. "Bin2Dec" returns xegaGaGeneMap(). (Default).

  2. "Gray2Dec" returns xegaGaGeneMapGray().

  3. "Identity" returns xegaGaGeneMapIdentity().

  4. "Permutation" returns xegaGaGeneMapPerm().

Usage

xegaGaGeneMapFactory(method = "Bin2Dec")

Arguments

method

A string specifying the GeneMap function.

Value

A gene map function for genes.

See Also

Other Configuration: lFxegaGaGene, xegaGaCrossoverFactory(), xegaGaMutationFactory(), xegaGaReplicationFactory()

Examples

XGene<-xegaGaGeneMapFactory("Identity")
gene<-xegaGaInitGene(lFxegaGaGene)
XGene(gene$gene1, lFxegaGaGene$penv)

xegaGaGene documentation built on April 16, 2025, 5:11 p.m.