Occupancy spectrum distribution: application for coalescence simulation with generic mergers

Bioinformatics. 2020 May 1;36(10):3279-3280. doi: 10.1093/bioinformatics/btaa090.

Abstract

Motivation: As the density of sampled population increases, especially as studies incorporate aspects of the spatial landscape to study evolutionary processes, efficient simulation of genetic data under the coalescent becomes a primary challenge. Beyond the computational demands, coalescence-based simulation strategies have to be reconsidered because traditional assumptions about the dynamics of coalescing lineages within local populations may be violated (e.g. more than two daughter lineages may coalesce to a parent at low population densities). Specifically, to efficiently assign n lineages to m parents, the order relation between n and m strongly affects the relevant algorithm for the coalescent simulator (e.g. only when n<2m, it is reasonable to assume that two lineages, at most, can be assigned to the same parent). Controlling the details of the simulation model as a function of n and m is then crucial to represent accurately and efficiently the assignment process, but current implementations make it difficult to switch between different types of lineage mergers at run-time or even compile-time.

Results: With the described occupancy spectrum and algorithm that generates the support of the joint probability distribution of the occupancy spectrum; computation is much faster than realizing the whole assignment process under the coalescent. Using general definitions of lineage merges, which also makes the codebase reusable, we implement several variants of coalescent mergers, including an approximation where low probability spectrums are discarded. Comparison of runtimes and performance of the different C++ highly reusable coalescence mergers (binary, multiple, hybrids) are given, and we illustrate their potential utility with example applications.

Availability and implementation: All components are integrated into Quetzal, an open-source C++ library for coalescence available at https://becheler.github.io/pages/quetzal.html.

Supplementary information: Supplementary data are available at Bioinformatics online.

Publication types

  • Research Support, Non-U.S. Gov't
  • Research Support, U.S. Gov't, Non-P.H.S.

MeSH terms

  • Algorithms*
  • Biological Evolution
  • Computer Simulation
  • Genetics, Population*
  • Models, Genetic
  • Population Density
  • Probability