select: Universal selection high-level function

Description Usage Arguments Value Author(s) Examples

View source: R/select.R

Description

This function performs universal selection. The function handles multiple populations and calls the low level selection function for the actual selection process.

Usage

1
select(SEL_F=c("sus","rws"),Chrom,FitnV,GGAP=1,SUBPOP=1,...)

Arguments

SEL_F

character string indicating the selection function.

Chrom

a matrix containing the individuals (parents) of the current population. Each row corresponds to one individual.

FitnV

a vector containing the fitness values of the individuals in the population.

GGAP

an optional number indicating rate of individuals to be selected. Default is set to 1.

SUBPOP

an optional number indicating subpopulations. Default is set to 1 subpopulation.

...

ohter aurguments passed on to selection function.

Value

a matrix containing the selected individuals.

Author(s)

The original matlab implementation of mutate was written by Hartmut Pohlheim. The R implementation was written by David Zhao.

Examples

1
2
3
4
5
6
Chrom = crtbp(40,10)$Chrom

#Ojbective function is the sum of individuals
FitnV = ranking(apply(Chrom,1,sum))

Selch = select(SEL_F="sus",Chrom=Chrom,FitnV=FitnV,GGAP=0.9)

drizztxx/gatbxr documentation built on Dec. 27, 2021, 2:26 a.m.