Home Forums Chart Support how to avoid to starting lines from value 0

how to avoid to starting lines from value 0

Viewing 3 posts - 1 through 3 (of 3 total)
  • #19303

    Hello,
    in my dataPoints sometimes I use to put some “null” values when I’ve no data for a certain point, but when canvasjs encounter this “null” value it seems to convert it to zero and the line starts from Y=0

    Eg if I’ve these 3 datapoints (1,null), (2,5), (3,6) the rendering enging will show 2 segments, the first one from (1,0) to (2,5) and the second one from (2,5) to (3,6). Is there a way to avoid showing the first segment? I would that canvasjs skips all lines having null values as Y coordinate.

    #19307

    @blacktek,

    Adding a null dataPoint in the begining seems to be working fine and is not considered as zero. Please take a look at this jsfiddle. If you are still facing the issue, kindly create a jsfiddle reproducing the issue so that we can look at it and help you out.

    ___________
    Indranil Deo,
    Team CanvasJS

    #19311

    you’re correct; I made a cast to float for all the Y values in another part of the code and this was traslating null to 0.

    thank you

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.