matsengrp / gctree

GCtree: phylogenetic inference of genotype-collapsed trees
https://matsengrp.github.io/gctree
GNU General Public License v3.0
16 stars 2 forks source link

add isotype to mutation model simulation #83

Open willdumm opened 2 years ago

willdumm commented 2 years ago

Without otherwise changing the simulation in mutation_model.MutationModel.simulate, adds isotype switching according to a new rate parameter isotype_lambda.

willdumm commented 2 years ago

What I've done instead is add a parameter transition_probabilities, which allows the user to pass an arbitrary transition matrix, in which rows are probability distributions on target isotypes. These transition probabilities are different than the weights attached to isotype objects, since larger weights should correspond to lower probability transitions. I considered relating the two by taking the log of probabilities, but I think it better to just separate them