watermark | R Documentation |
Add a watermark annotation layer for a ggplot2 object
watermark(
watermark,
fontsize = 120,
colour = "grey90",
alpha = 0.1,
fontface = "bold",
angle = 22
)
watermark |
String to be added as watermark |
fontsize |
Font size |
colour |
Font colour |
alpha |
Alpha (transparency; lower number = more transparent) |
fontface |
Font face ("bold" by default) |
angle |
Angle of the watermark |
library(ggplot2)
# First, start with a plot:
p <- ggplot(mtcars, aes(x = wt, y = mpg)) + geom_point() + theme_grattan()
# Then add a watermark:
p + watermark("DRAFT")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.