Hi, I have a slightly irritating problem that I can’t get rid of…
Every time I reboot my HA I get a value from the adjusted sensor showing like a “dip” in the graph, and I wonder if there is a way to remove this “dip” from my graph?
You won’t be able to without pulling the previous temperature. On startup, your sensors aren’t ready. When this happens your equations will return a sensor value of 0 and it will be reported. You can attempt to wrap your templates in an if statement so that the template returns a blank value. Not sure how that will impact the graph result though.
Also, as a side note, that round function is doing nothing to your whole value. It’s only affecting the subtracted or added number. filters work like order of operation in math. So your templat is subtracting a rounded 5 from your sensor value. Better put those in parenthesis.
- platform: template
sensors:
grund_humidity_adjusted:
friendly_name: "Källargrund Fukt"
unit_of_measurement: '%'
value_template: >
{% if states.sensor.199_humidity is defined %}
{{ ( states('sensor.199_humidity')|float - 5 ) | round(1) }}
{% endif %}