ggvis - add tooltip with count to layer_bars -


suppose have following graph

library(ggvis) mtcars%>% ggvis(~factor(cyl)) %>% layer_bars() 

how can add tooltip count variable?

thanks

this trick:

library(ggvis) mtcars  %>% ggvis(~factor(cyl)) %>% layer_bars() %>%   add_tooltip(function(df) (df$stack_upr_ - df$stack_lwr_)) 

Comments

Popular posts from this blog

timeout - Handshake_timeout on RabbitMQ using python and pika from remote vm -

gcc - MinGW's ld cannot perform PE operations on non PE output file -

c# - Search and Add Comment with OpenXML for Word -