emap_points: Add map points

Description Usage Arguments Details See Also Examples

View source: R/add.R

Description

Add map points

Usage

1
2
3
4
5
emap_points(p, serie, clickable = TRUE, symbol = "pin", symbolSize = 10,
  symbolRotate = NULL, large = FALSE, itemStyle = NULL, ...)

emap_points_(p, serie, clickable = TRUE, symbol = "pin", symbolSize = 10,
  symbolRotate = NULL, large = FALSE, itemStyle = NULL, ...)

Arguments

p

an echart objects.

serie

values to plot.

clickable

whether points are clickable.

symbol

point symbol, see details for valid values.

symbolSize

size of points.

symbolRotate

angle by which symbol is rotated, i.e.: 30.

large

whether to optimise for large datasets: 2K points +.

itemStyle

cutomise points.

...

any other option to pass to points.

Details

Valid values for symbol:

See Also

office map points docs

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
## Not run: 
coords <- data.frame(city = c("London", "New York", "Beijing", "Sydney"),
  lon = c(-0.1167218, -73.98002, 116.3883, 151.18518),
  lat = c(51.49999, 40.74998, 39.92889, -33.92001),
  values = runif(4, 10, 20))

coords %>%
  echart_("city") %>%
  emap() %>%
  emap_coords_("lon", "lat") %>%
  emap_points_("values")

coords2 <- data.frame(city = "Rio", lon = -43.172896, lat = -22.906847, value = 15)

coords %>%
  echart_("city") %>%
  emap() %>%
  emap_coords_("lon", "lat") %>%
  emap_points_("values", symbolSize = 5) %>%
  edata_(coords2, "city") %>%
  emap() %>%
  emap_coords_("lon", "lat") %>%
  emap_points_("value", symbol = "emptyCircle", effect = list(show = TRUE, shadowBlur = 10)) %>%
  etheme("helianthus")

## End(Not run)

JohnCoene/echarts documentation built on May 22, 2021, 6:18 p.m.