Bayesian Dynamic Energy Budget Modelling
Overview
Provides a Bayesian framework for Dynamic Energy Budget (DEB) modelling via 'Stan'. Implements the standard DEB model of Kooijman (2010, doi:10.1017/CBO9780511805400) as a state-space model with Hamiltonian Monte Carlo inference (Carpenter et al., 2017, doi:10.18637/jss.v076.i01). Includes individual-level growth models, growth-reproduction models, hierarchical multi-individual models with partial pooling, and toxicokinetic-toxicodynamic (TKTD) models for ecotoxicology following the DEBtox framework (Jager et al., 2006, doi:10.1007/s10646-006-0060-x). Supports prior specification from biological knowledge, convergence diagnostics (Vehtari et al., 2021, doi:10.1214/20-BA1221), posterior predictive checks, derived quantity estimation, and visualisation via 'ggplot2'.
Second-round JSS revision: diagnostics display polish, fully runnable
(toolchain-gated) examples, and replication / manuscript reproducibility
fixes.
print.bdeb_diagnostics()now prints a compact table by default, hiding the per-time-point latent states (x_sol[i,j],L_hat[i]); the newfull = TRUEargument restores the complete table (also available viasummary(x)$table).plot.bdeb_diagnostics()likewise hides the per-time-point latent states by default for a shorter, more readable R-hat / ESS plot; the newfull = TRUEargument plots every monitored quantity. The subtitle notes how many latent rows were hidden.bdeb_diagnose()and thebdeb_diagnosticsprint/summary/plot methods, plusbdeb_loo(),bdeb_derived()andbdeb_summary(), moved their examples from\dontrun{}to a cmdstanr-gated\donttest{}block, soexample()runs them when a CmdStan toolchain is available (mirroringbdeb_fit()).
Show all changes in 0.2.1Hide the rest of the changes in 0.2.1
plot_dose_response()now draws posterior-median EC50 (dashed red) and NEC (dotted green) reference lines, drops non-finite draws, and clips the view withcoord_cartesian()so degenerate draws no longer appear as vertical artefacts.- Replication material: a single-command
replicate_all.Rreproduces every manuscript figure, table and printed number in ~1 min from cached draws; every manuscript code listing is now executed and printed; outputs use a fixed seed for bit-identical reproduction; and the README maps every figure to the script that produces it.
From NEWS.md in the release
Install
Health
- OK13 OK2026-08-05
- NOTE12 OK, 1 NOTE2026-08-01
- OK11 OK2026-04-25
- NOTE6 OK, 2 NOTE2026-04-22
Documentation
- Help pages
- 65 (12 internal)includes a package overview page
- Examples that run
- 48%23 run in a plain check · 25 only when donttest examples are enabled (R CMD check --as-cran)
- Exported functions with examples
- 100%
- Documented parameters
- 100%
- Return-value docs
- 100%
- Help pages citing references
- 32%
Downloads
Repository
Forks over time
Releases over time
4 development-tooling and community-health practices detected across 3 families in the upstream repository
Checks run against github.com/sciom/bayesiandeb on 2026-10-22.
Dependencies
Code & Tests
Datasets
People & History
Pick two releases to compare their code metrics.
- 0.2.1Latest
- RR 4.6.0 released · 2026-04-24
- 0.1.42026-04-21
- RR 4.5.0 released · 2025-04-11
Package metadata
- First published
- 2026-04-21
- Total releases
- 2 / 1 yrs
- License
- MIT + file LICENSE OSI
- Additional repositories
- stan-dev.r-universe.dev
- Minimum R
- ≥ 4.1.0
- Bundled data
- 4.9 KB / 5 files
- Download size
- 2.0 MB
Cite
Cite this package
Run in R for the authors' entry:
citation("BayesianDEB")The package provides a citation file, so citation() returns the authors' own entry.
It points to 10.5281/zenodo.19443804, 10.1017/cbo9780511805400.
The repository also keeps a CITATION.cff.
Cite the R Observatory
For a number measured here: a download total, a coverage figure, an archival date.
From data release v2026-10-25, which the citation names so these numbers can be found later. More on citing and the projects behind them.