Learn R Programming

pcnetmeta (version 1.1)

ci.plot: Plot credible interval

Description

ci.plot generates credible interval plot for the population-averaged event rates given by the function nma.ab.

Usage

ci.plot(summary.stat, trtname, graphtitle = "")

Arguments

summary.stat
a data frame read from the summary result file generated by the function nma.ab. We can use the function read.table to import the summary file.
trtname
a vector of character string indicating treatment names. These will be shown on x-axis in the plot. The default is "trt1", "trt2", and so on.
graphtitle
a charater string indicating the graph title. The default is an empty character.

Value

  • A credible interval plot for population-averaged event rate is generated. Treatment names are placed on x-axis, while the y-axis shows the lower bound, upper bound and median of credible interval.

References

Zhang J, Carlin BP, Neaton JD, Soon GG, Nie L, Kane R, Virnig BA, Chu H (2013). "Network meta-analysis of randomized clinical trials: Reporting the proper summaries." Clin Trials.

Examples

Run this code
## CI plot for network Ara 2009
data(Ara09)
attach(Ara09)
set.seed(12345)
nma.ab(s.id = Study.ID, t.id = Treatment, event.n = r, total.n = n,
       f.name = "Ara09_", n.iter = 500, dic = FALSE)
detach(Ara09)
ci.plot(summary.stat = read.table("Ara09_Summary.stat", header = TRUE),
        graphtitle = "CI plot of estimated event rate for Ara09 network")

## CI plot for network Lam 2007
data(Lam07.Summary)
data(Lam07)
ci.plot(summary.stat = Lam07.Summary, trtname = Lam07$trtname,
        graphtitle = "CI plot of estimated event rate for Lam07 network")

Run the code above in your browser using DataLab