Closed kapsner closed 1 year ago
The latest commit enhances the beeswarm plot by making use of the awesome R package ggbeeswarm
https://github.com/eclarke/ggbeeswarm, resulting in
The latest commit normalizes feature values between 0 and 1, resulting in n
Hi @bgreenwell , when you take a closer look, there are some "challenges" to be considered:
All in all 6 new dependencies have been added for performing the data wrangling and visualizations:
magrittr
dplyr
utils
tidyr
viridis
ggbeeswarm
Whereas ggbeeswarm
is also imported via the DESCRIPTION file's "Remotes" section, since the argument corral
from geom_beeswarm
is not yet available the version that is released on CRAN.
This would currently disallow a fast CRAN release of fastshap
, if one wants to make use of this argument. Alternatively, I have commented out the part without ggbeeswarm
that uses plain ggplot2
and geom_jitter
(https://github.com/kapsner/fastshap/blob/feat_beeswarm_plot/R/beeswarm.R#L110), which, however, does not look as nice.
To clarify the progress of ggbeeswarm
's next CRAN release, I have opened this issue https://github.com/eclarke/ggbeeswarm/issues/74.
Unfortunatelly, ggbeeswarm
seems not to be actively maintained anymore (last CRAN upload in 2017). To get rid of this dependency, I've found geom_sina
from the ggforce
package, which results in a very similar depiction:
Hi @bgreenwell , have you had already some time to take a closer look to this PR?
Thanks @kapsner, I have not had a chance, but I will try to take a close look this week!
Closing this in favor of reliance on the shapviz package.
This PR adds a ggplot2-based beeswarm plot to fastshap and closes #17.
The example plot from the unittest (https://github.com/kapsner/fastshap/blob/feat_beeswarm_plot/inst/tinytest/test_fastshap.R#L197) is as follows: