move_legend_to_empty_facet | R Documentation |
Moves a ggplot legend to an empty facet if one exists
move_legend_to_empty_facet(g)
g |
A |
If an empty facet does not exist, an error will be thrown
If the input object g
is not a ggplot2::ggplot()
object nor a
ggplot2::ggplot_gtable()
object, the original object is returned.
A ggplot2::ggplot()
object
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.