Highlights specified targets and fade out the others.
Highlights specified targets and fade out the others.
bb_proxy_focus(proxy, ids = NULL) bb_proxy_defocus(proxy, ids = NULL)
proxy |
A |
ids |
Data ids (names) to be highlighted, if |
A billboardProxy
htmlwidget
object.
bb_defocus
is the opposite of bb_focus
if (interactive()) { library("shiny") library("billboarder") ui <- fluidPage( tags$h1("Proxy method to highlight data"), checkboxGroupInput( inputId = "focus", label = "Focus", choices = c("setosa", "versicolor", "virginica"), inline = TRUE ), billboarderOutput(outputId = "bb") ) server <- function(input, output, session) { output$bb <- renderBillboarder({ billboarder() %>% bb_scatter( data = iris, x = "Sepal.Length", y = "Sepal.Width", group = "Species" ) %>% bb_axis(x = list(tick = list(fit = FALSE))) %>% bb_point(r = 8) }) observeEvent(input$focus, { billboarderProxy("bb") %>% bb_proxy_focus(input$focus) }, ignoreNULL = FALSE) } shinyApp(ui = ui, server = server) }
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.