M
M
miki1312014-11-07 04:11:00
Canvas
miki131, 2014-11-07 04:11:00

How to make a timeline chart?

[{
    "status": "Undefined",
    "start": "00:00:00",
    "duration": 50518
  }, {
    "status": "Unavailable",
    "start": "14:01:58",
    "duration": 11
  }, {
    "status": "Pending",
    "start": "14:02:09",
    "duration": 0
  }, {
    "status": "Available",
    "start": "14:02:09",
    "duration": 952
  }]

I have data like this.
I need to draw a graph of activity per day.
Now it's just on canvas - I count the number of seconds per 1 pixel for a given scale and draw rectangles of different colors.
Question: is there any ready-made solution for this kind of charts?

Answer the question

In order to leave comments, you need to log in

3 answer(s)
V
Vitaly Peretyatko, 2014-11-07
@miki131

I use such a library almende.github.io/chap-links-library/js/timeline/d...
only in it the format is slightly different, the start time and end time of the event.
there are many different such libraries, write in Google "timeline js" and choose to your taste

M
Maksim Zverev, 2014-11-07
@m1skam

Look towards chartjs

A
Alexander, 2014-11-07
@drunking

1) www.highcharts.com
2) d3js.org

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question