Published May 6, 2026
| Version v0.3.0
Software
Open
FBartos/BayesTools: BayesTools 0.3.0
Authors/Creators
Description
Features
- major refactoring and speed-up of unit tests
- adds support for
__default_factorand__default_continuouspriors inJAGS_formula()- when specified in theprior_list, these are used as default priors for factor and continuous predictors that are not explicitly specified - adds automatic standardization of continuous predictors via
formula_scaleparameter inJAGS_formula()andJAGS_fit()- improves MCMC sampling efficiency and numerical stability - adds
transform_scale_samples()function to transform posterior samples back to original scale after standardization - adds
transform_prior_samples()function to generate and transform prior samples using the same matrix transformation as posterior samples - enables correct visualization of priors on the original (unscaled) predictor scale, including proper handling of the intercept which depends on multiple coefficient priors - adds
transform_scaledargument toplot_posterior()for visualizing prior and posterior distributions on the original (unscaled) scale when using formula-based models with auto-scaling - adds
exp_lintransformation type for log-intercept unscaling in density/plotting functions:exp(a + b * log(x)) - adds
log(intercept)formula attribute for specifying models of the formlog(intercept) + sum(beta_i * x_i)- useful for parameters that must be positive (e.g., standard deviation) while keeping the intercept on the original scale. Set viaattr(formula, "log(intercept)") <- TRUE. Supported inJAGS_formula(),JAGS_evaluate_formula(), and marginal likelihood computation - adds advanced parameter filtering options to
runjags_estimates_table():remove_parameters = TRUEto remove all non-formula parametersremove_formulasto remove all parameters from specific formulaskeep_parametersto keep only specified parameterskeep_formulasto keep only parameters from specified formulas- when
biasis specified inremove_parametersorkeep_parameters, the corresponding bias-related parameters (PET,PEESE,omega,alpha,pi_null, andphack_kind) are automatically included based on the bias prior type
- adds
probsargument torunjags_estimates_table()andrunjags_estimates_empty_table()for custom quantiles (default:c(0.025, 0.5, 0.975)) - adds
effect_directionargument toplot_posterior(),plot_prior_list(),lines_prior_list(), andgeom_prior_list()for PET-PEESE regression plots - use"positive"(default) formu + PET*se + PEESE*se^2or"negative"formu - PET*se - PEESE*se^2 - redesigns
prior_weightfunction()around a unifiedside,steps, andweightsspecification, withwf_cumulative(),wf_fixed(), andwf_independent()constructors for cumulative Dirichlet, fixed, independent, and log-independent weightfunction priors - adds p-hacking and composed selection-bias priors via
prior_phacking(),prior_bias(), calibration helpers, andselection_backend_spec()for compiling active step/p-hacking backend parameters - adds error % for inclusion BF calculation
Changes
- changes quantile column names in
runjags_estimates_table()andstan_estimates_table()fromlCI/Median/uCIto numeric values (e.g.,0.025/0.5/0.975) for consistency with ensemble summary tables - implied prior distributions for estimated marginal means, unstandardized coefficients, and PET-PEESE no longer require prior samples
- implied prior distributions for weightfunction weights now use analytical forms for cumulative Dirichlet, fixed, independent, and log-independent priors, including mixture and model-averaged weightfunctions where possible
- independent weightfunction priors now allow non-reference weights above one via non-negative omega-scale priors or unrestricted log-omega priors
- replaces the legacy dot-named weightfunction prior specifications with the unified weightfunction prior API and updates JAGS generation, marginal likelihood computation, posterior extraction, diagnostics, and summary tables to use the new component-local
omegarepresentation - composed selection-bias priors and publication-bias mixtures now support prior sampling and explicit unsupported-operation errors for ambiguous scalar prior generics
Fixes
- reports inclusion Bayes factors as
NAwhen the prior assigns probability 0 or 1 to inclusion, while keeping finite-sample bounds for posterior inclusion probabilities of 0 or 1 - fixes incorrect ordering the printed mixture priors
- fixes formula with no intercepts coded as
0(instead of only-1) - fixes bug in
.is.wholenumberwith NAs andna.rm = TRUE - fixes ggplot prior spike layers for marginal factor plots with density and point components
Files
FBartos/BayesTools-v0.3.0.zip
Files
(5.6 MB)
| Name | Size | Download all |
|---|---|---|
|
md5:83b8a01423e90bf63ea65e774260214f
|
5.6 MB | Preview Download |
Additional details
Related works
- Is supplement to
- Software: https://github.com/FBartos/BayesTools/tree/v0.3.0 (URL)
Software
- Repository URL
- https://github.com/FBartos/BayesTools