View source: R/gg_ShowPlotDims.R
gg_ShowPlotDims | R Documentation |
Function to determine and show dimensions of a ggplot2 object or derived gtable.
gg_ShowPlotDims(
p,
unit = "in",
null = 3,
null_x = NULL,
null_y = NULL,
xtick = 0.5,
ytick = xtick,
showPlot = TRUE,
verbose = 0
)
p |
|
unit |
|
null |
|
null_x |
|
null_y |
|
xtick |
|
ytick |
|
showPlot |
|
verbose |
|
This function converts "null" (relative) scales in a ggplot2 object (or derived gtable) to absolute scales and creates a rectangle plot of the resulting components with axes reflecting the absolute scales.
If either null_x or null_y is NULL, then the value of null
is used for both. If
both null_x and null_y are not NULL, these values are used for nulls along the correpsonding
axes.
invisibly returns a list with elements plot - plot of object components with axes reflecting inferred sizes dims - vector with plot width and height lyt - layout table (if verbose>1) tbl_rows - row dimensions (if verbose>1) tbl_cols - column dimensions (if verbose>1) tbl_matp -tibble with intermediate information (if verbose>1) tbl_matpp - tibble with intermediate information (if verbose>1)
William Stockhausen (william.stockhausen@noaa.gov)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.