Skip to contents

Getter for costs

Usage

get_costs(res, arm = NULL)

Arguments

res

A list of results returned by ce_markov.

arm

Optional treatment arm name or index.

Value

A numeric vector of total costs by treatment, or a single numeric value if arm is specified.

Examples

data(test_data)
res <- run_model(test_data)
get_costs(res)
#> without_drug    with_drug 
#>     9205.744    16977.576 
get_costs(res, "with_drug")
#> with_drug 
#>  16977.58