br_group {brisk} | R Documentation |
Posterior Samples for a Benefit/Risk Group
Description
Posterior Samples for a Benefit/Risk Group
Usage
br_group(label, ...)
Arguments
label |
a string indicating the name of the group. |
... |
named arguments which correspond to the names of the
benefits/risks specified by |
Details
This function is intended to be used as an input argument to
the br()
function.
Value
A named list with the posterior samples and an assigned S3 class.
Examples
set.seed(1132)
out <- br(
benefit("CV", function(x) x, weight = 1),
risk("DVT", function(x) - .5 * x, weight = 1),
br_group(
label = "PBO",
CV = rnorm(1e4, .1),
DVT = rnorm(1e4, .1)
),
br_group(
label = "TRT",
CV = rnorm(1e4, 2),
DVT = rnorm(1e4, 1)
)
)
out
summary(out, probs = c(.025, .5, .975))
summary(out, reference = "PBO")
plot(out)
# adjusted relative to PBO
plot(out, reference = "PBO")
plot_utility(out)
plot_utility(out, reference = "PBO")
plot_utility(out, stacked = TRUE)
[Package brisk version 0.1.0 Index]