plot.multipletables: Plot Method for 'multipletables' objects

Description Usage Arguments Details Author(s) References See Also Examples

View source: R/multipleplot.r

Description

Produces a variety of plots for multiple tables analysis

Usage

1
2
3
4
    ## S3 method for class 'multipletables'
plot(x,type=NULL,select=NULL,file=NULL, xlim=NULL,ylim=NULL,
                                xlabel=NULL,mar=NULL,xlog=TRUE,
                                addline=NULL,xlab=NULL,ylab=NULL,ciShow=TRUE,...)

Arguments

x

an object inheriting from class multipletables.

type

a chracter string specifying the type of plots to produce. Options are sidebyside, overlap, and forest. See details

select

a numeric value or vector specifying which studies to be plotted. By default (when NULL), all of the studies will be plotted.

xlab

a character string specifying the x-axis label in the plot. Default is the name of the measure of association

ylab

a character string specifying the x-axis label in the plot. Default is "Density"

file

a character string specifying the filename as which the plots are saved. By default (when NULL), the plots are displayed on screen. See details.

xlim, ylim

a numeric vectors of length 2 specifying the lower and upper limits of the axes. By default (when NULL), xlim and ylim are computed. For forest plots, if the lower bound of any measure is smaller than xlim[1] or the upper bound of any measure is larger than xlim[2], arrows will be used at the limits to denote the bounds exceed the specified ranges.

xlabel

a numeric vector specifying at which tick-marks are to be drawn. By default (when NULL), tickmark locations are computed.

addline

a numeric value specifying the x-value for a vertical reference line at x=addline. Default is NULL

xlog

a logical value indicating whether a logarithmic scale should be used for x-axis. Default is TRUE for measures OR and RR and FALSE for measure RD.

mar

A numerical vector of 4 values which control the space (in the number of lines) between the axes and the border of the graph of the form c(bottom, left, top, right) the default values are NULL.

ciShow

a logical value; if TRUE (default), the true credible intervals numbers will display at the right hand side of the forest plot.

...

Other arguments can be passed to plot function

Details

If type="sidebyside", the posterior distributions of all study-specific measure are displayed side by side in 4-panel plots with study names.

If type="overlap", the posterior distributions of all study-specific measure are displayed in one graph. To clarity, it is advisable to specify a few studies by select argument.

If type="forest"), a forest plot of all study-specific and overall measure with 95% credible/confidence intervals are plotted.

If file=NULL, the plots will be displayed on screen. Or else, the plots will be saved as "./mmeta/codefile.pdf", where "./" denotes current working directory.

Author(s)

Xiao Su <[email protected]>

References

Luo, S., Chen, Y., Su, X., Chu, H., (2014). mmeta: An R Package for Multivariate Meta-Analysis. Journal of Statistical Software, 56(11), 1-26.

Chen, Y., Luo, S., (2011a). A Few Remarks on "Statistical Distribution of the Difference of Two Proportions' by Nadarajah and Kotz, Statistics in Medicine 2007; 26(18):3518-3523" . Statistics in Medicine, 30(15), 1913-1915.

Chen, Y., Chu, H., Luo, S., Nie, L., and Chen, S. (2014a). Bayesian analysis on meta-analysis of case-control studies accounting for within-study correlation. Statistical Methods in Medical Research, doi: 10.1177/0962280211430889. In press.

Chen, Y., Luo, S., Chu, H., Su, X., and Nie, L. (2014b). An empirical Bayes method for multivariate meta-analysis with an application in clinical trials. Communication in Statistics: Theory and Methods. In press.

Chen, Y., Luo, S., Chu, H., Wei, P. (2013). Bayesian inference on risk differences: an application to multivariate meta-analysis of adverse events in clinical trials. Statistics in Biopharmaceutical Research, 5(2), 142-155.

See Also

multipletables summary.multipletables

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#library(mmeta)
# Analyze the dataset colorectal to conduct exact inference of the odds ratios
#data(colorectal)
#multiple.OR <- multipletables(data=colorectal, measure="OR", model="Sarmanov", method="exact")
# Generate the forest plot with 95% CIs of study-specific odds ratios
#and 95% CI of overall odds ratio
#plot(multiple.OR, type="forest", addline=1)
# Plot the posterior density functions of some target studies in an overlaying manner
#plot(multiple.OR, type="overlap", select=c(4,14,16,20))
# Plot the posterior density functions of some target studies in a
#side-by-side manner 
#plot(multiple.OR, type="sidebyside", select=c(4,14,16,20), ylim=c(0,2.7), xlim=c(0.5,1.5))


# Analyze the dataset withdrawal to conduct inference of the relative risks
#data(withdrawal)
#multiple.RR <- multipletables(data=withdrawal, measure="RR",model="Sarmanov")
#plot(multiple.RR, type="forest", addline=1)
#plot(multiple.RR, type="overlap", select=c(3,8,14,16))
#plot(multiple.RR, type="sidebyside", select=c(3,8,14,16), ylim=c(0,1.2),
#xlim=c(0.4,3))

# Analyze the dataset withdrawal to conduct inference of the risk differences
#data(withdrawal)
#multiple.RD <- multipletables(data=withdrawal, measure="RD", model="Sarmanov")
#summary(multiple.RD)
#plot(multiple.RD, type="forest", addline=0)
#plot(multiple.RD, type="overlap", select=c(3,8,14,16))
#plot(multiple.RD, type="sidebyside", select=c(3,8,14,16))
#plot(multiple.RD, type="sidebyside", select=c(3,8,14,16),
#     ylim=c(0,6), xlim=c(-0.2,0.4))

mmeta documentation built on May 29, 2017, 8:28 p.m.