Skip to content

Releases: paul-buerkner/brms

brms 2.22.0

01 Oct 05:59
Compare
Choose a tag to compare

New Features

  • Support different Gaussian process kernels in gp terms. (#234)
  • Support stratified cox models via the new addition term bhaz. (#1489)
  • Support futures for parallelization in the cmdstanr backend. (#1684)
  • Add method loo_epred thanks to Aki Vehtari. (#1641)
  • Add priorsense support via create_priorsense_data.brmsfit
    thanks to Noa Kallioinen. (#1354)
  • Vectorize censored log likelihoods in the Stan code when possible. (#1657)
  • Force Stan to activate threading without altering the Stan code
    via argument force of function threading. (#1549)
  • Support moment matching loo prediction methods. (#1674)

Bug Fixes

  • Fix a bug that led to partially duplicated Stan code in multilevel terms
    thanks to Henrik Singmann. (#1651)
  • Fix problems with parallel executions of post-processing functions
    sometimes leaving unused R instances behind. Thanks to Andrew Johnson,
    Aki Vehtari, and Noa Kallioinen. (#1658)
  • Fix several minor bugs. (#1648, #1644, #1672, #1642, #1634, #1666, #1664)

Other Changes

  • Refactor some of the internal code base to avoid evaluating
    many data-dependent quantities several times. (#1653)
  • Smartly access internal functions when evaluating non-linear formulas. (#1635)
  • Improve the documentation in several places.
  • Make argument loo optional in loo_moment_match.
  • Change the output format of loo_predict and loo_linpred to be
    more consistent with other post-processing functions.

brms 2.21.0

23 Mar 06:47
Compare
Choose a tag to compare

New Features

  • Add experimental support for the pathfinder and laplace algorithms
    in the cmdstanr backend. (#1591)
  • Automatically recompute fit criteria previously stored in the model
    if potentially results-changing arguments are provided to the criterion method.
  • Allow to turn off automatic broadcasting of constant priors.
  • Allow for joint likelihood evaluation in kfold via argument joint.
  • Use several Stan built-in functions implemented since version 2.26
    to improve the efficiency of multiple model classes. (#1077)

Other Changes

  • Change make_stancode and make_standata to be aliases of stancode and
    standata, respectively. Change get_prior to be an alias of a new generic
    method default_prior. This enable other packages to define new stancode,
    standata and default_prior methods to generate Stan code and data, and extract
    the default priors, for their own objects building on brms. Thanks to Ven Popov
    for helping with this. (#1604)
  • Change the default prior of the shape parameter of negbinomial models
    to inv_gamma(0.4, 0.3) thanks to Aki Vehtari. (#1614)
  • No longer automatically canonicalize the Stan code if cmdstanr is used
    as backend. (#1544)
  • Export read_csv_as_stanfit thanks to Ven Popov. (#1619)
  • Make installation of shinystan optional. This means that the package has to
    be loaded, via library(shinystan), before launch_shinystan can be used. (#1595)
  • Improve parameter class names in the summary output.
  • Show histograms rather than densities in the plot method by default.
  • Deprecate argument N in the plot method in favor of argument nvariables.
  • Remove deprecated argument exact_loo in method kfold.

Bug Fixes

  • Remove some remaining uses of Stan's old array syntax.
  • Fix a bug in formula parsing of missing values terms with interactions
    thank to Guido Biele. (#1608)
  • Ensure compatibility of combine_models with moment matching. (#1603)
  • Ensure compatibility with the latest splines2 package version. (#1580)
  • Fix output of rmulti_normal thanks to Ven Popov. (#1588)
  • Prevent memory leaks when executing kfold or reloo in parallel.

brms 2.20.3

15 Sep 11:23
Compare
Choose a tag to compare

New Features

  • Apply the horseshoe and R2D2 priors globally, that is, for all additive predictor terms specified in the same formula. (#1492)
  • Use as.brmsprior to transform objects into a brmsprior. (#1491)
  • Use matrix data as non-linear covariates. (#1488)

Other Changes

  • Switch to the new array syntax of Stan. This increases the version requirements of Stan to >= 2.26.
  • No longer support the lasso prior as it is not a good shrinkage prior and incompatible with the newly implemented global shrinkage prior framework.
  • No longer support multiple deprecated prior options for categorical and multivariate models after around 3 years of deprecation. (#1420)
  • Deprecate argument newdata of get_refmodel.brmsfit(). (#1502)
  • Disallow binomial models without trials argument after several years of deprecation. (#1501)

Bug Fixes

  • Fix a long-standing bug in the post-processing of spline models that could lead to non-sensible results if predictions were performed on a different machine than where the model was originally fitted. Old spline models can be repaired via restructure. Special thanks to Simon Wood, Ruben Arslan, Marta Kołczyńska, Patrick Hogan, and Urs Kalbitzer. (#1465)
  • Fix a bunch of minor issues occurring for rare feature combinations.

brms 2.19.0

16 Mar 08:54
Compare
Choose a tag to compare

New Features

  • Model unstructured autocorrelation matrices via the unstr term
    thanks to the help of Sebastian Weber. (#1435)
  • Model ordinal data with an extra category (non-response or similar)
    via the hurdle_cumulative family thanks to Stephen Wild. (#1448)
  • Improve user control over model recompilation via argument recompile
    in post-processing methods that require a compiled Stan model.
  • Extend control over the point_estimate feature in prepare_predictions
    via the new argument ndraws_point_estimate.
  • Add support for the latent projection available in
    projpred versions >= 2.4.0. (#1451)

Bug Fixes

  • Fix a Stan syntax error in threaded models with lasso priors. (#1427)
  • Fix Stan compilation issues for some of the more special
    link functions such as cauchit or softplus.
  • Fix a bug for predictions in projpred, previously requiring more variables
    in newdata than necessary. (#1457, #1459, #1460)

brms 2.18.0

19 Sep 18:53
Compare
Choose a tag to compare

New Features

  • Support regression splines with fixed degrees of freedom specified via s(..., fx = TRUE).
  • Reuse user-specified control arguments originally passed to the Stan backend in update and related methods. (#1373, #1378)
  • Allow to retain unused factors levels via drop_unused_levels = FALSE in brm and related functions. (#1346)
  • Automatically update old default priors based on new input when when updating models via update.brmsfit. (#1380)
  • Allow to use dirichlet priors for more parameter types. (#1165)

Other Changes

  • Improve efficiency of converting models fitted with backend = "cmdstanr" to stanfit objects thanks to Simon Mills and Jacob Socolar. (#1331)
  • Allow for more O1 optimization of brms-generated Stan models thanks to Aki Vehtari. (#1382)

Bug Fixes

  • Fix problems with missing boundaries of sdme parameters in models with known response standard errors thanks to Solomon Kurz. (#1348)
  • Fix Stan code of gamma models with softplus link.
  • Allow for more flexible data inputs to brm_multiple. (#1383)
  • Ensure that control_params returns the right values for models fitted with the cmdstanr backend. (#1390)
  • Fix problems in multivariate spline models when using the subset addition term. (#1385)

brms 2.17.0

13 Apr 21:15
Compare
Choose a tag to compare

brms 2.17.0

New Features

  • Add full user control for boundaries of most parameters via the lb and ub arguments of set_prior and related functions. (#878, #1094)
  • Add family logistic_normal for simplex responses. (#1274)
  • Add argument future_args to kfold and reloo for additional control over parallel execution via futures.
  • Add families beta_binomial & zero_inflated_beta_binomial for potentially over-dispersed and zero-inflated binomial response models thanks to Hayden Rabel. (#1319 & #1311)
  • Display ppd_* plots in pp_check via argument prefix. (#1313)
  • Support the log link in binomial and beta type families. (#1316)

Other changes

  • Argument brms_seed has been added to get_refmodel.brmsfit(). (#1287)
  • Deprecate argument inits in favor of init for consistency with the Stan backends.
  • Improve speed of the summary method for high-dimensional models. (#1330)

Bug Fixes

  • Fix Stan code of threaded multivariate models thanks to Anirban Mukherjee. (#1277)
  • Fix usage of int_conditions in conditional_smooths thanks to Urs Kalbitzer. (#1280)
  • Fix an error sometimes occurring for multilevel (reference) models in projpred's K-fold CV. (#1286)
  • Fix response values in make_standata for bernoulli families when only 1s are present thanks to Facundo Munoz. (#1298)
  • Fix pp_check for censored responses to work for all plot types thanks to Hayden Rabel. (#1327)
  • Ensure that argument overwrite in add_criterion works as expected for all criteria thanks to Andrew Milne. (#1323)
  • Fix a problem in launch_shinystan occurring when warmup draws were saved thanks to Frank Weber. (#1257, #1329)
  • Fix numerical stability problems in log_lik for ordinal models. (#1192)

brms 2.16.1

24 Aug 15:17
Compare
Choose a tag to compare

Bug Fixes

  • Fix a bug causing problems during post-processing of models
    fitted with older versions of brms and the cmdstanr backend
    thanks to Riccardo Fusaroli. (#1218)

brms 2.16.0

20 Aug 15:13
Compare
Choose a tag to compare

New Features

  • Support several methods of the posterior package. (#1204)
  • Substantially extend compatibility of brms models
    with emmeans thanks to Mattan S. Ben-Shachar. (#907, #1134)
  • Combine missing value (mi) terms with subset addition terms. (#1063)
  • Expose function get_dpar for use in the post-processing
    of custom families thank to Martin Modrak. (#1131)
  • Support the squareplus link function in all families and
    distributional parameters that also allow for the log link function.
  • Add argument incl_thres to posterior_linpred.brmsfit() allowing to
    subtract the threshold-excluding linear predictor from the thresholds in case
    of an ordinal family. (#1137)
  • Add a "mock" backend option to facilitate testing
    thanks to Martin Modrak. (#1116)
  • Add option file_refit = "always" to always overwrite models
    stored via the file argument. (#1151)
  • Initial GPU support via OpenCL thanks to the help
    Rok Češnovar. (#1166)
  • Support argument robust in method hypothesis. (#1170)
  • Vectorize the Stan code of custom likelihoods via
    argument loop of custom_family. (#1084)
  • Experimentally allow category specific effects for
    ordinal cumulative models. (#1060)
  • Regenerate Stan code of an existing model via
    argument regenerate of method stancode.
  • Support expose_functions for models fitted with the
    cmdstanr backend thanks to Sebastian Weber. (#1176)
  • Support log_prob and related functionality in models fitted
    with the cmdstanr backend via function add_rstan_model. (#1184)

Other Changes

  • Remove use of cbind to express multivariate models after
    over two years of deprecation (please use mvbind instead).
  • Method posterior_linpred(transform = TRUE) is now equal
    to posterior_epred(dpar = "mu") and no longer deprecated.
  • Refactor and extend internal post-processing functions
    for ordinal and categorical models thanks to Frank Weber. (#1159)
  • Ignore NA values in interval censored boundaries as long as
    they are unused. (#1070)
  • Take offsets into account when deriving default priors
    for overall intercept parameters. (#923)
  • Soft deprecate measurement error (me) terms in favor
    of the more general and consistent missing value (mi) terms. (#698)

Bug Fixes

  • Fix an issue in the post-processing of non-normal ARMA models
    thanks to Thomas Buehrens. (#1149)
  • Fix an issue with default baseline hazard knots in cox models
    thanks to Malcolm Gillies. (#1143)
  • Fix a bug in non-linear models caused by accidental
    merging of operators in the non-linear formula
    thanks to Fernando Miguez. (#1142)
  • Correctly trigger a refit for file_refit = "on_change" if factor level
    names have changed thanks to Martin Modrak. (#1128)
  • Validate factors in validate_newdata even when they are simultaneously
    used as predictors and grouping variables thanks to Martin Modrak. (#1141)
  • Fix a bug in the Stan code generation of threaded mixture models
    with predicted mixture probabilities thanks to Riccardo Fusaroli. (#1150)
  • Remove duplicated Stan code related to the horseshoe prior
    thanks to Max Joseph. (#1167)
  • Fix an issue in the post-processing of non-looped non-linear
    parameters thanks to Sebastian Weber.
  • Fix an issue in the Stan code of threaded non-looped non-linear
    models thanks to Sebastian Weber. (#1175)
  • Fix problems in the post-processing of multivariate meta-analytic
    models that could lead to incorrect handling of known standard errors.

brms 2.15.0

14 Mar 16:58
Compare
Choose a tag to compare

New Features

  • Turn off normalization in the Stan model via argument normalize to increase sampling efficiency thanks to Andrew Johnson. (#1017, #1053)
  • Enable posterior_predict for truncated continuous models even if the required CDF or quantile functions are unavailable.
  • Update and export validate_prior to validate priors supplied by the user.
  • Add support for within-chain threading with rstan (Stan >= 2.25) backend.
  • Apply the R2-D2 shrinkage prior to population-level coefficients via function R2D2 to be used in set_prior.
  • Extend support for arma correlation structures in non-normal families.
  • Extend scope of variables passed via data2 for use in the evaluation of most model terms.
  • Refit models previously stored on disc only when necessary thanks to Martin Modrak. The behavior can be controlled via file_refit. (#1058)
  • Allow for a finer tuning of informational messages printed in brm via the silent argument. (#1076)
  • Allow stanvars to alter distributional parameters. (#1061)
  • Allow stanvars to be used inside threaded likelihoods. (#1111)

Other Changes

  • Improve numerical stability of ordinal sequential models (families sratio and cratio) thanks to Andrew Johnson. (#1087)

Bug Fixes

  • Allow fitting multinomial models with the cmdstanr backend thanks to Andrew Johnson. (#1033)
  • Allow user-defined Stan functions in threaded models. (#1034)
  • Allow usage of the : operator in autocorrelation terms.
  • Fix Stan code generation when specifying coefficient-level priors on spline terms.
  • Fix numerical issues occurring in edge cases during post-processing of Gaussian processes thanks to Marta Kołczyńska.
  • Fix an error during post-processing of new levels in multi-membership terms thanks to Guilherme Mohor.
  • Fix a bug in the Stan code of threaded wiener drift diffusion models thanks to the GitHub user yanivabir. (#1085)
  • Fix a bug in the threaded Stan code for GPs with categorical by variables thanks to Reece Willoughby. (#1081)
  • Fix a bug in the threaded Stan code when using QR decomposition thanks to Steve Bronder. (#1086)
  • Include offsets in emmeans related methods thanks to Russell V. Lenth. (#1096)

brms 2.14.11

11 Feb 09:25
Compare
Choose a tag to compare
brms 2.14.11 Pre-release
Pre-release

New Features

  • Turn off normalization in the Stan model via argument normalize.
    to increase sampling efficiency thanks to Andrew Johnson. (#1017, #1053)
  • Enable posterior_predict for truncated continuous models
    even if the required CDF or quantile functions are unavailable.
  • Update and export validate_prior to validate priors supplied by the user.
  • Add support for within-chain threading with rstan (Stan >= 2.25) backend.
  • Apply the R2-D2 shrinkage prior to population-level coefficients
    via function R2D2 to be used in set_prior.
  • Extend support for arma correlation structures in non-normal families.
  • Extend scope of variables passed via data2 for use in the
    evaluation of most model terms.

Other Changes

  • Improve numerical stability of ordinal sequential models
    (families sratio and cratio) thanks to Andrew Johnson. (#1087)

Bug Fixes

  • Allow fitting multinomial models with the
    cmdstanr backend thanks to Andrew Johnson. (#1033)
  • Allow user-defined Stan functions in threaded models. (#1034)
  • Allow usage of the : operator in autocorrelation terms.
  • Fix Stan code generation when specifying coefficient-level
    priors on spline terms.
  • Fix numerical issues occurring in edge cases during
    post-processing of Gaussian processes thanks to Marta Kołczyńska.
  • Fix an error during post-processing of new levels in
    multi-membership terms thanks to Guilherme Mohor.
  • Fix a bug in the Stan code of threaded wiener drift diffusion
    models thanks to the GitHub user yanivabir. (#1085)
  • Fix a bug in the threaded Stan code for GPs with categorical
    by variables thanks to Reece Willoughby. (#1081)
  • Fix a bug in the threaded Stan code when using QR decomposition
    thanks to Steve Bronder. (#1086)