- src/Makevars{.win} now uses a more robust way to find StanHeaders
compare_models
is deprecated in favor ofloo_compare
- The
kfold
method now has acores
argument and parallelizes by fold rather than by Markov chain (unless otherwise specified), which should be much more efficient when many cores are available. - Fixed bug where
ranef()
andcoef()
methods forglmer
-style models printed the wrong output for certain combinations of varying intercepts and slopes.
stan_clogit()
now works even when there are no common predictorsprior.info()
works better with models produced bystan_jm()
andstan_mvmer()
stan_glm()
(only) gets amean_PPD
argument that whenFALSE
avoids drawing from the posterior predictive distribution in the Stan codeposterior_linpred()
now works even if the model was estimated withalgorithm = "optimizing"
stan_jm()
andstan_mvmer()
now correctly include the intercept in the longitudinal submodel
-
Compatible with loo package version
>= 2.0
-
QR = TRUE
no longer ignores theautoscale
argument and has better behavior whenautoscale = FALSE
-
posterior_linpred()
now has a draws argument like forposterior_predict()
-
Dynamic predictions are now supported in
posterior_traj()
forstan_jm
models. -
More options for K-fold CV, including manually specifying the folds or using helper functions to create them for particular model/data combinations.
Minor release for build fixes for Solaris and avoiding a test failure
Lots of good stuff in this release.
stan_polr()
andstan_lm()
handle theK = 1
case better
-
The prior_aux arguments now defaults to exponential rather than Cauchy. This should be a safer default.
-
The Stan programs do not drop any constants and should now be safe to use with the bridgesampling package
-
hs()
andhs_plus()
priors have new defaults based on a new paper by Aki Vehtari and Juho Piironen -
stan_gamm4()
is now more closely based onmgcv::jagam()
, which may affect some estimates but the options remain largely the same -
The
product_normal()
prior permitsdf = 1
, which is a product of ... one normal variate -
The build system is more conventional now. It should require less RAM to build from source but it is slower unless you utilize parallel make and LTO
-
stan_jm()
andstan_mvmer()
contributed by Sam Brilleman -
bayes_R2()
method to calculate a quantity similar to$R^2$ -
stan_nlmer()
, which is similar tolme4::nlmer
but watch out for multimodal posterior distributions -
stan_clogit()
, which is similar tosurvival::clogit
but accepts lme4-style group-specific terms -
The
mgcv::betar
family is supported for the lme4-like modeling functions, allowing for beta regressions with lme4-style group terms and / or smooth nonlinear functions of predictors
-
Fix to
stan_glmer()
Bernoulli models with multiple group-specific intercept terms that could result in draws from the wrong posterior distribution -
Fix bug with contrasts in
stan_aov()
(thanks to Henrik Singmann) -
Fix bug with
na.action
instan_glmer()
(thanks to Henrik Singmann)
Minor release with only changes to allow tests to pass on CRAN
-
Fix for intercept with identity or square root link functions for the auxiliary parameter of a beta regression
-
Fix for special case where only the intercepts vary by group and a non-default prior is specified for their standard deviation
-
Fix for off-by-one error in some lme4-style models with multiple grouping terms
-
New methods
loo_linpred()
,loo_pit()
,loo_predict()
, andloo_predictive_interval()
-
Support for many more plotfuns in
pp_check()
that are implemented in the bayesplot package -
Option to compute latent residuals in
stan_polr()
(Thanks to Nate Sanders) -
The pairs plot now uses the ggplot2 package
-
VarCorr()
could return duplicates in cases where astan_{g}lmer
model used grouping factor level names with spaces -
The pairs()
function now works with group-specific parameters -
The
stan_gamm4()
function works better now -
Fix a problem with factor levels after estimating a model via
stan_lm()
-
New model-fitting function(s)
stan_betareg()
(andstan_betareg.fit()
) that uses the same likelihoods as those supported by thebetareg()
function in the betareg package (Thanks to Imad Ali) -
New choices for priors on coefficients:
laplace()
,lasso()
,product_normal()
-
The
hs()
andhs_plus()
priors now have newglobal_df
andglobal_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 have gained an
autoscale
argument that defaults toTRUE
and indicates that rstanarm should make internal changes to the prior based on the scales of the variables so that they default priors are weakly informative -
The new
compare_models()
function does more extensive checking that the models being compared are compatible
- The
prior_ops
argument to various model fitting functions is deprecated and replaced by a theprior_aux
argument for the prior on the auxiliary parameter of various GLM-like models
- Fix bug in
reloo()
if data was not specified - Fix bug in
pp_validate()
that was only introduced on GitHub
-
Uses the new bayesplot and rstantools R packages
-
The new
prior_summary()
function can be used to figure out what priors were actually used -
stan_gamm4()
is better implemented, can be followed byplot_nonlinear()
,posterior_predict()
(with newdata), etc. -
Hyperparameters (i.e. covariance matrices in general) for lme4 style models are now returned by
as.matrix()
andas.data.frame()
-
pp_validate()
can now be used if optimization or variational Bayesian inference was used to estimate the original model
-
Fix for bad bug in
posterior_predict()
when factor labels have spaces in lme4-style models -
Fix when weights are used in Poisson models
posterior_linpred()
gains anXZ
argument to output the design matrix
- Requiring manually specifying offsets when model has an offset and newdata is not NULL
-
stan_biglm()
function that somewhat supportsbiglm::biglm
-
as.array()
method for stanreg objects
- Works with devtools now
-
k_threshold
argument toloo()
to do PSIS-LOO+ -
kfold()
for K-fold CV -
Ability to use sparse X matrices (slowly) for many models if memory is an issue
-
posterior_predict()
with newdata now works correctly for ordinal models -
stan_lm()
now works when intercept is omitted -
stan_glmer.fit()
no longer permit models with duplicative group-specific terms since they don't make sense and are usually a mistake on the user's part -
posterior_predict()
with lme4-style models no longer fails if there are spaces or colons in the levels of the grouping variables -
posterior_predict()
with ordinal models outputs a character matrix now
-
pp_validate()
function based on the BayesValidate package by Sam Cook -
posterior_vs_prior()
function to visualize the effect of conditioning on the data -
Works (again) with R versions back to 3.0.2 (untested though)
-
Fix problem with models that had group-specific coefficients, which were mislabled. Although the parameters were estimated correctly, users of previous versions of rstanarm should run such models again to obtain correct summaries and posterior predictions. Thanks to someone named Luke for pointing this problem out on stan-users.
-
Vignettes now view correctly on the CRAN webiste thanks to Yihui Xie
-
Fix problem with models without intercepts thanks to Paul-Christian Buerkner
-
Fix problem with specifying binomial 'size' for posterior_predict using newdata
-
Fix problem with lme4-style formulas that use the same grouping factor multiple times
-
Fix conclusion in rstanarm vignette thanks to someone named Michael
-
Group-specific design matrices are kept sparse throughout to reduce memory consumption
-
The
log_lik()
function now has anewdata
argument -
New vignette on hierarchical partial pooling
Initial CRAN release