# NOT RUN {
# image glyph
if(requireNamespace("png")) {
# Download images from github
img_path <- list.files(file.path(find.package(package = 'ggmulti'),
"images"),
full.names = TRUE)
Raptors <- png::readPNG(img_path[1L])
p <- ggplot(data = data.frame(x = 0, y = 0),
mapping = aes(x = x, y = y)) +
geom_image_glyph(images = Raptors,
units = "native",
imagewidth = 1,
imageheight = 1)
p
}
# }
Run the code above in your browser using DataLab