How to show only extrema and/or average values:
It is rather convenient to see extrema and/or average values right in the graph:
But sometimes it is required to have 2 or more graphs on the card - in this case displaying extrema/average values is possible for only one sensor, which is confusing.
By using this template it is possible to display extrema/average values on a separate card, so you may display a mini-graph-card
with 3 graphs and 3 small cards below stacked vertically:
Here is a code:
type: custom:decluttering-card
template: decl_graph_tmpl
variables:
- tmpl_VALUE_TITLE: ... some title ...
- tmpl_INPUT_HOURS_TO_SHOW: ...
- tmpl_INPUT_SHOW_EXTREMA: input_boolean.service_true_value
- tmpl_INPUT_SHOW_AVERAGE: input_boolean.service_true_value
- tmpl_VALUE_GRAPH_TYPE: false
- tmpl_INPUT_REALTIME: ...
- tmpl_VALUE_COMPACT_MIN_MAX_AVG_INFO: ... true or false ...
##############################################################
- tmpl_SENSOR: ... some sensor...
- tmpl_VALUE_NAME: ''
- tmpl_VALUE_SHOW_STATE: false
The tmpl_VALUE_COMPACT_MIN_MAX_AVG_INFO
variable is used to make fonts for extrema/average values smaller. Surely it may be used in a “usual graphs” (i.e. graphs with a curve & extrema/average values).
A small example: I needed these graphs to be stacked horizontally, so I applied this “small font” style.