dygraphs icon indicating copy to clipboard operation
dygraphs copied to clipboard

Stacked graph not properly handling null values

Open ischolten opened this issue 7 years ago • 1 comments

Filing a bug report? Please include the following:

Currently I have two series of data that I am displaying as a stacked line graph. The data looks similar to this: [[null, null], [1, null], [null, null], [null, 1], [1, null], [null, 1], [null, 1], [null, 1]]

where the first value represents one series and the second value represents another. Currently the graph looks like the following when stackGraph is true.

screen shot 2018-11-30 at 4 25 01 pm

I would expect that the second(orange) series would move down and show at value 1 on the y axis since the first series had no values at that point.

  1. Browser and Operating System that exhibit the problem Currently using Chrome.

  2. Version of dygraphs that you're using: 2.1.0

ischolten avatar Dec 01 '18 00:12 ischolten

Does it work as expected if you use NaN instead of null? See https://dygraphs.com/data.html#array

mirabilos avatar Feb 07 '23 21:02 mirabilos