Obtain estimated hazard ratios in a tidy data frame from a surv_ate object and compare them to benchmark hazard ratios (e.g., from target randomized clinical trials). Quickly plot comparisons of the estimated hazard ratios to the benchmarks using autoplot(). Generate a pretty HTML table with 95 percent confidence intervals using html_table().

benchmark_hazard_ratios(
  object,
  benchmarks = NULL,
  benchmark_estimate = "estimate",
  benchmark_lower = "lower",
  benchmark_upper = "upper"
)

# S3 method for benchmarked_hazard_ratios
autoplot(
  object,
  xlab = "Benchmark hazard ratio",
  ylab = "Estimated hazard ratio",
  scale_breaks = seq(0.4, 2, 0.2),
  ...
)

# S3 method for benchmarked_hazard_ratios
html_table(x, ...)

Arguments

object

A surv_ate object.

benchmarks

A data frame containing benchmark hazard ratios, potentially by group. It must

benchmark_lower

The column identifier for the lower confidence limit of the benchmark hazard ratio.

benchmark_upper

The column identifier for the upper confidence limit of the benchmark hazard ratio.

becnhmark_estimate

The column identifier for the benchmark hazard ratio estimate.

Value

A hazard_ratio object that inherits from dplyr::tibble.