YuLab-SMU / scatterpie

:art: scatter pie plot
https://cran.r-project.org/package=scatterpie
60 stars 15 forks source link

Rounding in the legend #3

Closed danielsjf closed 7 years ago

danielsjf commented 7 years ago

I have some issues with your rounding in the legends. If the different radii are orders of magnitude apart, the rounding is not consistent, which seems to lead to a non-natural legend.

image

Things can get even worse when two roundings lead to the same number:

image

Maybe you can round all the radii to the same number of digits?

Furthermore, there are some base-R rounding functions available (I saw that you implemented your own function). https://stat.ethz.ch/R-manual/R-devel/library/base/html/Round.html

danielsjf commented 7 years ago

An even better example is this one:

image

Radii: 0.7792073 0.6600432 2.2452716 1.8896772 1.9545808 1.1000840 1.7399760 1.1673637

GuangchuangYu commented 7 years ago

the updated version (0.0.6) is now available on CRAN. 😃