Pulling ggplot legend
g_legend(p)
p
A ggplot of which legend should be pulled.
ggplot
A ggplot legend.