gaospecial / ggVennDiagram

A 'ggplot2' implement of Venn Diagram.
https://gaospecial.github.io/ggVennDiagram/
GNU General Public License v3.0
282 stars 38 forks source link

Option for counts/labels in plotly #21

Closed joannawolthuis closed 3 years ago

joannawolthuis commented 3 years ago

Hi there! Thanks for all you work on this package and addressing my earlier issue :) I noticed that you removed the numbers in the intersections in plotly plots for the new release. I was wondering if you'd consider adding those back in (perhaps optional?) as it would aid me in my analyses.

Thank you and kind regards, Joanna

gaospecial commented 3 years ago

Thanks for your feedback.

I have added this feature in https://github.com/gaospecial/ggVennDiagram/commit/546ebe5148ef56dbc38b97f84a431a48a327e1a7

Since plotly is not fine compatible with sf object (see https://github.com/ropensci/plotly/issues/1641#issuecomment-550477069) , I just set label count as the archor to show item members in tooltip.

x <- list(A=1:5,B=2:7,C=3:6,D=4:9)
ggVennDiagram(x, show_intersect = T)

will give

image