PhenoPath learns genomic trajectories (pseudotimes) in the presence of heterogenous environmental and genetic backgrounds encoded as additional covariates and identifies interactions between the trajectories and covariates. Scalable variational Bayesian inference allows the trajectory and interactions to be inferred for thousands of samples and genes quickly.

Build Status

To quickly get started, see either of the vignettes:


install.packages("devtools") # If not already installed
devtools::install_github("kieranrcampbell/phenopath", build_vignettes = TRUE)


PhenoPath models the observed expression y in terms of a latent pathway score (pseudotime) z. Uniquely, the evolution of genes along the trajectory isn't common to each gene but can be perturbed by an additional sample-specific covariate. For example, this could be the mutational status of each sample or a drug that each sample was exposed to.


Inference is performed using co-ordinate ascent variational inference (CAVI) implemented using the Rcpp library for increased performance. This minimises the KL-divergence between a set of approximating distributions and the true posterior by making a full-factorized mean-field approximation.

Getting started

See the vignette for details.


Kieran R Campbell & Christopher Yau

Try the phenopath package in your browser

Any scripts or data that you put into this service are public.

phenopath documentation built on May 2, 2018, 3:34 a.m.