Karthik VU
Karthik VU

Reputation: 561

Highcharts : Plotting Data versus Date

I am having some data which looks like [{"data":[22,27,22,13],"name":"Data1"},{"data":[31,31,31,50],"name":"Data2"}. Every value corresponds to a progressing day. How do I plot this data versus date, while the length of data being dynamic.

I don't want to specify the "Categories", because my data is dynamic. Range varies everytime. I can supply the start date and end date.

Fiddle here.

Upvotes: 0

Views: 50

Answers (1)

Sebastian Bochan
Sebastian Bochan

Reputation: 37588

You can set pointInterval / pointStart, like here.

plotOptions:{
        series:{
            pointStart: Date.UTC(2015,4,1),
            pointInterval: 24 * 3600 * 1000
        }
},

Example: http://jsfiddle.net/978svgc9/2/

Upvotes: 1

Related Questions