DumbGrid | R Documentation |
This function is a wrapper for plot_grid
that removes unnecessary axis labels for
plots that are not along the left side of the plot. While it was initially intended to incorporate
a "smart-adjust" feature that would scale all plots without y-axis labels to be the same width as the plot
areas with y-axis labels, this function requires manual resizing of the furthest-left column of plots to
make them the same size as the others, hence the name DumbGrid rather than SmartGrid.
DumbGrid(..., Ncols, FirstColWidth = 1, SharedLegend = F)
... |
Unquoted object names of ggplot objects to be included in the resultant grid of plots. |
Ncols |
A number indicating the number of columns that should be used in the plot grid. |
FirstColWidth |
A number indicating the relative width of the first column of plots compared to all other columns. A value of 1 sets the left-most column at the same width as all others. |
SharedLegend |
A logical value indicating whether plots should share a legend (T), or have their own legend (F). |
This function produces a grid of plots constructed from the plots supplied to the ...
argument. Plots that are not in the left-most columns will not have y-axis labels.
data("Epfu_Nb2_Long", package = "EcoCountHelper") EffectsPlotter(Epfu_Nb2_Long, c(":)", "!", "argument", "FirstColWidth", "the", "with", "adjusted", "be", "to", "need", "plots", "These")) ExPlot <- Epfu_Nb2_LongEffectsPlot #First grid attempt TestGrid <- DumbGrid(ExPlot, ExPlot, ExPlot, ExPlot, Ncols = 2) TestGrid #View the plot in a separate window #Adjusting the first column width to make plot sizes equal TestGrid2 <- DumbGrid(ExPlot, ExPlot, ExPlot, ExPlot, Ncols = 2, FirstColWidth = 1.35) TestGrid2 #View the plot in a separate window
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.