color/symbol mapping breaks `transforms` filter
Nessuno ha ancora preso questa issue.
- Lingua principale
- R
- Stelle
- 2.7k
- Fork
- 641
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Descrizione
Issue
transforms filter plus color/symbol mapping seems to break the transforms filter.
Reprex
Sample data
df <- data.frame(
x = c(1:10, 1:10),
y = c(1:10, 10:1),
z = c(rep("up", 10), rep("down", 10)))
The idea is to only show data where z = "up" through a transforms filter.
Case 1: transforms filter without color mapping
This works
plot_ly(
df,
x = ~x, y = ~y, text = ~z,
type = "scatter", mode = "markers+text",
marker = list(size = 10, opacity = 0.8),
transforms = list(
list(
type = "filter",
target = ~z,
operation = "=",
value = "up")))

Case 2: transforms filter with color mapping
This does not work
plot_ly(
df,
x = ~x, y = ~y, text = ~z, color = ~z,
type = "scatter", mode = "markers+text",
marker = list(size = 10, opacity = 0.8),
transforms = list(
list(
type = "filter",
target = ~z,
operation = "=",
value = "up")))

Summary
In both cases the transforms filter is the same and should select only those entries where z = "up"; however, when a color (or symbol) mapping is added, for some reason only entries where z = "down" are shown.
Guida per i contributori
Apri la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Direzione di ricerca
Inizia con i due reprex di plot_ly() nell’issue e confronta il comportamento generato con e senza il mapping color = ~z o il mapping di symbol. Riproduci il filtro transforms usando i dati forniti, quindi traccia il mapping plotly.R rilevante e la gestione di transforms; il lavoro è completato quando il filtro mostra costantemente solo le righe in cui z = "up" con il mapping di color o symbol abilitato.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- r
- Ambito
- data-visualization
- Tipo di issue
- Bug
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Stato di attività
- Ferma
- Chiarezza
- Abbastanza chiara
- Idoneità per principianti
- 38/100