library(leaflet)
df <- data.frame(ville=c("Strasbourg", "Paris", "Thionville", "Metz", "Nancy", "Reims", "Troyes"), pop=c(277,2148,41,117,106, 184,61), lat=c(48.5833,48.8534,49.3667,49.1191, 48.6833,49.25,48.3), lng=c(7.75,2.3488,6.1667,6.1727,6.2,4.0333,4.0833))
df %>%
leaflet() %>%
addTiles() %>%
addCircleMarkers(weight = 10, radius = sqrt(df$pop))
Assuming "lng" and "lat" are longitude and latitude, respectively
Below some places have been selected. Click to zoom and see more detailed clusters until distinguishing places.
df <- data.frame(lat=runif(500, min=48.57, max = 48.61 ),
lng=runif(500, min=7.74, max = 7.76 ))
df %>%
leaflet() %>%
addTiles() %>%
addMarkers(clusterOptions = markerClusterOptions())