g2_chord | R Documentation |
chord
g2_chord(encode = NULL, ...)
encode |
encode |
... |
property: y / id / source / target / sourceWeight / targetWeight / sortBy / nodeWidthRatio / nodePaddingRatio |
data for chord:
df = data.frame(source=..., target=..., value=...) g2(data=list(value=list(links=df)))
you need to pass the other property to g2_chord() to config the data field
mapping if your data don't have the source
target
and value
Other mark:
g2_area()
,
g2_bar()
,
g2_box()
,
g2_boxplot()
,
g2_cell()
,
g2_col()
,
g2_density()
,
g2_gauge()
,
g2_heatmap()
,
g2_hist()
,
g2_image()
,
g2_interval()
,
g2_line()
,
g2_lineX()
,
g2_lineY()
,
g2_link()
,
g2_liquid()
,
g2_pie()
,
g2_point()
,
g2_polygon()
,
g2_range()
,
g2_range_x()
,
g2_range_y()
,
g2_rect()
,
g2_shape()
,
g2_text()
,
g2_vector()
,
g2_wordCloud()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.