plotly / plotly/plotly.R

'hovertemplate' not passable as an attribute into a dataframe in a sankey diagram's nodes/links

Offen
#2,090 0 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen

Dieses Issue hat noch niemand übernommen.

Vorherrschende Sprache
R
Sterne
2.7k
Forks
641
PR-Merge-Kennzahlen
Keine gemergten PRs in 30 T.

Beschreibung


The 'hovertemplate' attribute is not working when passed into the 'nodes' or 'links' dataframes in a sankey diagram. "Node" and "link" are arguments for the sankey's links and nodes and are of type dataframe which contain arbitrary data for the links and nodes, as well as attributes of links and nodes (see plotly::schema() for a list of all available attributes for each trace). Reprex here is unnecessary since my question is why 'hovertemplate' cannot be passed into the 'nodes' or 'links' as attributes when other attributes such as 'color' and 'hoverinfo' are passable? Is there any workaround to this?



fig <- plot_ly(
      type = "sankey",
      orientation = "h",
      node = nodes, # dataframe which includes sankey trace data and attributes
      link = links, # dataframe which includes sankey trace data and attributes
      valueformat = ".0f")

fig 

Beitragsleitfaden

Beitragsleitfaden öffnen

Erste Schritte

  1. Lies das ganze Issue und danach den Beitragsleitfaden des Projekts.
  2. Schreib ins Issue, dass du es übernimmst — das erspart doppelte Arbeit.
  3. Forke das Repository und arbeite in einem Branch.
  4. Öffne einen Pull Request, der die Issue-Nummer nennt.

Rechercherichtung

Es wird keine Implementierungsdatei und kein Test genannt. Beginne mit der Untersuchung von plotly::schema() auf Sankey-Knoten- und Link-Attribute und verfolge anschließend, wie die Knoten- und Link-Dataframes konvertiert werden; als erledigt gilt die Bestimmung, warum sich hovertemplate von color und hoverinfo unterscheidet, sowie die Dokumentation eines bestätigten Workarounds oder des unterstützten Verhaltens.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
plotly, r
Bereich
data-visualization
Issue-Typ
Bug
Schwierigkeit
4/5
Geschätzter Aufwand
3-5 Tage
Aktivitätsstatus
Veraltet
Klarheit
Muss geklärt werden
Anfängerfreundlichkeit
25/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.