powered by
create sticker in R
sticker(subplot, s_x = 0.8, s_y = 0.75, s_width = 0.4, s_height = 0.5, package, p_x = 1, p_y = 1.4, p_color = "#FFFFFF", p_family = "Aller_Rg", p_size = 8, h_size = 1.2, h_fill = "#1881C2", h_color = "#87B13F", spotlight = FALSE, l_x = 1, l_y = 0.5, l_width = 3, l_height = 3, l_alpha = 0.4, url = "", u_x = 1, u_y = 0.08, u_color = "black", u_family = "Aller_Rg", u_size = 1.5, filename = paste0(package, ".png"), dpi = 300)
subplot
x position for subplot
y position for subplot
width for subplot
height for subplot
package name
x position for package name
y position for package name
color for package name
font family for package name
font size for package name
size for hexagon border
color to fill hexagon
color for hexagon border
whether add spotlight
x position for spotlight
y position for spotlight
width for spotlight
height for spotlight
maximum alpha for spotlight
url at lower border
x position for url
y position for url
color for url
font family for url
text size for url
filename to save sticker
plot resolution
gg object
# NOT RUN { library(ggplot2) p <- ggplot(aes(x = mpg, y = wt), data = mtcars) + geom_point() p <- p + theme_void() + theme_transparent() sticker(p, package="hexSticker") # }
Run the code above in your browser using DataLab