Skip to main page content
U.S. flag

An official website of the United States government

Dot gov

The .gov means it’s official.
Federal government websites often end in .gov or .mil. Before sharing sensitive information, make sure you’re on a federal government site.

Https

The site is secure.
The https:// ensures that you are connecting to the official website and that any information you provide is encrypted and transmitted securely.

Access keys NCBI Homepage MyNCBI Homepage Main Content Main Navigation
. 2022 Mar 4;38(6):1770-1772.
doi: 10.1093/bioinformatics/btac004.

Implementation of a practical Markov chain Monte Carlo sampling algorithm in PyBioNetFit

Affiliations

Implementation of a practical Markov chain Monte Carlo sampling algorithm in PyBioNetFit

Jacob Neumann et al. Bioinformatics. .

Abstract

Summary: Bayesian inference in biological modeling commonly relies on Markov chain Monte Carlo (MCMC) sampling of a multidimensional and non-Gaussian posterior distribution that is not analytically tractable. Here, we present the implementation of a practical MCMC method in the open-source software package PyBioNetFit (PyBNF), which is designed to support parameterization of mathematical models for biological systems. The new MCMC method, am, incorporates an adaptive move proposal distribution. For warm starts, sampling can be initiated at a specified location in parameter space and with a multivariate Gaussian proposal distribution defined initially by a specified covariance matrix. Multiple chains can be generated in parallel using a computer cluster. We demonstrate that am can be used to successfully solve real-world Bayesian inference problems, including forecasting of new Coronavirus Disease 2019 case detection with Bayesian quantification of forecast uncertainty.

Availability and implementation: PyBNF version 1.1.9, the first stable release with am, is available at PyPI and can be installed using the pip package-management system on platforms that have a working installation of Python 3. PyBNF relies on libRoadRunner and BioNetGen for simulations (e.g. numerical integration of ordinary differential equations defined in SBML or BNGL files) and Dask.Distributed for task scheduling on Linux computer clusters. The Python source code can be freely downloaded/cloned from GitHub and used and modified under terms of the BSD-3 license (https://github.com/lanl/pybnf). Online documentation covering installation/usage is available (https://pybnf.readthedocs.io/en/latest/). A tutorial video is available on YouTube (https://www.youtube.com/watch?v=2aRqpqFOiS4&t=63s).

Supplementary information: Supplementary data are available at Bioinformatics online.

PubMed Disclaimer

Figures

Fig. 1.
Fig. 1.
A comparison of selected marginal posteriors was obtained using PyBNF’s am method (blue) and the problem-specific code of Lin et al. (2021; light red). Dark red indicates overlap. The inference problem is that considered in Supplementary Figure S7, which is related to a forecast of COVID-19 incidence for the metropolitan statistical area encompassing Los Angeles, CA. Nomenclature is the same as that of Lin et al. (2021)

Similar articles

Cited by

References

    1. Andrieu C. et al. (2003) An introduction to MCMC for machine learning. Mach. Learn., 50, 5–43.
    1. Andrieu C., Thoms J. (2008) A tutorial on adaptive MCMC. Stat. Comput., 18, 343–373.
    1. Choi K. et al. (2018) Tellurium: an extensible python-based modeling environment for systems and synthetic biology. Biosystems, 171, 74–79. - PMC - PubMed
    1. Eydgahi H. et al. (2013) Properties of cell death models calibrated and compared using Bayesian approaches. Mol. Syst. Biol., 9, 644. - PMC - PubMed
    1. Faeder J.R. et al. (2009) Rule-based modeling of biochemical systems with BioNetGen. Methods Mol. Biol., 500, 113–167. - PubMed

Publication types