substitution_mutator: Perform substitution mutations on a nucelotide sequence.

Description Usage Arguments Details Value Examples

Description

Perform substitution mutations on a nucelotide sequence.

Usage

1
2
3
4
5
substitution_mutator(nt_sequence, sub_rate_A_to_T = 0.05,
  sub_rate_A_to_C = 0.05, sub_rate_A_to_G = 0.05, sub_rate_T_to_A = 0.05,
  sub_rate_T_to_C = 0.05, sub_rate_T_to_G = 0.05, sub_rate_C_to_A = 0.05,
  sub_rate_C_to_T = 0.05, sub_rate_C_to_G = 0.05, sub_rate_G_to_A = 0.05,
  sub_rate_G_to_T = 0.05, sub_rate_G_to_C = 0.05)

Arguments

nt_sequence

A vector of nucleotides, i.e. c("C","A","T","G","A").

sub_rate_A_to_T

The probability of an "A" becoming a "T".

sub_rate_A_to_C

The probability of an "A" becoming a "C".

sub_rate_A_to_G

The probability of an "A" becoming a "G".

sub_rate_T_to_A

The probability of an "T" becoming a "A".

sub_rate_T_to_C

The probability of an "T" becoming a "C".

sub_rate_T_to_G

The probability of an "T" becoming a "G".

sub_rate_C_to_A

The probability of an "C" becoming a "A".

sub_rate_C_to_T

The probability of an "C" becoming a "T".

sub_rate_C_to_G

The probability of an "C" becoming a "G".

sub_rate_G_to_A

The probability of an "G" becoming a "A".

sub_rate_G_to_T

The probability of an "G" becoming a "T".

sub_rate_G_to_C

The probability of an "G" becoming a "C".

Details

Pass in a vector of nucleotides and the probability of each type of substitution mutation. Get back a mutated vector.

Value

A vector of nucleotides, i.e. c("C","A","A","G","A"), with subsitution mutations included.

Examples

1
2
3
4
set.seed(1)
substitution_mutator(
c("C","A","T","G","A")
)

zcolburn/evolution documentation built on May 19, 2019, 1:48 a.m.