Maxion
Maxion

Reputation: 45

Highstock not rendering properly; displays empty series until zooming in

I've got Highstock running on a website loading two series from two different csv/log files on the same webserver.

I previously had this exact setup on a different server where it worked flawlessly.

On the new server, however, the chart doesn't render properly. When the page is loaded the series lines do not display. If you zoom in, or scroll away from the rightmost edge of the chart the lines pop into view. If you scroll back all the way to the right the lines stop displaying.

The actual chart can be seen here on this temporary page: http://maxedin.com/pages/18/

The JS which loads the chart here: http://jsfiddle.net/3Jpb3/

The chart is loaded with this div element:

<div id="mholmen" style = "width:100%"></div>

I've tried playing around with the different zoom options, chart sizes, modifying the data that's being loaded and such to no luck.

Has anyone else bumped into this same issue and managed to fix it?

Upvotes: 0

Views: 460

Answers (2)

Maxion
Maxion

Reputation: 45

Thanks to Pawel Fus I figured it out. Turns out the text editor nano which I used to view and edit the log files did some odd things while saving them. Editing the files in textwrangler fixed my problems. Go figure.

Upvotes: 0

Paweł Fus
Paweł Fus

Reputation: 45079

In your data you have some NaN's, for example:

lines[2154]: Array[2] 
    0: NaN
    1: NaN 

Which can not be displayed on a chart. Make also sure that data doesn't contain duplitaced and is ordered for xAxis ascending.

Upvotes: 1

Related Questions