Description Usage Arguments Examples
Add arcs by coordinates.
1 |
p |
a datamaps object. |
origin.lon, origin.lat |
origin coordinates. |
destination.lon, destination.lat |
destination coordinates. |
... |
any other arguments to use as options. |
1 2 3 4 5 6 7 8 9 10 | states <- data.frame(ori.lon = c(-97.03720, -87.90446),
ori.lat = c(32.89595, 41.97960),
des.lon = c(-106.60919, -97.66987),
des.lat = c(35.04022, 30.19453),
strokeColor = c("blue", "red"),
arcSharpness = c(2, 1))
states %>%
datamaps(scope = "USA", default = "lightgray") %>%
add_arcs(ori.lon, ori.lat, des.lon, des.lat, strokeColor)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.