plot_ceac: Plot Cost-Effectiveness Acceptability Curve (CEAC)

View source: R/plot_ceac.R

plot_ceacR Documentation

Plot Cost-Effectiveness Acceptability Curve (CEAC)

Description

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.

Arguments

x

Either a result object from boot_icer(), or a formula of the form cost + effect ~ group or cost + effect ~ 1.

data

A data frame, required if x is a formula.

wtp_range

A numeric vector of WTP thresholds.

...

Additional arguments passed to ggplot2::labs().

Value

A ggplot object displaying the CEAC.

Examples

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)

ielbadisy/CEACT documentation built on June 11, 2025, 9:19 p.m.