Chart.js
Chart.js copied to clipboard
Line graph time issue
Im having an issue with using the time scale type. I want the graph to start at the very start of the graph and end at the very end but i get something that looks like this https://jsfiddle.net/13zy7ykt/4/
Hi gaz492
You will need to supply labels (of time) that correspond to each of your data points.
eg:
//labels: [1470525209000,1470528809000],
labels: ['01:00','02:00','03:00','04:00','05:00','06:00','07:00'],
https://jsfiddle.net/13zy7ykt/5/
Note that time.format is the format of your "input" labels and displayFormat is the "output" or the actual labels.
Another option is to use the time.min and time.max settings to get exact start and end points for the x axis.