Learn R Programming

metaSEM (version 0.9.8)

plot: Plot method for meta objects

Description

It plots the pooled and the individual effect sizes and their confidence ellipses for meta objects.

Usage

"plot"(x, effect.sizes, add.margin = 0.1, interval = 0.95, main= "Effect Sizes and their Confidence Ellipses", axis.labels= paste("Effect size ", effect.sizes, sep = ""), study.col = "black", study.pch = 19, study.min.cex = 0.8, study.weight.plot = FALSE, study.ellipse.plot = TRUE, study.ellipse.col = "black", study.ellipse.lty = 2, study.ellipse.lwd = 0.5, estimate.col = "blue", estimate.pch = 18, estimate.cex = 2, estimate.ellipse.plot = TRUE, estimate.ellipse.col = "red", estimate.ellipse.lty = 1, estimate.ellipse.lwd = 2, randeff.ellipse.plot = TRUE, randeff.ellipse.col = "green", randeff.ellipse.lty = 1, randeff.ellipse.lwd = 2, univariate.plot = TRUE, univariate.lines.col = "gray", univariate.lines.lty = 3, univariate.lines.lwd = 1, univariate.polygon.width = 0.02, univariate.polygon.col = "red", univariate.arrows.col = "green", univariate.arrows.lwd = 2, diag.panel = FALSE, xlim=NULL, ylim=NULL, ...)

Arguments

x
An object of class meta.
effect.sizes
Numeric values indicating which effect sizes to be plotted. At least two effect sizes are required. To plot the effect sizes of $y1$ and $y2$, one may use effect.sizes=c(1,2). If it is missing, all effect sizes will be plotted in a pairwise way.
add.margin
Value for additional margins on the left and bottom margins.
interval
Interval for the confidence ellipses.
main
Main title of each plot. If there are multiple plots, a vector of character titles may be used.
axis.labels
Labels for the effect sizes.
study.col
Color of individual studies. See col in par.
study.pch
Plotting character of individual studies. See pch in points.
study.min.cex
Minimum value of cex for individual studies. See cex in par.
study.weight.plot
Logical. If TRUE, the ploting size of individual studies (cex) will be proportional to one over the square root of the determinant of the sampling covariance matrix of the study.
study.ellipse.plot
Logical. If TRUE, the confidence ellipses of individual studies are plotted.
study.ellipse.col
Color of the confidence ellipses of individual studies. See col in par.
study.ellipse.lty
Line type of the confidence ellipse of individual studies. See lty in par.
study.ellipse.lwd
Line width of the confidence ellipse of individual studies. See lwd in par.
estimate.col
Color of the estimated effect size. See col in par.
estimate.pch
Plotting character of the estimated effect sizes. See pch in points.
estimate.cex
Amount of plotting of the estimated effect sizes. See cex in par.
estimate.ellipse.plot
Logical. If TRUE, the confidence ellipse of the estimated effect sizes will be plotted.
estimate.ellipse.col
Color of the confidence ellipse of the estimated effect sizes. See col in par.
estimate.ellipse.lty
Line type of the confidence ellipse of the estimated effect sizes. See lty in par.
estimate.ellipse.lwd
Line width of the confidence ellipse of the estimated effect sizes. See lwd in par.
randeff.ellipse.plot
Logical. If TRUE, the confidence ellipses of the random effects will be plotted.
randeff.ellipse.col
Color of the confidence ellipses of the random effects. See col in par.
randeff.ellipse.lty
Line type of the confidence ellipses of the random effects. See lty in par.
randeff.ellipse.lwd
Line width of the confidence ellipses of the random effects. See lwd in par.
univariate.plot
Logical. If TRUE, the estimated univariate effect sizes will be plotted.
univariate.lines.col
Color of the estimated univariate effect sizes. See col in par.
univariate.lines.lty
Line type of the estimated univariate effect sizes. See lty in par.
univariate.lines.lwd
Line width of the estimated univariate effect sizes. See lwd in par.
univariate.polygon.width
Width of the polygon of the estimated univariate effect sizes.
univariate.polygon.col
Color of the polygon of the estimated univariate effect sizes.
univariate.arrows.col
Color of the arrows of the estimated univariate effect sizes.
univariate.arrows.lwd
Line width of the arrows of the estimated univariate effect sizes.
diag.panel
Logical. If TRUE, diagonal panels will be created. They can then be used for forrest plots for univariate meta-analysis.
xlim
NULL or a numeric vector of length 2; if it is NULL, it provides defaults estimated from the data.
ylim
NULL or a numeric vector of length 2; if it is NULL, it provides defaults estimated from the data.
...
Further arguments to be passed to the plot function.

References

Cheung, M. W.-L. (2013). Multivariate meta-analysis as structural equation models. Structural Equation Modeling, 20, 429-454.

Examples

Run this code
## Not run: 
# ## Multivariate meta-analysis
# x <- meta(y=cbind(PD, AL), v=cbind(var_PD, cov_PD_AL, var_AL), data=Berkey98)
# plot(x)
# 
# ## Plot individual studies proportional to the weights
# plot(x, study.weight.plot=TRUE)
# 
# ## Include forest plot from the metafor package
# library(metafor)
# plot(x, diag.panel=TRUE, main="Multivariate meta-analysis",
# axis.label=c("PD", "AL"))
# forest( rma(yi=PD, vi=var_PD, data=Berkey98) )
# title("Forest plot of PD")
# forest( rma(yi=AL, vi=var_AL, data=Berkey98) )
# title("Forest plot of AL")
# ## End(Not run)

Run the code above in your browser using DataLab