- Matrix multiplication of
rvar
s can now be done with the base matrix multiplication operator (%*%
) instead of%**%
in R >= 4.3.
- Added support for nested-Rhat via
rhat_nested
(#256) - Added support for indexing draws in
rvar
s usingrvar
s (#282):x[i]
orx[i] <- y
wherei
is a scalar logicalrvar
slices (or updates)x
by its draws. Thus, ify <- x[i]
, theny
is the same shape asx
but withsum(i)
draws.x[[i]]
orx[[i]] <- y
wherei
is a scalar numeric rvar slices (or updates)x
by selecting thei
th element within each corresponding draw. Thus, ify <- x[[i]]
, theny
is anrvar
of length 1.
- Added
rvar_ifelse()
, which is a variant ofifelse()
that accepts (and returns)rvar
s (#282). - Array broadcasting for
rvar
s has been made faster.
- Ensure
rfun()
works with primitive functions (#290) and dots arguments (#291). - Provide implementations of
vctrs::vec_proxy_equal()
,vctrs::vec_proxy_compare()
, andvctrs::vec_proxy_order()
. - Minor future-proofing of
cbind(<rvar>)
,rbind(<rvar>)
, andchol(<rvar>)
for R 4.4 (#304). - Ensure that
bind_draws(<draws_rvars>)
regenerates draw ids when binding along chains or draws; this also fixes a bug insplit_chains(<draws_rvars>)
(#300).
- Delay applying
tibble::num()
formatting to output fromsummarise_draws()
untilprint()
is called so that summary output can be easily converted to a vanilla data frame (#275).
- Added new
rvar_factor()
andrvar_ordered()
subtypes ofrvar()
that work analogously tofactor()
andordered()
(#149). See the new section onrvar_factor
s invignette("rvar")
. - The
draws_df()
,draws_list()
, anddraws_rvars()
formats now support discrete variables stored asfactors
/ordered
s (orrvar_factor
s /rvar_ordered
s). If converted to formats that do not support discrete variables with named levels (draws_matrix()
anddraws_array()
), factor-like variables are converted tonumeric
s. - Made
match()
and%in%
generic and added support forrvar
s to both functions. - Added
modal_category()
,entropy()
, anddissent()
functions for summarizing discrete draws. - Allow lists of draws objects to be passed as the first argument to
bind_draws()
(#253). - Improving formatting of
summarise_draws
output viatibble::num
. print.rvar()
andformat.rvar()
now default to a smaller number of significant digits in more cases, including when printing in data frames. This is controlled by the new"posterior.digits"
option (seehelp("posterior-package")
).- Implemented faster
vec_proxy.rvar()
andvec_restore.rvar()
, improving performance ofrvar
s intibble
s (and elsewherevctrs
is used).
- Ensure that
as_draws_rvars()
preserves dimensions of length-1 arrays (#265). - Fix some minor compatibility issues with
rvar
,vctrs
,dplyr
, andggplot2
(#267, #269).
- Minor release that fixes some CRAN check failures.
- Implement
for_each_draw(x, expr)
, which executesexpr
once for each draw ofx
, exposing variables inx
as arrays of the shape implied by the indices in their names (#224). - Implement
subset_draws()
,thin_draws()
, andresample_draws()
forrvar
s (#225). - Allow
weights
to be optional inresample_draws()
(#225). - Add an implementation of
drop()
forrvar
s. - Speed up subsetting of
draws_list
objects. (#229, #250)
- Support remaining modes of
diag()
forrvar
s (#246). - Better parsing for named indices in
as_draws_rvars()
, including nested use of[
, likex[y[1],2]
(#243). - Allow 0-length
rvar
s withndraws() > 1
(#242). - Ensure 0-length
rvar
s can be cast todraws
formats (#242). - Don't treat length-1
rvar
s with more than 1 dimension as scalars when casting to other formats (#248).
- Improve the
mcse_sd
function to not make a normality assumption. (#232)
- Correctly transform lists of data.frames into
draws_list
objects. - Correctly drop variables on assigning
NULL
inmutate_variables
. (#222)
- support casting to/from
rvar
anddistributional::dist_sample
(#109)
- fix hidden variables in
bind_draws.draws_df
when binding more than two objects thanks to Jouni Helske (#204) - fix output of
pillar::glimpse()
when used on a data frame containingrvar
s (#210) - drop
"draws"
and"draws_df"
classes fromdraws_df
objects if meta data columns are removed by adplyr
operation (#202) - fix output of
print.draws_df()
on objects with unrepaired draws (#217) - ensure
variance()
works properly withsummarise_draws()
(#219)
- use
matrixStats
to speed up convergence functions (#190) andrvar
summaries (#200)
- ensure that
as_draws_rvars()
works on lists of lists (#192) - fix some vector recycling issues with
rvar_rng
(#195) - ensure that
subset_draws()
respects input variable order, thanks to Karl Dunkle Werner and Alexey Stukalov (#188)
- No longer check for constant-per-chain input in effective
sample size diagnostics as this is overly conservative
especially for
ess_tail
. (#198)
- ensure that all unit tests pass on all CRAN environments
- fix a problem that sometimes lead to
rvar
s being unnecessarily slow (#179)
- initial CRAN release
- beta release