Package 'BCEAweb'

Title: BCEA web app
Description: Bayesian Cost Effectiveness Analysis (BCEA) web app using Shiny.
Authors: Gianluca Baio [aut, cre, cph] (ORCID: <https://orcid.org/0000-0003-4314-2570>), Andrea Berardi [aut] (ORCID: <https://orcid.org/0000-0002-2906-496X>), Anna Heath [aut] (ORCID: <https://orcid.org/0000-0002-7263-4251>), Nathan Green [aut] (ORCID: <https://orcid.org/0000-0003-2745-1736>)
Maintainer: Gianluca Baio <[email protected]>
License: GPL (>= 3)
Version: 0.0.0.9001
Built: 2026-05-25 07:52:22 UTC
Source: https://github.com/giabaio/BCEAweb

Help Index


BCEAweb

Description

Launches the web-app

Usage

BCEAweb(e = NULL, c = NULL, parameters = NULL, launch.browser = TRUE, ...)

Arguments

e

A matrix containing the simulations for the effectiveness variable (with number of simulation rows and number of interventions columns). Defaults at NULL, which means the user has to load their own values using the web-interface

c

A matrix containing the simulations for the cost variable (with number of simulation rows and number of interventions columns). Defaults at NULL, which means the user has to load their own values using the web-interface

parameters

A matrix with the simulations for all the relevant model parameters. Defaults at NULL, which means the user has to load their own values using the web-interface

launch.browser

Defaults to TRUE, but can be specified to open inside Rstudio (e.g. launch.browser=rstudioapi::viewer)

...

Additional parameters.

Author(s)

Gianluca Baio

References

Baio, G., Dawid, A. P. (2011). Probabilistic Sensitivity Analysis in Health Economics. Statistical Methods in Medical Research doi:10.1177/0962280211419832.

Baio G. (2012). Bayesian Methods in Health Economics. CRC/Chapman Hall, London

See Also

bcea

Examples

## Not run: 
data(Vaccine)
BCEAweb(eff,cost,vaccine_mat)

## End(Not run)

Internal launch function

Description

Internal launch function

Usage

launch(e, c, parameters, launch.browser = TRUE, ...)

Arguments

e

A matrix containing the simulations for the effectiveness variable (with number of simulation rows and number of interventions columns). Defaults at NULL, which means the user has to load their own values using the web-interface

c

A matrix containing the simulations for the cost variable (with number of simulation rows and number of interventions columns). Defaults at NULL, which means the user has to load their own values using the web-interface

parameters

A matrix with the simulations for all the relevant model parameters. Defaults at NULL, which means the user has to load their own values using the web-interface

launch.browser

Defaults to TRUE, but can be specified to open inside Rstudio (e.g. launch.browser=rstudioapi::viewer)

...

Additional parameters.

Value

runApp


Make Report

Description

Constructs the automated report from the output of the BCEA.

Usage

make.report(he, evppi = NULL, ext = "pdf", echo = FALSE, ...)

Arguments

he

A bcea object containing the results of the Bayesian modelling and the economic evaluation.

evppi

An object obtained as output to a call to evppi (default is NULL, so not essential to producing the report).

ext

A string of text to indicate the extension of the resulting output file. Possible options are "pdf", "docx". This requires the use of pandoc, knitr and rmarkdown.

echo

A string (default to FALSE) to instruct whether the report should also include the BCEA commands used to produce the analyses. If the optional argument echo is set to TRUE (default = FALSE), then the commands are also printed.

...

Additional parameters. For example, the user can specify the value of the willingness to pay wtp, which is used in some of the resulting analyses (default at the break even point). Another additional parameter that the user can specify is the name of the file to which the report should be written. This can be done by simply passing the optional argument filename="NAME". The user can also specify an object including the PSA simulations for all the relevant model parameters. If this is passed to the function (in the object psa_sims), then make.report will automatically construct an "Info-rank plot", which is a probabilistic form of tornado plot, based on the Expected Value of Partial Information. The user can also specify the optional argument show.tab (default=FALSE); if set to TRUE, then a table with the values of the Info-rank is also shown.

Author(s)

Gianluca Baio

References

Baio, G., Dawid, A. P. (2011). Probabilistic Sensitivity Analysis in Health Economics. Statistical Methods in Medical Research doi:10.1177/0962280211419832.

Baio G. (2012). Bayesian Methods in Health Economics. CRC/Chapman Hall, London

Baio G., Heath, A., Berardi, A. and Green, N. (2025). Bayesian Cost-Effectiveness Analysis with the R package BCEA (2nd Edition). Springer

See Also

BCEA::bcea()

Examples

## Not run: 
  data(Vaccine, package = "BCEA")
  m <- bcea(eff, cost, ref = 2)
  make.report(m)

## End(Not run)

Smoking Cessation Cost-Effectiveness Data

Description

This data set contains the results of a Bayesian analysis modeling the clinical outputs and costs for an economic evaluation of four different smoking cessation interventions.

Format

A list containing the variables for the cost-effectiveness analysis:

cost

A matrix of 500 simulations from the posterior distribution of the overall costs for the four strategies.

data

A dataset with characteristics of smokers in the UK population.

eff

A matrix of 500 simulations from the posterior distribution of the clinical benefits for the four strategies.

life.years

A matrix of 500 simulations from the posterior distribution of the life years gained with each strategy.

pi_post

A matrix of 500 simulations from the posterior distribution of the probability of smoking cessation with each strategy.

smoking

A data frame with inputs for the network meta-analysis, containing: nobs (record ID), s (study ID), i (intervention ID), r_i (number of patients who quit), n_i (total patients in arm), and b_i (reference intervention for the study).

smoking_output

A matrix of results from the network meta-analysis model run on the smoking object.

treats

A character vector of labels for the four strategies.

Source

Effectiveness data adapted from Hasselblad V. (1998). "Meta-analysis of Multitreatment Studies". Medical Decision Making, 18:37-43.

Cost and population data adapted from various sources:

  • Taylor, D.H. Jr, et al. (2002). "Benefits of smoking cessation on longevity". American Journal of Public Health, 92(6).

  • Action on Smoking and Health (ASH) (2013). "ASH fact sheet on smoking statistics". https://ash.org/wp-content/uploads/2014/05/ASH-Annual-Report-2014.pdf.

  • Flack, S., et al. (2007). "Cost-effectiveness of interventions for smoking cessation". York Health Economics Consortium.

  • McGhan, W.F.D., and Smith, M. (1996). "Pharmacoeconomic analysis of smoking-cessation interventions". American Journal of Health-System Pharmacy, 53:45-52.

References

Baio G. (2012). Bayesian Methods in Health Economics. CRC/Chapman & Hall, London.


Smoking Cessation Example - Parameters

Description

This CSV file contains simulated parameter data for the Smoking Cessation example.

Format

A CSV file with 500 rows and 4 variables:

p1

Simulations for the probability of quitting in intervention 1

p2

Simulations for the probability of quitting in intervention 2

p3

Simulations for the probability of quitting in intervention 3

p4

Simulations for the probability of quitting in intervention 4

Source

Generated for package examples

Examples

## Not run: 
csv_file <- system.file("extdata", "smoking_parameters.csv", package = "BCEAweb")
data <- read.csv(csv_file)
head(data)

## End(Not run)

Smoking Cessation Example - Results

Description

This CSV file contains simulated outputs for the Smoking Cessation example.

Format

A CSV file with 500 rows and 4 variables:

e.No.treatment

Simulations for the effects in intervention 1

c.No.treatment

Simulations for the costs in intervention 1

e.Self.help

Simulations for the effects in intervention 2

c.Self.help

Simulations for the costs in intervention 2

e.Individual.counselling

Simulations for the effects in intervention 3

c.Individual.counselling

Simulations for the effects in intervention 3

e.Group.counselling

Simulations for the effects in intervention 4

c.Group.counselling

Simulations for the costs in intervention 4

Source

Generated for package examples

Examples

## Not run: 
csv_file <- system.file("extdata", "Smoking_results.csv", package = "BCEAweb")
data <- read.csv(csv_file)
head(data)

## End(Not run)

Influenza Vaccination Cost-Effectiveness Data

Description

This data set contains the results of a Bayesian analysis modeling the clinical outputs and costs associated with an influenza vaccination program.

Format

A list containing variables for the influenza vaccination model:

cost

A matrix of simulations of the overall costs for the two treatments.

c.pts

Coordinates for plotting cost distributions.

cost.GP

A matrix of simulations of the costs for GP visits.

cost.hosp

A matrix of simulations of the costs for hospitalisations.

cost.otc

A matrix of simulations of the costs for over-the-counter medications.

cost.time.off

A matrix of simulations of the costs for time off work.

cost.time.vac

A matrix of simulations of the costs for time to get vaccinated.

cost.travel

A matrix of simulations of the costs for travel to get vaccinated.

cost.trt1

A matrix of simulations of the overall costs for first-line treatment.

cost.trt2

A matrix of simulations of the overall costs for second-line treatment.

cost.vac

A matrix of simulations of the costs for vaccination.

eff

A matrix of simulations of the clinical benefits.

e.pts

Coordinates for plotting effectiveness distributions.

N

The number of subjects in the reference population.

N.outcomes

The number of clinical outcomes analysed.

N.resources

The number of health-care resources under study.

QALYs.adv

A vector of QALYs associated with adverse events.

QALYs.death

A vector of QALYs associated with death.

QALYs.hosp

A vector of QALYs associated with hospitalisation.

QALYs.inf

A vector of QALYs associated with influenza infection.

QALYs.pne

A vector of QALYs associated with pneumonia.

treats

A character vector of labels for the two treatments.

vaccine_mat

A matrix of simulations for the parameters in the original model.

Source

Adapted from Turner D, et al. (2006). "The cost-effectiveness of influenza vaccination of healthy adults 50-64 years of age". Vaccine, 24:1035-1043.

References

Baio, G., & Dawid, A. P. (2011). "Probabilistic Sensitivity Analysis in Health Economics". Statistical Methods in Medical Research. doi:10.1177/0962280211419832.


Vaccine Example - Results

Description

This CSV file contains simulated outputs for the Vaccine example.

Format

A CSV file with 500 rows and 2 variables:

e.Status.Quo

Simulations for the effects in intervention 1

c.Status.Quo

Simulations for the costs in intervention 1

e.Vaccination

Simulations for the effects in intervention 2

c.Vaccination

Simulations for the costs in intervention 2

Source

Generated for package examples

Examples

## Not run: 
csv_file <- system.file("extdata", "Vaccine_results.csv", package = "BCEAweb")
data <- read.csv(csv_file)
head(data)

## End(Not run)