Joint Bayesian inference of bacterial ancestral recombination graphs

Tim Vaughan
Centre for Computational Evolution
The University of Auckland
PhyloSeminar, 23rd February, 2017

Why study bacterial phylogenetics?

  • Bacteria play important roles (both positive and negative) in the health of animals and plants.
  • Many bacteria possess interesting and experimentally accessible evolutionary dynamics.
  • Bacterial genomes are measurably evolving over relatively short study periods.
    Drummond & Rambaut, TIEE (2003)
Rainey & Travisano, Nature (1998)

Cartoon bacterial population genetics

  • Effect of events can be plasmid transfer, insertion or homologous recombination.
  • Rate of recombination varies and is subject to selection.
  • Focus on homologous recombination: only event which doesn't alter the length of the sequence

The Problem for Phylogenetic Inference

For many bacteria, the ratio between the recombination rate and the mutation rate is extremely high.

Vos and Didelot, The ISME Journal (2009)

Existing solutions

  • Pre-processing of data to identify and remove non-vertically inherited material. (eg. START: Jolley et al., 2001)
    Pros Cons
    • Can use standard tools for phylogenetic inference.
    • Data is being thrown away.
    • Ad hoc, may bias results.
  • Explicit modelling of bacterial recombination.
    (eg. ClonalFrame and ClonalOrigin: Didelot et al., 2007, 2010)
    Pros Cons
    • Can make use of all data.
    • Can infer additional parameters such as recombination rates.
    • May yield increased confidence in estimates.
    • Models can be complex, with many parameters.
    • Both computationally and statistically challenging.
    • Existing implementations lack flexibility.

The Coalescent with Gene Conversion

Wiuf, 1999; Wiuf and Hein, 2000
Parameters
$N(t)g$ Coalescence rate
$\rho_s$ Recombination rate
$\delta$ Expected tract length
Problem
The space of possible ancestral recombination graphs is extremely large. Even two samples have infinitely many distinct ancestries!

Full ARG


 

Approximation 1: ClonalFrame


Didelot et al., 2007 (ClonalFrame); Didelot and Wilson, 2015 (ClonalFrameML)

Approximation 2: ClonalOrigin


Didelot et al., 2010 (ClonalOrigin); Ansari and Didelot, 2014 (ClonalOrigin')
Our Goal
To conduct Bayesian inference of the full ARG under the ClonalOrigin model, optionally under non-trivial population size dynamics.

Inference under the ClonalOrigin Model

Inference follows the standard Bayesian phylogenetic tradition:

\begin{equation*} f(G,N,\mu,\rho,\delta|A) \propto P_{F}(A|G,\mu)f_{CGC}(G|N,\rho,\delta)f_{\text{prior}}(N ,\mu,\rho,\delta) \end{equation*}

where

  • $A$ is the sequence alignment,
  • $\mu$ are the substitution model parameters, and
  • $G$ is the full sample genealogy including clonal frame
    $T$ and $M$ conversions $\{C_i\}_{i\in[1\ldots M]}$.

The genealogy density under ClonalOrigin model can be expanded

\begin{equation*} f_{CGC}(G|\rho',\delta,N)=\left(\prod_{i=1}^M f(C_i|T,N,\delta)\right)P(M|T,\rho)f_C(T|N) \end{equation*}

Identifiability

Despite using a simplified model, an infinite number of ARGs still possess the same likelihood given a sequence alignment.

Very important for an MCMC algorithm to propose state changes which minimize effect on likelihood.

MCMC State Proposal Strategy

  • Attachment points and site tracts of new conversions drawn from prior.

Validation 1: Sampling from the prior

  • It is trivial to sample directly from the approximate ARG prior via coalescent simulation.
  • We expect precise agreement between our MCMC algorithm and the coalescent simulation when no data is involved.
One should alwayas test that a new sampler exactly converges to a known distribution: this provides a strict necessary criterion for correctness.

Validation 2: Inference from simulated data

True ARG:

Randomly-selected ARG from MCMC:

Summary networks

True ARG:

Summary ARG from MCMC:

Application to Escherichia coli

  • Applied method to E. coli O157/O26 sequences collected by Tessy George (mEpiLab, Massey University, New Zealand).
  • Sequences for 53 rMLST genes (21.1 kb total) from each of 23 human and cattle-derived isolates.
  • Analyzed using fixed expected tract length parameter and informative prior on conversion rate parameter.

Application to Escherichia coli

Software implementation


tgvaughan.github.io/bacter

  • BEAST 2 package that performs inference under the ClonalOrigin model.
  • Joint inference of the clonal frame, recombinant edges and parameters.
  • Can be combined with usual variety of substitution models, parametric population models and parameter priors.
  • GUI analysis configuration via BEAUti.

Recombination and Demographic Inference



  • Relationship used by Li and Durbin, 2011 to infer human demographic history from pairs of autosomes.

Bayesian Skyline Plots in Bacter

  • Bacter implements a non-parametric demographic history model inspired by the standard Bayesian Skyline Plot (Drummond et al., 2005).
  • In principle can reconstruct non-trivial dynamics from very few genomes.
  • In practice, this is limited by the computational expense of the algorithm.

Piecewise constant/linear population model

Inference example

Bacter limitations

  • Computational complexity scales with the number of proposed conversions.
    • This can be arbitrarily large, even for small sample sets.
    • Cannot use the BEAGLE phylogenetic likelihood library to speed things up due to peculiarities of ARG likelihood computation.

  • MCMC algorithm used does not intelligently locate conversions.
    • Looking at addressing this in the near future.

  • Network summary algorithm can produce peculiar results.
    • More research needs to be done to find a better algorithm.


Acknowledgements

  • Members of mEpiLab, Massey University, New Zealand
    • Patrick Biggs, Tessy George and Nigel French (providing hard-won data)

  • Members of the Centre for Computational Evolution, University of Auckland, New Zealand

  • The following organizations:


Slides of this talk are online at
tgvaughan.github.io/talks/PhyloSeminar17