stickr
The goal of stickr is to make it easier for you to include any R package hex stickers in your work.
Installation
You can install the released version of stickr from GitHub with:
remotes::install_github("akgold/stickr")Example
This is a basic example which shows you how to find and download a sticker:
library(stickr)
# Get the tidyverse sticker, downloads to temp file if no destfile specified
stickr_get("tidyverse")
# Get a sticker that's not in the RStudio repository
stickr_get("textmineR")
# But that's the old sticker, get the new one by name
stickr_get("textmineR", filename = "textmineR_v8.png")A common use case would be to include in an R Markdown document,
that would be done using stickr_insert("tidyverse"). If trying to insert inline, consider using dpi argument.
Package Maintainers
Want to make sure users can get your sticker with stickr? Two steps!
- Make sure your package's DESCRIPTION file includes a URL and/or BugReport field field that points to your package's GitHub repository.
- Put your hex sticker in the
/man/figuresdirectory inside your package -- one namedlogo.pngwill be used by default, but other names are ok too.