View source: R/get_sim_twal_with_std_nsm_fun.R
get_sim_twal_with_std_nsm_fun | R Documentation |
Get a function to simulate a twin alignment which uses a standard site model
get_sim_twal_with_std_nsm_fun(
mutation_rate = 0.1,
site_model = beautier::create_jc69_site_model()
)
mutation_rate |
the mutation rate per base pair per time unit. Use check_mutation_rate to check if a mutation rate is valid. |
site_model |
a nucleotide substitution model, which can be:
|
a partially evaluated function of sim_twal_with_std_nsm
See check_sim_twal_fun to the the other functions to simulate a twin alignment. Use sim_twin_alignment to use this function to create a twin alignment.
f <- get_sim_twal_with_std_nsm_fun(
mutation_rate = 0.1
)
# This adapter function must be a sim_twin_alignment function
check_sim_twal_fun(f)
# Simulate a twin DNA alignment
alignment <- f(
twin_phylogeny = ape::read.tree(text = "((A:1, B:1):2, C:3);"),
root_sequence = "aaaa"
)
check_alignment(alignment)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.