mbmm
Citation: A Mechanistic Bayesian Framework for Latent-State Inference in Vaccine and Infection Immunology
A general implementation of the Mechanistic Bayesian Mixture Model framework that embeds an application-specific ordinary differential equation trajectory model inside a Bayesian mixture likelihood evaluated against Approximate Bayesian Computation reference banks, with covariate-linked logistic or multinomial gates.
How this model is classified mathematically and dynamically.
- Model class
- Formalism
- Determinism
- Stochastic
- Time dynamics
- Continuous
- Spatial
- Non-spatial
- Multiscale
- No
Organisms, entities and processes this model represents.
- Organisms
- Not recorded
- Infectious agents
- Not recorded
- Health conditions
- Not recorded
- Biological processes
- Molecular entities
- Not recorded
- Proteins / genes
- Not recorded
The data this model consumes and produces when executed.
Parameters
| Name | Default | Unit | Meaning |
|---|---|---|---|
| beta | Not recorded | per day | infection rate |
| delta | 1 | per day | clearance rate |
| p | Not recorded | copies per milliliter per day | viral production rate |
| V0 | Not recorded | copies per milliliter | viral burden |
| offset | Not recorded | day | Days between model internal time origin and observed day 0. |
| T0 | 10000000 | dimensionless | target-cell count |
| k | 4 | per day | transition rate |
| c | 10 | per day | clearance rate |
| n_subjects | 90 | dimensionless | Total number of subjects in a synthetic cohort. |
| prevalence | 0.35 | dimensionless | probability measure |
Outputs
| Name | Quantity | Unit | Format |
|---|---|---|---|
| viral_load_trajectory | concentration | copies per milliliter | Not recorded |
| subject_observations | Named list of per-subject data frames containing time, observed value, censoring, and limit-of-detection columns. | Not recorded | Not recorded |
| mbmm_fit | Fitted class-conditional likelihoods and covariate-linked gate. | Not recorded | Not recorded |
Experiment protocol
A typical synthetic demonstration generates a cohort, simulates longitudinal viral-load observations over a 21-day schedule, scores observations against mechanistic reference banks, and fits a logistic or multinomial latent-state gate.
- Timestep
- 2 day
- Duration
- 21 day
- Observables
- viral loadbaseline antibodylatent productive-infection state
Runtime environment, dependencies, and compute requirements.
- Language
- R >= 4.0
- Environment
- native
The repository is an R package with exported functions and vignettes, not a standalone command-line simulator. The model is normally run by calling exported functions such as mbmm_abc_fit, mbmm, and mbmm_simulate_manuscript_demo.
Compute requirements
- GPU
- Not required
- Parallelism
- multi-process
Dependencies
- runtime
- stats
- graphics
- grDevices
- deSolve
- optional
- testthat >= 3.0.0
- knitr
- rmarkdown
- ggplot2
Containers
- docker · docker.io/mismplatform/envbuild@sha256:74aedef40d4abbc39476fe854a9739cd6c295523240c576be2591e62105758a0 · docker.io
Image approved · envbuild-agent · Oct 2026
Entry points
Rscript -e 'testthat::test_local()'verified by envbuild
R CMD check <PACKAGE_ROOT>Run the package checks and test suite.
- PACKAGE_ROOT
- Path to the package root
R CMD build <PACKAGE_ROOT>Build an R source package archive.
- PACKAGE_ROOT
- Path to the package root
RLoad mbmm and run the documented analysis workflows or vignettes interactively.
- -e
- Evaluate an R expression
Tests
testthatR CMD check <PACKAGE_ROOT>
Artifacts stored with this model.
Identifiers and integrity.
- Metadata review
- Approved · 1da614bf-946a-4400-a0be-4fd0f1d00f74 · Oct 2026
- Contacts
- Linh Do · thuylinh.do@duke.edu
- Bruce Rogers · bruce.rogers2@duke.edu
- Related
- Is described byurl:https://linhdo154.github.io/MBMM/articles/mbmm-intro.html
- Is described by
- External IDs
- url:https://github.com/linhdo154/MBMM