ggimage
ggimage copied to clipboard
ggbackground overrides annotation_custom
I want to use annotation_custom to add the logo to the plot. However, when I'm using it together with the ggbackground, the background image seems to cover the logos:
plot <- ggbackground(plot, "background.png")
plot +
annotation_custom(rasterGrob(logo), xmin = 0, xmax = 0.3, ymin = 0.3, ymax = -1) +
coord_cartesian(clip = "off")
The same code without ggbackground(plot, "background.png") generates the expected result.