Recently I have been working with the package 'leaflet' in R. I have already created my interactive map and so on, but I would prefer to style it up a bit. My program recieves a list of Cities inputted by the user whose names I store in a dataframe. My goal is to have the first image that comes up in Google search while looking for every city as the marker's pop-up. I would really appreciate if someone could help me out.
mapa<- leaflet() %>%
addTiles() %>%
addMarkers(data=df,lat=~Latitudes,lng=~Longitudes, label=~Nombres)
mapa <- setView(mapa,lat = 40.416775, lng = -3.703790, zoom = 5)
mapa <- addProviderTiles(mapa,providers$Esri.NatGeoWorldMap)
Thanks
library(rvest)
and then loop over the results to put image links in your popup.