Plotly different Y-axis direction with binary sensors

Hi, why are there different directions with binary sensors?

type: custom:plotly-graph
entities:
  - entity: binary_sensor.vicare_burner_active
hours_to_show: 24
refresh_interval: 10
title: Brenner-Diagnose

plots like this:
image

While:

type: custom:plotly-graph
entities:
  - entity: binary_sensor.haustur_motion
hours_to_show: 24
refresh_interval: 10

plots like this:
image

Note that the values for “on” and “off” are differnt in both plots. Seems to me, that the placement is determined by the time value the sensor is in “on” state. I need the “on” value on top, regardless how long the binary sensor is “on”. How to accomplish this?

I have the same problem: Have you found a solution? It gets reverse on it’s own. One day “True” is up and other day is “False”.

Finally!

layout:
  yaxis:
    categoryorder: array
    categoryarray:
      - off
      - on
3 Likes

Thanks. My usecase was to correlate wirh another sensor. So I made a template sensor which multiplies the value from the other senso with the state of the binary sensor.