Bayesian Simultaneous Credible Bands for Polynomial Regression
Overview
Provides functions to construct two-sided Bayesian simultaneous credible bands (BSCBs) for the regression curve in univariate polynomial regression over a finite covariate interval. Six methods are implemented, including Normal-Gamma conjugate priors (with empirical Bayes, unit-information, and g-prior hyperparameter specifications), non-conjugate priors fitted via Hamiltonian Monte Carlo (HMC) using 'cmdstanr', and a non-informative independent Jeffreys prior approach. Also includes functions for computing the empirical simultaneous coverage rate (ESCR) and posterior simultaneous coverage probability (PSCP), enabling performance comparison across methods. The methodology is described in: Yang et al. (2026). "Bayesian simultaneous credible bands for polynomial regression" doi:10.48550/arXiv.2606.28015.
Changes
- Added Yang Han, Wei Liu, and Ian Hall as co-authors, reflecting their contributions to the methodology described in the accompanying paper (arXiv:2606.28015) as well as suggestions on optimize_function.R.
Features
- Implements six methods for constructing two-sided Bayesian simultaneous credible bands (BSCBs) for the regression curve in univariate polynomial regression over a finite covariate interval:
- Conjugate Normal-Gamma priors, with empirical Bayes, unit-information, and g-prior hyperparameter specifications
- Non-conjugate priors fitted via Hamiltonian Monte Carlo (HMC) using 'cmdstanr' (Normal-half-Normal and Normal-half-Cauchy priors)
Show all changes in 1.0.2Hide the rest of the changes in 1.0.2
- A non-informative independent Jeffreys prior approach
- Provides functions for evaluating and comparing method performance:
ESCR()for computing the empirical simultaneous coverage ratePSCP()for computing the posterior simultaneous coverage probability- Includes a vignette demonstrating usage and comparing methods.
Documentation
- The methodology is described in Yang, F., Han, Y., Liu, W., & Hall, I. (2026), "Bayesian Simultaneous Credible Bands for Polynomial Regression."
Bug fixes
- Fixed an issue where
generate_simulation_data()withdesign_index = 2(D-optimal design) could produce non-reproducible results even whenseedwas supplied. The underlying call toOptimalDesign::od_KL()previously relied on a time-based stopping rule (t.max), which made the number of completed restarts—and hence the result—dependent on machine speed. The search now stops after a fixed number of restarts (rest.max), ensuring full reproducibility given a fixedseed.
From NEWS.md in the release
Install
Health
- OK13 OK2026-08-05
- NOTE12 OK, 1 NOTE2026-08-01
- OK11 OK2026-07-13
- ERROR7 OK, 1 ERROR2026-07-11
Documentation
- Help pages
- 23
- Examples that run
- 38%3 run in a plain check · 5 only when donttest examples are enabled (R CMD check --as-cran)
- Exported functions with examples
- 35%
- Documented parameters
- 100%
- Return-value docs
- 100%
- Help pages citing references
- 0%
- BSCB-vignette HTML
Downloads
Repository
6 development-tooling and community-health practices detected across 5 families in the upstream repository
Checks run against github.com/fannyyang73/bscb on 2026-10-18.
Show all practicesHide 1 practice
Dependencies
Code & Tests
People & History
Package metadata
- First published
- 2026-07-10
- Total releases
- 3 / 1 yrs
- License
- MIT + file LICENSE OSI
- Additional repositories
- stan-dev.r-universe.dev
- Minimum R
- ≥ 4.0
- Download size
- 345 KB
Cite
Cite this package
Run in R for the authors' preferred citation:
citation("BSCB")This package has no citation file, so citation() returns this entry built from DESCRIPTION.
Cite the R Observatory
For a number measured here: a download total, a coverage figure, an archival date.
From data release v2026-10-20, which the citation names so these numbers can be found later. More on citing and the projects behind them.