plotly / plotly/plotly.js

Incorrect fill rendering caused by gaps in data

Offen
#2,736 10 Kommentare 13 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen

Dieses Issue hat noch niemand übernommen.

bug P2
Vorherrschende Sprache
JavaScript
Sterne
18.3k
Forks
2k
Ø Merge
2 T. 12 Std.
Gemergte PRs (30 T.)
28

Beschreibung

I'm using Plotly.js to display some time series data with the following relevant properties:

  • Large gaps in the data, and
  • Non-symmetric uncertainty (i.e. each data point has min,avg,max values).

I'm attempting to plot this by adapting this example, but I seem to have come across a bug: when using data with gaps (and connectgaps: false) at the same time as fill: 'tonexty', the gaps cause the fill to be drawn incorrectly:
screenshot from 2018-06-14 15-28-40

(The section of data at the very end of the graph is rendered correctly, but everything before the last gap is messed up.) For a simple example that reproduces this issue, see this codepen.

Interestingly, adding fill: 'tozeroy' to the bottom trace seems to resolve the obviously broken aspect of this issue:
screenshot from 2018-06-14 15-39-04

I would still argue that the expected behaviour is that connectgaps: false should result in no fill crossing the gaps.

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

Beginne damit, die verknüpfte CodePen-Reproduktion mit connectgaps: false, fill: 'tonexty', Lücken und asymmetrischer Unsicherheit auszuführen. Verfolge das Fill-Rendering-Verhalten von Plotly.js für die beiden Traces; abgeschlossen ist es, wenn die Füllung keine Datenlücken überquert und der letzte Abschnitt korrekt gerendert bleibt.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
javascript
Bereich
data-visualization
Issue-Typ
Bug
Schwierigkeit
4/5
Geschätzter Aufwand
3-5 Tage
Aktivitätsstatus
Veraltet
Klarheit
Größtenteils klar
Anfängerfreundlichkeit
42/100

Neue Issues direkt in Ihr Postfach

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