A History Graph-Like Horizontal Bar Status Graph (configurable for multiple rows) #550
CharlesCage
started this conversation in
Show and tell
Replies: 1 comment 1 reply
-
Wow, that looks amazing! |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hey everyone! Long time listener, first time caller. I REALLY appreciate all the work on this custom card, and I get LOTS of helpful information from the show & tell and similar conversations. I bring in Google Pollen API information for my partner who is very sensitive to pollen, and I wanted to create something similar to the history graph to show one row for each pollen type and a sideways bar graph showing different colors for each value--you know, so it'd be easy for her to see what's in the air and also to scroll back and see how it changed over previous weeks.
Here's what it looks like:
Problem: Like others, I tried various solutions of horizontal stacked bar graphs, but ran into problems with repeating values (pollen can be 4 then 5 then 4 again) and the inability to pro grammatically generate entities, etc. I tried using a standard line graph, but I constantly had problems with lines overlapping each other, like a 4 that becomes a 5 and then a 4 again showing up as just 4.
My crazy solution:
Yeah, it's cheesy, but it works? 😆
I noticed that others were trying to do similar things, so I tried my best to modularize and document my code so others can use it without too much trouble. BUT, understand that it's a hacky solution... that's also hacked together. So if you find problems I apologize in advance. Here's a two bar example:
Note that it can easily be adapted to a single bar:
Or, of course, a kjillion like the one at the top.
Anyway, thanks everyone for all the help you've provided me, and I hope this might prove useful to some of you (and that my documentation makes it as easy as possible).
Beta Was this translation helpful? Give feedback.
All reactions