Quantcast
Channel: Configuration - Home Assistant Community
Viewing all articles
Browse latest Browse all 107924

How to calculate average hourly energy consumption over multiple days?

$
0
0

Hi everyone,

I have been logging my energy consumption for a long time in Home Assistant.
Now, I would like to calculate the average energy consumption for each specific hour across multiple days.

For example:

  • What is my average consumption between 12 PM and 1 PM over the last 3 months?
  • Ideally, I want a table showing each hour of the day (00–01, 01–02, …, 23–00) with the corresponding average consumption.

I understand that the data is stored in the home-assistant_v2.db SQLite database.
Is there a built-in way in Home Assistant to generate this (using templates, statistics, SQL integration, etc.)?
Or would I need to manually query the database with an SQL statement?

Any guidance or examples would be greatly appreciated!

Thank you! :blush:

1 post - 1 participant

Read full topic


Viewing all articles
Browse latest Browse all 107924

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>