Learn R Programming

echarts4r (version 0.2.0)

e_tree: Tree

Description

Build a tree.

Usage

e_tree(e, parent, child, rm_x = TRUE, rm_y = TRUE, ...)

e_tree_(e, parent, child, rm_x = TRUE, rm_y = TRUE, ...)

Arguments

e

An echarts4r object as returned by e_charts.

parent, child

Edges.

rm_x, rm_y

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

...

Any other option to pass, check See Also section.

See Also

Additional arguments

Examples

Run this code
# NOT RUN {
df <- data.frame(
  parent = c("earth","earth","forest","forest","ocean","ocean","ocean","ocean"), 
  child = c("ocean","forest","tree","sasquatch","fish","seaweed","mantis shrimp","sea monster")
)

df %>% 
  e_charts() %>% 
  e_tree(parent, child)

# }

Run the code above in your browser using DataLab