Learn R Programming

rmeta (version 3.0)

meta.colors: Control colours in meta-analysis plot

Description

Wrapper function for specifying colours to meta-analysis plots

Usage

meta.colors(all.elements, box="black", lines="gray", summary="black",
            zero="lightgray", mirror="lightblue", text="black",
             axes="black",background=NA)

Arguments

all.elements

if present, overrides other arguments

box

Colour of sample size box

lines

Colour of confidence intervals

summary

Colour of summary estimate

zero

Colour of null hypothesis line

mirror

Colour of reflected points (in funnelplot)

text

Colour of labels

axes

Colour of x-axis and axis labels

background

Background colour.

Value

a list of colors

See Also

plot.meta.MH,plot.meta.DSL,plot.meta.summaries,funnelplot,metaplot

Examples

Run this code
# NOT RUN {
data(cochrane)
steroid <- meta.MH(n.trt, n.ctrl, ev.trt, ev.ctrl,
                   names=name, data=cochrane)

## All black, for better photocopying
plot(steroid, col=meta.colors("black"))

## distinguish the summary 
plot(steroid,colors=meta.colors(summary="forestgreen"))

data(catheter)
e <- meta.DSL(n.trt, n.ctrl, inf.trt, inf.ctrl, data=catheter,
              names=Name, subset=c(13,6,3,12,4,11,1,14,8,10,2))

## Truly awful colour scheme to illustrate flexibility
plot(e, colors=meta.colors(summary="green",lines=c("purple","skyblue"),
       box="red",zero="yellow",text=palette(),background="tomato",
       axes="lightgreen"))

## Dark blue background popular for presentations.
plot(e, colors=meta.colors(summary="white",lines="#FFFFF0",
        box="#FFFF50",zero="grey90",text="white",background="darkblue",
        axes="grey90"))
# }

Run the code above in your browser using DataLab