Hello,
I am having issues viewing a map produced via the leaflet package in Rmarkdown. Here is a preview of the code I am using to display the map:
## install.packages("leaflet")
## webshot::install_phantomjs()
library(leaflet)
leaflet() %>% addTiles() %>%
setView(lat = 32.987607, lng = -96.751466, zoom = 17) %>%
addMarkers(lat = 32.987607, lng = -96.751466, popup = "We are here")
When I run this I am able to see my code in the pdf file produced, but the image will not appear. What's somewhat confusing is that if I use a mac the code above produces the map in the markdown file. However, if I use a windows machine only the code itself will be printed without the map.
Can somebody please explain what I must do to remedy this issue on a windows machine?