Sample Size and Power Calculation for Bayesian Testing with Bayes Factor
Overview
The goal of 'BayesPower' is to provide tools for Bayesian sample size determination and power analysis across a range of common hypothesis testing scenarios using Bayes factors. The main function, BayesPower_BayesFactor(), launches an interactive 'shiny' application for performing these analyses. The application also provides command-line code for reproducibility. Details of the methods are described in the tutorial by Wong, Pawel, and Tendeiro (2025) doi:10.31234/osf.io/pgdac_v3.
- Improved the consistency between the documentation and their corresponding exported functions.
- Improved input validation in the Shiny app. For example, invalid sample-size inputs such as zero or negative values are now automatically adjusted to the smallest allowed value.
- Shiny app can be opened via "Addins" in the main tool bar for Rstudio users.
From NEWS.md in the release
Install
Health
- OK13 OK2026-08-05
- NOTE12 OK, 1 NOTE2026-08-01
- OK12 OK2026-04-25
- NOTE12 OK, 2 NOTE2026-04-22
- ERROR11 OK, 2 NOTE, 1 ERROR2026-04-18
Show 1 earlier changeHide 1 earlier change
- NOTE12 OK, 2 NOTE2026-03-10
Documentation
Downloads
Repository
- PRs merged (all time)
- 100%
- Median days to close, 50 most recently updated closed issues
- not measured
- Median days to close, 50 most recently updated closed PRs
- 0
Checks run against github.com/tkwong3004/bayespower on 2026-10-11.
No development-tooling practices detected in the upstream repository.
Dependencies
Code & Tests
People & History
- 1.0.5Latest
- RR 4.6.0 released · 2026-04-24
- 1.0.42026-04-13 · diff ↗
- 1.0.32026-03-16 · diff ↗
- 1.0.22026-02-12 · diff ↗ ·
removed 5 exports
BF10.t.test.one_sample, BF10.t.test.two_sample, BFpower.f, BFpower.t.test_one_sample, BFpower.t.test_two_sampleadded 5 exports
BF10.ttest.OneSample, BF10.ttest.TwoSample, BFpower.f.test, BFpower.ttest.OneSample, BFpower.ttest.TwoSample - 1.0.12025-10-29
- RR 4.5.0 released · 2025-04-11
Package metadata
- First published
- 2025-10-29
- Total releases
- 5 / 1 yrs
- License
- GPL (>= 3) OSI
- Download size
- 120 KB
Cite
Cite this package
Run in R for the authors' preferred citation:
citation("BayesPower")This is what citation() produces when a package has no citation file of its own. If it prints something else, use that.
Cite the R Observatory
For a number measured here: a download total, a coverage figure, an archival date.
From data release v2026-10-19, which the citation names so these numbers can be found later. More on citing and the projects behind them.