How do I reference a clicked point on a ggvis plot in Shiny
问题 I wish to use the values of a clicked point for further processing but am unclear how to reference the data library(shiny) library(ggvis) library(dplyr) df <- data.frame(a=c(1,2),b=c(5,3)) runApp(list( ui = bootstrapPage( ggvisOutput("plot") ), server = function(..., session) { # function to handle click getData = function(data,location,session){ if(is.null(data)) return(NULL) # This returns values to console print(glimpse(data)) # Observations: 1 # Variables: # $ a (int) 2 # $ b (int) 3 } #