Build a sunburst.

e_sunburst(e, parent, child, value, itemStyle, rm_x = TRUE,
  rm_y = TRUE, ...)

e_sunburst_(e, parent, child, value, itemStyle = NULL, rm_x = TRUE,
  rm_y = TRUE, ...)



An echarts4r object as returned by e_charts.

parent, child



Name of column containing values.


Name of column containing styles to pass to child, expects a data.frame or a list, see details.

rm_x, rm_y

Whether to remove x and y axis, defaults to TRUE.


Any other option to pass, check See Also section.


The itemStyle argument essentially is a nested data.frame with column names such as color, or borderColor as specified in the official documentation.

See also


df <- data.frame( parent = c("earth", "earth", "earth", "mars", "mars"), child = c("forest", "ocean", "iceberg", "elon", "curiosity"), value = ceiling(rnorm(5, 10, 2)) ) df %>% e_charts() %>% e_sunburst(parent, child, value) %>% e_theme("westeros") # with itemStyle colors <- c("red", "black", "blue") df$color <- sample(colors, 5, replace = TRUE) df$borderColor <- sample(colors, 5, replace = TRUE) df %>% tidyr::nest(color, borderColor, .key = "style") %>% # nest e_charts() %>% e_sunburst(parent, child, value, style)