Given a list of ggplot2 plots, remove legend from each of them and return grid of such plots plus legend from the first vis. Suitable for plots with similar legends.
1 | .add.legend(.vis.list, .vis.nrow = 2, .legend.ncol = 1)
|
.vis.list |
A list with ggplot2 plots. |
.vis.nrow |
Number of rows of the resulting grid with plots. |
.legend.ncol |
Number of columns in the shared legend. |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.