Description
The Graph widget in Gladys currently allows displaying multiple data points on the same graph.
It would be interesting to go a step further by allowing the type of representation for each series to be chosen independently.
The goal would be to be able to combine, for example:
- one or more series as bar charts;
- one or more series as curves.
This would allow for more natural representation of different types of data over the same period.
Concrete Example: Gas Consumption and Temperature
My use case is tracking my gas consumption.
I would like to display on the same graph:
- Gas consumption → bar charts, in kWh;
- Outside temperature → curve, in °C.
The interest is to be able to immediately visualize the relationship between the outside temperature and heating consumption.
For example, on a given day:
Bar charts: gas consumption (kWh)
Curve: outside temperature (°C)
The temperature would thus allow visualizing the correlation with heating consumption periods.
Two Y Axes
In this type of configuration, it would also be interesting to be able to use two Y axes when the units or orders of magnitude are different.
For example:
Left Y Axis
- Consumption: 0 to 30 kWh
Right Y Axis
- Temperature: -5 to 30 °C
This would avoid the difference in scale between the two data points making one of the series unreadable.
Ideally, the use of a second axis could be automatic when the units are different, or configurable by the user.
Other Use Cases
This possibility could be useful in many other cases:
- Solar production + electricity consumption: bar charts for both consumptions/productions and curve for instantaneous power;
- Electric power + outside temperature: bar charts in W + curve in °C;
- Precipitation + temperature: bar charts in mm + curve in °C;
- Wind speed + temperature: bar charts in km/h + curve in °C;
- Water consumption + outside temperature: bar charts in liters + curve in °C;
- Battery level + electricity consumption: curve of battery level + consumption bar charts.
Proposed Configuration
When configuring the widget, each feature could have parameters such as:
| Feature | Graph Type | Axis |
|---|---|---|
| Gas consumption | Bar chart | Left |
| Outside temperature | Curve | Right |
The user could thus freely build their graph by mixing representations adapted to each data point.
Why This Evolution?
The ability to display multiple features on the same graph is already very useful for comparing different data points.
However, when the data has different characteristics, forcing the same type of representation limits visualization possibilities.
Allowing the combination of bar charts, curves, and possibly multiple axes would make the widget much more powerful while remaining relatively easy to use.
This feature would be particularly interesting for dashboards focused on energy, weather, and the environment.