richelbilderbeek / raket

What is the error we make, when nature has protracted speciation, and inference ignore this?
GNU General Public License v3.0
0 stars 0 forks source link

Prerequisite: babette provides for constant known strict clock rate #7

Closed richelbilderbeek closed 6 years ago

richelbilderbeek commented 6 years ago

BEAST2 ignores whatever I do with the explicitly set strict clock. I will keep the default clock.

library(babette)
simple_names <- names(
  bbt_run(
    fasta_filenames = get_babette_path("anthus_aco_sub.fas"),
    clock_models = create_strict_clock_model(),
    mcmc = create_mcmc(
      chain_length = 2000, 
      store_every = 1000
    )
  )$estimates
)
hard_names <- names(
  bbt_run(
    fasta_filenames = get_babette_path("anthus_aco.fas"),
    clock_models = create_strict_clock_model(
      clock_rate_param = create_clock_rate_param(
        value = 10.0, estimate = FALSE
      ),
      clock_rate_distr = create_normal_distr(
        mean = create_mean_param(
          value = 10.0, 
          estimate = FALSE
        ),
        sigma = create_sigma_param(
          value = 0.01, 
          estimate = FALSE
        )
      )
    ),
    mcmc = create_mcmc(
      chain_length = 2000, 
      store_every = 1000
    )
  )$estimates
)
testit::assert(simple_names == hard_names)