plotPlusMatrix | R Documentation |
function to generate an aligned set of (maximum 4) plots as a 2x2 matrix (2 columns, 2 rows)
plotPlusMatrix(
sPlot,
xPlot = clearPlot(),
yPlot = clearPlot(),
crossPlot = clearPlot(),
widths = c(125, 875),
heights = c(875, 125)
)
sPlot |
ggplot object to be placed in top, right corner |
xPlot |
ggplot object to be placed in bottom, right corner (along x-axis of sPlot object) |
yPlot |
ggplot object to be placed in top, left corner (along y-axis of sPlot object) |
crossPlot |
ggplot object to be placed in bottom, left corner |
widths |
horizontal: two number (integer) vector specifying the amount of the plot to be used for the plots (horizontally) |
heights |
vertical: two number (integer) vector specifying the amount of the plot to be used for the plots (vertically) |
a ggplot object
what is returned is grobtable (class gtable): this can be drawn via the grid.draw() function. The plot drawn before this will have to be cleared "manually" via clearPlot()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.