Learn R Programming

pcnetmeta (version 1.3)

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 (2014). "Network meta-analysis of randomized clinical trials: Reporting the proper summaries." Clin Trials 11(2), 246--262.

Examples

Run this code
## CI plot for network Middleton 2010
data(Middleton10)
attach(Middleton10)
set.seed(12345)
nma.ab(s.id = sid, t.id = tid, event.n = r, total.n = n,
       f.name = "Middleton10_", n.iter = 500, dic = FALSE)
detach(Middleton10)
ci.plot(summary.stat = read.table("Middleton10_Summary.stat", header = TRUE),
        graphtitle = "CI plot of estimated event rate for network Middleton10",
        trtname = c("First generation", "Hysterectomy", "Second generation",
        "Mirena"))

Run the code above in your browser using DataLab