log graphs on longer period

Use this forum to discuss possible implementation of a new feature before opening a ticket.
A developer shall edit the topic title with "[xxx]" where xxx is the id of the accompanying tracker id.
Duplicate posts about the same id. +1 posts are not allowed.

Moderators: leecollings, remb0

Post Reply
ricorico94
Posts: 94
Joined: Monday 26 October 2015 10:41
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

log graphs on longer period

Post by ricorico94 »

Hi,
Would it be possible to visualize data on more than 1 week or more than 1 year ?
Currently, there's a comparison graph which is useful, but I'd appreciate being able to compare "month to month", like comparing January 2023 with January 2024, or comparing the same day between current week with current one (like today, we're Saturday 23rd, and I'd like to compare Friday22d with Friday 17th).
I understand that there's need to summarize data to avoid database growth, but it could be interesting to have a setting to enable graphs showing like "13 months" instead of 12 months, and 8 days instead of 7, to have at least some detailed comparison available.
There could be also a feature to "export" the detailed measurements regularly and automatically, so that we don't lose detailed historical measurements (for users having enough storage) and so that we could add some comparison graphs or calculations, and this, without impacting size of the main domoticz database..
br,
Ricorico94
User avatar
waltervl
Posts: 5148
Joined: Monday 28 January 2019 18:48
Target OS: Linux
Domoticz version: 2024.7
Location: NL
Contact:

Re: log graphs on longer period

Post by waltervl »

For that users normally use the export to influxdb functionality.
https://www.domoticz.com/wiki/Influxdb

Combined with Grafana you can show all kind of neat comparisons on detailed information in nice graphics.

Google the combination Domoticz Influxdb Grafana for more information.
Domoticz running on Udoo X86 (on Ubuntu)
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
ricorico94
Posts: 94
Joined: Monday 26 October 2015 10:41
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: log graphs on longer period

Post by ricorico94 »

Hi,
I've indeed used Influxdb and Grafana to export data, but it forces to add other apps, so higher maintenance, more problems, more knowledge on reporting, etc. Not really user friendly as an overall solution, even thoughI agree that these 2 other tools are themselves individually very powerful.
It would be so much simpler if graphs in domoticz were showing the last 13 or 14 months instead of only 12 , meaning that you can't compare the existing month with the same of previous year.. Same thing for week view where comparing 2 same days of the week would be so useful.
Maybe it's just a couple settings in Domoticz which would allow people to define the detailed view window.. then anyone could decide whether they want to optimize viewing capabilities or minimize size of database.

br,
Ricorico94
User avatar
waltervl
Posts: 5148
Joined: Monday 28 January 2019 18:48
Target OS: Linux
Domoticz version: 2024.7
Location: NL
Contact:

Re: log graphs on longer period

Post by waltervl »

If it were just some settings it would already been done....

But, in a lot of sensors you also have the previous year option which enables you to compare last 2 years including last month
Screenshot_20240324-160740.png
Screenshot_20240324-160740.png (99.69 KiB) Viewed 780 times
If someone with JavaScript programming experience feels the need to add functionality they are welcome to create a PR.
Domoticz running on Udoo X86 (on Ubuntu)
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
Kedi
Posts: 536
Joined: Monday 20 March 2023 14:41
Target OS: Raspberry Pi / ODroid
Domoticz version:
Location: Somewhere in NL
Contact:

Re: log graphs on longer period

Post by Kedi »

How do you get that graph?
Mine shows Past Usage and Trend Usage with strikethrough text
Logic will get you from A to B. Imagination will take you everywhere.
ricorico94
Posts: 94
Joined: Monday 26 October 2015 10:41
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: log graphs on longer period

Post by ricorico94 »

To be honest, I had seen this "total usage" and "past usage" without understanding what it was calculating..
What is this "past usage" ? the usage during previous period (previous year or previous month depending on the graph you look at ?) ? or the sum of several previous periods ? Is it documented somewhere ?
waltervl wrote: Sunday 24 March 2024 16:13 If it were just some settings it would already been done....
Then indeed, if it means a structural change in Domoticz, I can understand reluctancy.. I don't know enough of domoticz structure and its underlying database to assess the difficulty and I know developer's time is precious. Thanks anyway for having answered.
Kedi
Posts: 536
Joined: Monday 20 March 2023 14:41
Target OS: Raspberry Pi / ODroid
Domoticz version:
Location: Somewhere in NL
Contact:

Re: log graphs on longer period

Post by Kedi »

Found it, so simple. :oops: A mouseover would help.
Logic will get you from A to B. Imagination will take you everywhere.
User avatar
waltervl
Posts: 5148
Joined: Monday 28 January 2019 18:48
Target OS: Linux
Domoticz version: 2024.7
Location: NL
Contact:

Re: log graphs on longer period

Post by waltervl »

Kedi wrote: Sunday 24 March 2024 16:25 How do you get that graph?
Mine shows Past Usage and Trend Usage with strikethrough text
You can click on the greyed out options to enable them
Domoticz running on Udoo X86 (on Ubuntu)
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
User avatar
waltervl
Posts: 5148
Joined: Monday 28 January 2019 18:48
Target OS: Linux
Domoticz version: 2024.7
Location: NL
Contact:

Re: log graphs on longer period

Post by waltervl »

ricorico94 wrote: Sunday 24 March 2024 16:44 To be honest, I had seen this "total usage" and "past usage" without understanding what it was calculating..
What is this "past usage" ? the usage during previous period (previous year or previous month depending on the graph you look at ?) ? or the sum of several previous periods ? Is it documented somewhere ?
It is what is says. The past years values shows the corresponding value of last year so you can compare it with this year's value.
Domoticz running on Udoo X86 (on Ubuntu)
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest