Extract ggplot legend as it's own plot grob object

e_plot_extract_legend(p = NULL)

Arguments

p

ggplot grob

Value

p_legend ggplot grob of only the legend

Examples

if (FALSE) {
p_legend <- e_plot_extract_legend(p)
}