multiplot: Complex Plot Arrangements for ggplot Objects

Description Usage Arguments Author(s) See Also Examples

View source: R/multiplot.R

Description

Arrange multiple ggplot objects on graphics device

Usage

1
multiplot(..., plotlist = NULL, cols = 1, layout = NULL)

Arguments

...

ggplot objects to be passed to the function

plotlist

a list of ggplot plots to plot

cols

number of columns in layout

layout

a matrix specifying the layout

Author(s)

Winston Chang <winston@stdout.org>

See Also

layout

Examples

1
2
3
4
p1 <- ggplot(data = HSWRESTLER, aes(x = skfat, y = hwfat)) + geom_point()
p2 <- ggplot(data = HSWRESTLER, aes(x = tanfat, y = hwfat)) + geom_point()
multiplot(p1, p2, cols = 2)
multiplot(p1, p2, cols = 2, layout=matrix(c(1, 0, 0, 2), byrow = TRUE, nrow = 2))

PASWR2 documentation built on Sept. 5, 2021, 5:44 p.m.