Skip to contents

Function to add the tag "toBeMutated" to a randomly sampled part of the population. Some individuals (the best ones) will be protected from the mutation so that genetic decline does not happen.

Usage

tag_ToBeMutated(pop, mutate_size, protected = NULL)

Arguments

pop:

The population on which the individuals to be mutated will be selected

mutate_size:

The number of individuals to mutate

protected:

The index of individuals which should not be mutated.

Value

The population given as an input with `mutate_size` individuals with `toBeMutated = TRUE`