# NOT RUN {
## default position is topleft next to zoom control
img <- "https://www.r-project.org/logo/Rlogo.svg"
leaflet() %>% addTiles() %>% addLogo(img, url = "https://www.r-project.org/logo/")
## with local image
library(png)
img <- system.file("img", "Rlogo.png", package="png")
leaflet() %>% addTiles() %>% addLogo(img, src = "local", alpha = 0.3)
## dancing banana gif :-)
library(magick)
m <- mapview(breweries91)
addLogo(m, "https://jeroenooms.github.io/images/banana.gif",
position = "bottomleft",
offset.x = 5,
offset.y = 40,
width = 100,
height = 100)
# }
# NOT RUN {
# }
Run the code above in your browser using DataLab