Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Highcharts 24 hour setup for hourly values

Tags:

highcharts

I want to realize a chart (daily view) where hours start with 00:00, and end with 24:00, with one hour intervals. And showing Y axis values at specific hours like 14:30, 21:25 etc. What I successfully reached is showing the Y axis values, but the hours doesn't start with 00:00 and end with 24:00.. and they are kind of shifted, I see a part of the daily "timeline".

I use datetime type for X axis. My guess I have some zooming, or interval issues, tried several possibilities.

Thanks

like image 751
subdesign Avatar asked May 22 '13 14:05

subdesign


1 Answers

You can set:

    xAxis: {
        type: 'datetime',
        tickInterval: 3600 * 1000,
        min: Date.UTC(2013,4,22),
        max: Date.UTC(2013,4,23),
    },

Example: http://jsfiddle.net/93Xcu/7/

like image 79
Paweł Fus Avatar answered Nov 16 '22 23:11

Paweł Fus