How to add a reference line? #357
Answered
by
dbuezas
jazzmonger
asked this question in
Q&A
-
I'd like to add a dotted reference line so I can see if graphs fall above or below a specific value. How might I do this? |
Beta Was this translation helpful? Give feedback.
Answered by
dbuezas
Jan 17, 2024
Replies: 2 comments
-
Like the "Now line" https://github.com/dbuezas/lovelace-plotly-graph-card?tab=readme-ov-file#now-line but horizontal in the other axis. Option 1The line spreads as wide as is currently visible: - entity: ""
name: Theshold of 15
yaxis: y
showlegend: false
line:
width: 1
dash: dot
color: deepskyblue
x: "$ex get('visible_range')"
y: [15,15] Option 2The line spreads as wide as another entity - entity: sensor.the_other_entity
filters:
- store_var: other_entity
- entity: ""
name: Theshold
yaxis: y
showlegend: false
line:
width: 1
dash: dot
color: deepskyblue
x:
- "$ex vars.other_entity.xs.at(0)"
- "$ex vars.other_entity.xs.at(-1)"
y: [15,15] |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
dbuezas
-
I NEVER would have figured that out! thanks! |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Like the "Now line" https://github.com/dbuezas/lovelace-plotly-graph-card?tab=readme-ov-file#now-line but horizontal in the other axis.
Option 1
The line spreads as wide as is currently visible:
Option 2
The line spreads as wide as another entity