Diverge | R Documentation |
Generates a set of diverging haplotypes from the given DNA sequence. The haplotypes produced share a pattern of divergence with an increasing number of mutations.
Diverge(vm, seq)
vm |
Vector with number of diverging mutations to be generated. |
seq |
Reference sequence from which to generate the variants. |
max(vm)
Positions in the given sequence are randomly generated.
A substitution is also randomly produced for each of these positions.
A haplotype is generated for each element in vm
, so that it contains
vm[i]
substitutions of those previously generated.
Character string vector with the segregating haplotypes generated.
Mercedes Guerrero-Murillo and Josep Gregori
GetRandomSeq
set.seed(123)
m1 <- GetRandomSeq(50)
hpl <- Diverge(3:6,m1)
DottedAlignment(DNAStringSet(hpl))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.