GARS_Mutation {GARS}R Documentation

Perform the Mutation step

Description

This function implements the mutation step in the GA. First, it checks and replace duplicate features in each chromosomes; then, random mutation are applied to the entire population.

Usage

GARS_Mutation(chr.pop, mut.rate = 0.01, totFeats)

Arguments

chr.pop

A matrix or a data.frame representing the chromosomes population: each column is a chromosome and each element correspond to the feature position in the data matrix

mut.rate

The probability to apply a random mutation to each element. It must be between 0 and 1. Default is 0.01

totFeats

The total number of features. Often, it corresponds to number of columns of the data matrix

Value

A matrix representing the "mutated" population. The dimensions of this matrix are the same of 'chr.pop'

Author(s)

Mattia Chiesa, Luca Piacentini

See Also

GARS_Elitism, GARS_Selection, GARS_Crossover,

Examples

# use example data:
data(GARS_popul)
data(GARS_data_norm)

mutated_pop <- GARS_Mutation(GARS_popul, mut.rate=0.1,
 dim(GARS_data_norm)[2])


[Package GARS version 1.2.0 Index]