plot_ceac | R Documentation |
This function plots the CEAC, which displays the probability that an intervention is cost-effective compared to a reference, across a range of willingness-to-pay (WTP) thresholds.
x |
Either a result object from |
data |
A data frame, required if |
wtp_range |
A numeric vector of WTP thresholds. |
... |
Additional arguments passed to |
A ggplot
object displaying the CEAC.
set.seed(123)
df <- data.frame(
c = c(rnorm(100, 500, 100), rnorm(100, 200, 100)),
e = c(rnorm(100, 0.6, 0.05), rnorm(100, 0.65, 0.06)),
g = rep(c("control", "treatment"), each = 100)
)
res <- boot_icer(c + e ~ g, data = df, ref = "control", R = 500)
plot_ceac(res, wtp_range = seq(0, 20000, 500))
plot_ceac(c + e ~ 1, data = df)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.