Chartjs 2.5
I am looking at a possibility of displaying the data points on the bar-chart so that the bar width represents/shows the given time period. This would be useful for displaying all kinds of consumption entries, like energy consumption, where you have data points that represent a consumption over time (eg. from 15:00 to 16:00 or from a whole day, week, month, year etc. )
Note: I am also using the zoom-plugin, which changes the view-point based on the zoom-level.
Example:
Like, we want to show a daily energy consumption for a time range of the month June. Now we would need 30 entries each representing a whole day, so that each bar represents exactly one day (eg. stretching between 1st and 2nd and so on..)
Any ideas on how to approach this?
Not sure of the best way to support this. Once the time-series scale gets merged in v2.7 it should be closer to possible. @benmccann any thoughts based on your work with the time series charts?
If each bar represents the same amount of time then the timeseries scale should work well for you. If each bar represents a variable amount of time then you'd probably need to create a custom chart
Btw, the plan is to do some final fixes on the timeseries scale over the weekend and then send a PR for it next week
In the use-case that I mentioned each bar does indeed have the same width or well represents the same amount of time.
So I'll wait for 2.7, thanks allot guys 👍