Template Function fwdpp::mutate_recombine¶
Defined in File mutate_recombine.hpp
Function Documentation¶
-
template<typename
GenomeContainerType, typenameMutationContainerType, typenamequeue_type, typenamenew_mutations_type, typenamebreakpoints_type>
uint_tfwdpp::mutate_recombine(const new_mutations_type &new_mutations, const breakpoints_type &breakpoints, const std::size_t g1, const std::size_t g2, GenomeContainerType &haploid_genomes, MutationContainerType &mutations, queue_type &haploid_genome_recycling_bin, typename GenomeContainerType::value_type::mutation_container &neutral, typename GenomeContainerType::value_type::mutation_container &selected)¶ Update apply new mutations and recombination events to an offspring’s haploid_genome.
TODO: unit test this note. I simply cannot believe it! :)
- Todo:
Need a unit test on what happens if mutation_keys is not a sorted range
- Return
The index of the new offspring haploid_genome in haploid_genomes.
- Note
For efficiency, it is helpful if new_mutations is sorted by mutation position. fwdpp::generate_new_mutations exists to help in that regard. Many of the evolve functions used in this library and other packages by the author will use fwdpp::generate_breakpoints to generate breakpoints. That is not, however, required.
- Parameters
new_mutations: A range referring to new mutation keys. Must be traversable via non-member begin/end functions using argument-dependent lookup (ADL).breakpoints: A range of recombination breakpoints traversable via non-member begin/end functions.g1: Parental haploid_genome 1g2: Parental haploid_genome 2haploid_genomes: The vector of haploid_genomes in the populationmutations: The vector of mutations in the populationhaploid_genome_recycling_bin: FIFO queue for haploid_genome recyclingneutral: Temporary container for updating neutral mutationsselected: Temporary container for updatng selected positions
- Version
This function was added in fwdpp 0.5.7.