I’m fairly new to Grafana, so I’m not sure what’s possible. But here’s my case:
I am using Grafana with data from InfluxDB, which is filled by Home Assistant. In Home Assisitant I have Sonoff PowR2’s storing power-usage data. The Sonoff isn’t really accurate and consistent by itself. It should reset it’s “Daily usage” every day at 00:00. Instead, it seems to reset at 01:00 on the next day. But stranger: the value on 01:00 is still not reset to 0, it almost seems that at the 01:00-mark it starts to gradually lower the value to 0, but posting updates along the way. Creating values somewhere between the max of day 1 and the zero-point on day 2. To visualize:
Graph, multiple days
Values around a reset
The thing I want to know is the total usage on a day, so basicly for each day the maximum value. However, since the reset is somewhere around 01:00 on the next day, I have no idea how to create a graph that shows this maximum value of a day, on the actualy day that this value was reached.
I was thinking about shifting the time of the graph about 2 hours back in time, so at least the maximum value would be somewhere between 22:00 and 24:00 on the actualy day it was reached, instead of 00:00 and 02:00 on the next day. And then using selector ‘max’ when I group by ‘1d’. But I cannot find out how to shift back the time 2 hours.
Does someone have any tips for me on how I could get the values I want?