Hi All
Ive got a water meter that works on a pulse. For the current state its an int.
I would like to use history stats on water used for the day but im finding it difficult.
Is there any easy way to do this?
Hi All
Ive got a water meter that works on a pulse. For the current state its an int.
I would like to use history stats on water used for the day but im finding it difficult.
Is there any easy way to do this?
sensor:
- platform: statistics
name: water_use_24h
entity_id: sensor.water_meter_litre
max_age:
hours: 24
Now you have all that statistics you would want on it.
count
, mean
, median
, stdev
, variance
, total
, min_value
, max_value
, min_age
, max_age
, change
, average_change
and change_rate
You will almost certainly have to set the sample size greater than the default (20) for 24 hours of data. You can see if this is required by looking at the max age in the developer tools states menu.