Rstanarm Versions Save

rstanarm R package for Bayesian applied regression modeling

v2.32.1

3 months ago

What's Changed

Full Changelog: https://github.com/stan-dev/rstanarm/compare/v2.26.1...v2.32.1

v2.26.1

8 months ago

This release updates rstanarm to use the latest syntax supported by rstan.

What's Changed

Full Changelog: https://github.com/stan-dev/rstanarm/compare/v2.21.3...v2.26.1

v2.21.3

2 years ago

Bug fixes

  • Fix bug where loo() with k_threshold argument specified would error if the model formula was a string instead of a formula object. (#454)

  • Fix bug where loo() with k_threshold argument specified would error for models fit with stan_polr(). (#450)

  • Fix bug where stan_aov() would use the wrong singular.ok logic. (#448)

  • Fix bug where contrasts info was dropped when subsetting the model matrix in stan_glm(). (#459)

  • Fix bug where stan_glmer() would error if prior_aux=NULL. (#482)

  • posterior_predict() and posterior_epred() don't error with newdata for intercept only models by allowing data frames with 0 columns and multiple rows. (#492)

New features

  • New vignette on AB testing. (#409)

  • stan_jm() gains an offset term for the longitudinal submodel. (#415, @pamelanluna)

  • Effective number of parameters are computed for K-fold CV not just LOO CV. (#462)

  • stan_clogit() now allows outcome variable to be a factor. (#520)

v2.21.1

3 years ago

rstanarm 2.21.1

Backwards incompatible changes

  • stan_jm() is not available for 32bit Windows

  • Some improvements to prior distributions, as described in detail in the vignette Prior Distributions for rstanarm Models and book Regression and Other Stories. These changes shouldn't cause any existing code to error, but default priors have changed in some cases:

    • default prior on intercept is still Gaussian but the way the location and scale are determined has been updated (#432)
    • autoscale argument to functions like normal(), student_t(), etc., now defaults to FALSE except when used by default priors (default priors still do autoscalinng). This makes it simpler to specify non-default priors. (#432)

Bug fixes

  • Fixed error in kfold() for stan_gamm4() models that used random argument (#435)
  • Fixed error in posterior_predict() and posterior_linpred() when using newdata with family = mgcv::betar (#406, #407)
  • singular.ok now rules out singular design matrices in stan_lm() (#402)
  • Fix a potential error when data is a data.table object (#434, @danschrage)

New functions

  • New method posterior_epred() returns the posterior distribution of the conditional expectation, which is equivalent to (and may eventually entirely replace) setting argument transform=TRUE with posterior_linpred(). (#432)

  • Added convenience functions logit() and invlogit() that are just wrappers for qlogis() and plogis(). These were previously provided by the arm package. (#432)

v2.19.2

4 years ago

rstanarm version 2.19.2 is now on CRAN. Binaries have been built so it should be possible to install via

install.packages("rstanarm")

Release notes are available on the rstanarm website at http://mc-stan.org/rstanarm/news/

v2.14.1

7 years ago

Bug fixes

  • VarCorr could return duplicates in cases where a stan_{g}lmer model used grouping factors with spaces. This is now fixed.
  • The pairs function now also allows with group-specific parameters
  • The stan_gamm4 function works better now (see issues #136, #132)
  • Fix a problem with factor levels after estimating a model via stan_lm

New features

  • New model-fitting function stan_betareg (and stan_betareg.fit) that uses the same likelihoods as those supported by the betareg function in the betareg package
  • New choices for priors on regression coefficients: laplace, lasso, product_normal
  • The hs and hs_plus priors now have new global_df and global_scale arguments
  • stan_{g}lmer models that only have group-specific intercept shifts are considerably faster now
  • Models with Student t priors and low degrees of freedom (that are not 1, 2, or 4) may work better now due to Cornish-Fisher transformations
  • Many functions for priors (e.g., normal, student_t, etc.) have gained an autoscale argument that defaults to TRUE and indicates that rstanarm should make internal changes to the prior based on the scales of the variables. This doesn't change previous behavior, just replaces the former mechanism for controlling this (used to be the scaled argument to the now deprecated prior_options function).
  • The new compare_models function is a wrapper for loo::compare that does more extensive checking that the rstanarm models being compared are compatible
  • New prior_aux argument allow specifying priors for auxiliary parameters. Previously it was only possible to set the scale for the prior on auxiliary parameters (e.g., residual sd for Gaussian, shape for Gamma, etc.). With the prior_aux argument it is now possible to use exponential, normal, student_t, or cauchy for auxiliary parameters.

Deprecated arguments

  • The prior_ops argument to various model fitting functions is deprecated and the prior_options function used to specify the prior_ops argument is also depredated. The functionality of prior_options has been replaced by the autoscale argument to the functions for setting priors as well as the prior_aux argument for for the prior on the auxiliary parameter of various GLM-like models.

v2.13.1

7 years ago