Description Usage Arguments Value Examples
Sets theme and scales so that the blank area around the plotting area is the same width on all four sides.
1 | equal_margins(margin = ggplot2::unit(0.5, "inches"))
|
margin |
|
list appropriate for adding directly to ggplot2 object
1 2 3 4 5 6 7 | library(ggplot2)
rect <- data.frame(x = 0, y = 0)
p <- rect %>%
ggplot(aes(xmin = x, xmax = x + 1, ymin = y, ymax = y + 1)) +
geom_rect(fill = "black")
p
p + equal_margins()
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.