calculate_ceac_mult: Calculate cost-effectiveness probabilities.

calculate_ceac_multR Documentation

Calculate cost-effectiveness probabilities.

Description

This function calculates the probabilities that each strategy is the cost effective at different willingness to pay thresholds, for an infinite amount of strategies.

Usage

calculate_ceac_mult(
  df,
  outcomes,
  costs,
  v_wtp = seq(from = 0, to = 1e+05, by = 1000)
)

Arguments

df

a dataframe.

outcomes

character. Vector of variable names containing the outcomes to be plotted on the x-axis. The variable names should be structured as follows: 't_qaly_d_' followed by the name of the strategy: e.g. 't_qaly_d_intervention'.

costs

character. Vector of variable names containing the costs to be plotted on the y-axis. The variable names should be structured as follows: 't_costs_d_' followed by the name of the strategy: e.g. 't_costs_d_intervention'.

v_wtp

vector of numerical values. Vector of willingness-to-pay threshold for which the probabilities of cost effectiveness have to be defined. Default is 0:100,000 by increments of 1,000.

Value

A dataframe with three columns:

  • WTP_threshold = The willingness-to-pay thresholds at which the probability of cost effectiveness has been calculated for both strategies

  • Prob_int = The probability that the intervention strategy is cost effective at a given willingness-to-pay threshold

  • Prob_comp = The probability that the comparator strategy is cost effective at a given willingness-to-pay threshold

Examples

# Calculate probabilities of cost effectiveness using the example dataframe,
data("df_pa")
df_pa$t_qaly_d_int2 <- df_pa$t_qaly_d_int * 1.5 # creating additional outcome variable
df_pa$t_costs_d_int2 <- df_pa$t_costs_d_int * 1.5 # creating additional cost variable
calculate_ceac_mult(df = df_pa,
             outcomes = c("t_qaly_d_int", "t_qaly_d_comp", "t_qaly_d_int2"),
             costs = c("t_costs_d_int","t_costs_d_comp", "t_costs_d_int2")
             )

Xa4P/pacheck documentation built on April 14, 2025, 1:51 p.m.