refactor sim_bayes_comp5