Database and visualization question: displaying growth value and total value with date/time filter

inspired by this graph

I have my IoT project to display energy management. i set my power consumption sensor then calculate to get energy consumption. for the output i want to make the graph above with date/time filter (a day, a week, and so on). With those filters, i imagine this:

Is it possible to show those in a single graph? Even better with time filter though

That's just a display, but how about the database (even for a flat csv)? what i prepare for now are date, time, and sensor value. what i haven't yet is the chart and its logic. Here's the thing:

  1. I've prepared key parameters: date, time (with microseconds). I use mosquitto for transmission but that's different topic here
  2. For the web app, I use Flask with SocketIO and Paho as framework. I don't use any javascript engine like React nor have experience on nvm for now
  3. I haven't prepared the chart and its logic yet. For logic, i possibly use python or javascript to calculate the energy value based on the time frame. I still only have the data in flat csv, but haven't store in database yet. What if i call directly on that database to calculate?
  4. For chart, which javascript chart has time filter implementation? I just know amchart for this day, but more examples, the better

submitted by /u/Famas_1234
[comments]



Source link

Write A Comment