plotOnSide adds plot areas on the specified sides of the original figures.

plotOnSide(mat, side = 1:2, dim = NULL, quiet = FALSE, ...)

Arguments

mat

a matrix object specifying the location of the next N figures on the output device, see graphics::layout().

side

the number of the sides on which plot areas must be added.

dim

optional. If provided, then a matrix is created based and this argument specifies its dimensions.

quiet

if TRUE, no warning message will be displayed.

...

additional arguments to be passed to graphics::layout().

Details

This function eases the creation of plots that include multiple panels that shares information such as axis labels. Instead of repeating or deleting axis labels, plotOnSide add plot areas on the specified sides of the original figures. It is based on graphics::layout() and it is no more than a tuned version of it.

Examples

plotOnSide(matrix(1,2), width=c(0.2,1), height=c(1,1,1,0.6)) graphics::layout.show(5)