Skip to content

Instantly share code, notes, and snippets.

@joelnitta
Created September 22, 2019 22:25
Show Gist options
  • Save joelnitta/dab60fe8e48a75cf9f472f0721b627a8 to your computer and use it in GitHub Desktop.
Save joelnitta/dab60fe8e48a75cf9f472f0721b627a8 to your computer and use it in GitHub Desktop.
Make a generic hex sticker
library(hexSticker)
library(ggplot2)
# Make a blank plot because hexSticker::sticker() expects something.
p <- ggplot(mtcars, aes(wt, mpg)) + geom_blank() + theme_void() + theme_transparent()
sticker(p,
package="generic",
p_size=8, s_x=1, s_y=.8, s_width=1.2, s_height=1,
h_color = "grey",
h_fill = "cyan4")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment