mutatePopulation {ModCon} | R Documentation

## Randomly exchange codons within a set of sequences.

### Description

For every codon within a set of nucleotide sequences randomly exchange the codon encoding the same amino acid to a certain chance.

### Usage

    mutatePopulation(sequenceVector, codonReplacementChance)

### Arguments

`sequenceVector` | Character vector of nucleotide sequences (at least 3 nt long)
`codonReplacementChance` | Numeric value of chance of a codons within the sequences to get exchanged to another codon encoding the same amino acid

### Value

Creates a character vector of coding nucleotide sequences encoding the same amino acid sequence as the entered `sequenceVector`. By a mutation rate stated in `codonReplacementChance`, codons are randomly exchanged, by alternative codons encoding the same amino acid.

### Examples

    mutatePopulation(c("CGCGATACGCTAAGCGCTACCGATAGTGGA","TGGGATATTTTAAGCGCTGACGATAGTGGA"), 0.1)

[Package ModCon version 1.2.0 Index]