Skip to content

group_by.plotly() doesn't retain crosstalk set information #1920

Closed

Description

@cpsievert

The core issue behind tidyverse/dplyr#5760 (example below) is that group_by.plotly() doesn't retain crosstalk set information

library(plotly)
library(crosstalk)

shared_data <- mtcars %>% 
  SharedData$new()

p <- shared_data %>% 
  plot_ly(x = ~mpg, y = ~hp) %>%
  group_by(am) %>%
  add_markers()

bscols(list(
  filter_slider(id = "mpg", label = "Miles per Gallon",
                sharedData = shared_data, column = "mpg"),
  filter_checkbox(id = "am", label = "Automatic / Manual",
                  sharedData = shared_data, group = ~am)),
  p)

Activity

  1. added a commit that references this issue on Jan 7, 2026
    757a329
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions