v2.4.1
Major refactoring
Code base improved robustness and extensibility.
bcea()
is now a helper function which calls the constructornew_bcea()
, separating concerns.new_bcea()
composed of smaller HEE statistics functions with names starting withcompute_*
e.g.compute_CEAC()
,compute_EIB()
,.... This allows us to call and test them individually.
It also allows more flexibility in changing or adding functionality tonew_bcea()
.- Plotting functions have been rewritten. These functions now simply dispatch to the base R, ggplot2 or plotly versions (think strategy pattern).
Internally, these functions, e.g.ceplane_plot_ggplot()
, are also split into parameter and data setting and plotting components.
This modulisation allows us to add new layers to plots or modify existing parameter sets and defaults. We could also return the data without the plotting step as in e.g.ggplot2::autoplot()
.
It also means we can reuse some functionality across plots such as axes and legend setting e.g.BCEA:::where_legend()
. ceac_plot()
changes- Deprecated
mce.plot()
. Now dispatched onceac.plot()
for bothmulti.ce()
andbcea()
outputs. - For a multiple comparison the plot for pairwise comparison over all interventions is returned by default. The alternative version of each comparison against the reference group is still available.
- Plots and tables using S3 methods for
bcea
type object.
- Deprecated
- Tables updated. Duplication in
summary()
andsim_table()
removed. createInputs()
used for EVPI calculation now dispatches S3 methods by JAGS, BUGS, Stan and other R data types.make.report()
rewritten to have separate section files.
New features
- Extend ways to set comparison interventions. Subsets of comparison can still be set in a call to a plotting function as before.
Now subsets can be set in both the originalbcea()
construction or separately using a setter functionssetComparisons()
. - Similarly, maximum willingness to pay and the reference group can be set with
setKmax()
andsetReferenceGroup()
, respectively. multi.ce()
andCEriskAv()
also now work similarly. They operate by modifying thebcea
object, rather than creating new one (think decorator pattern).bcea()
methods for jags, WinBUGS, Stan (#76)
Miscellaneous
- Additional help documentation and examples.
- New vignettes about plotting and comparison intervention setting.
- Testing suite started. This is not comprehensive as of yet.
- Added a
NEWS.md
file to track changes to the package. Details about previous releases, such as dates, versions, fixes and enhancements obtained from CRAN and code comments so a little patchy. pkgdown
GitHub site made.- Cheatsheet written and published on RStudio site (#22).
- Dependency package ldr removed from BCEA because it was removed from CRAN (#74)