plot_arrange: Arrange base R plots on a grid

View source: R/plot_tools.R

plot_arrangeR Documentation

Arrange base R plots on a grid

Description

This is similar to gridExtra::grid.arrange(), but it works on base R plots instead of ggplot objects.

Usage

plot_arrange(..., nrow, ncol, par_args = character(0))

Arguments

...

(Expressions) Functions that create plots.

nrow

(Integer) Number of rows to arrange plots into.

ncol

(Integer) Number of columns to arrange plots into.

par_args

(List) A list() of arguments to pass into par().

Value

Plots arranged in a grid.

Authors

Examples

plot_arrange(plot(Sepal.Length ~ Sepal.Width,  data = iris),
             plot(Petal.Length ~ Petal.Width,  data = iris),
             plot(Petal.Length ~ Sepal.Length, data = iris),
             plot(Petal.Width  ~ Sepal.Width,  data = iris),
             nrow = 2, ncol = 2)


DesiQuintans/desiderata documentation built on April 9, 2023, 5:43 a.m.