Hello!
I would like to create a graph of 15 minute average of my energy power data from Shelly 3EM device for finding 15 minute peaks of power in Grafana/InfluxDB/HomeAssistrant. I have a reference in state app for electricity (MojElektro). First I would like to find which timeframe is included in MojElektroApp measurements 26. 12. 2023 at 23.45 - 2kW (15min). I suppose it’s at the end of interval?
When comparing to graph in Grafana there seems to be a time shift of roughly 15 minutes - at 23.30 - 1.78kW.
This is the code in InfluxDB/Flux so far:
from(bucket: “homeassistant/autogen”)
|> range(start: v.timeRangeStart, stop: v.timeRangeStop)
|> filter(fn: (r) => r[“entity_id”] == “power_a_b_c”)
|> filter(fn: (r) => r[“_measurement”] == “W”)
|> filter(fn: (r) => r[“_field”] == “value”)
I would like to add code for 15 minute average and in the same time shift the data for 15 minutes in advance or back.
Thank you!