ethangk
ethangk

Reputation: 109

Highcharts not drawing lines between points

EDIT: The problem was that the intervals were inconsistent. Between this post and this post, it can be fixed fairly easily.

I am using highcharts to draw a chart, with initial points being provided within the highcharts code, then the rest of the points are pulled in with ajax.

The initial points draw perfectly, and the first few fetched points also work fine, but every few minutes the points will stop being connected on the graph, then it will correct itself, then screw up again.

Does anyone have any idea what could be causing this?

Upvotes: 4

Views: 6019

Answers (3)

Manu
Manu

Reputation: 99

I had a similar issue, I noticed that some of my 'empty' values were undefined and some were null values. I changed it all to be null and it did the trick.

Upvotes: 0

Abram
Abram

Reputation: 41954

You need to ensure that you have null instead of an empty string, etc, but also ensure you have enabled connectNulls in plotOptions as follows:

plotOptions: {
    series: {
        connectNulls: true
    }
}

See JS FIDDLE

Upvotes: 3

FoosFodder
FoosFodder

Reputation: 376

Had the same problem. My issue was that empty values (not zero, but a no-value-exists type scenario) were empty strings (""). Changing those values to null magically connected the dots for me.

Upvotes: 4

Related Questions