Lovelace: mini graph card

Thanks all. I seemingly have it working now. I reinstalled to double check the installation as well as changed the card configuration.

Thank you!

Like i mentionned

Type doesnt have to be the first Line
Last Line works evenly well

I have the very same problem! Did you ever find a solution?

That can happen when there’s no history data available for the entity in HA.
Make sure you’ve set up history & recorder correctly and it’s working as intended, make sure that the entity isn’t excluded from the recorder.
You can try with the default history-graph card, it should also not display the graph if the above is the case.

Hey @kalkih, thank you for your answer - it works perfectly fine with the default card.
I could locate the problem in the meantime. My card-config includes the following:

update_interval: 300

when I remove it, the graph loads instantly.

When a graph has negative numbers, is it possible for the fill to be towards the Y zero axis. For example, in the screen shot below you can see the fill is to the lowest Y axis point -2546.34, where as it would be nicer in this use case to fill to the y axis. Screenshot 2020-05-12 at 09.56.25

Can the size of the extrema font be changed independently of the state font?

Hello everyone.

I am using this (great) card to show daily energy consumption. I am aggregating data by date (day), so I would expect to see full dates per datapoint, but instead I am getting the 0am - 11:59pm range per data point.
Is there a way to view dates on each data point?

00:00 to 23:59 sounds a lot like a full day to me :smiley:
Am I missing something?

Yes, it is a full day, but what I am trying to achieve is one datapoint per day, thus it makes more sense to present them as a full date on the x-axis rather than a time range, otherwise I will have a series of bars with 0 - 23:59 with no clue about the actual day each one refers to.

Could it be something missconfigured?
Because you should also have the date:
image

I have been struggling a bit with the layout of the mini-graph-card.
The amount of empty white space in the card is bothering me.
I was wondering if it is possible to control the size of the graph and placement of the text boxes.
Ideally (for me) the graph would span the entire height of the card and the extrema / current state info would be printed on top.

Is there any way to realize such lay-out?
I have played with the height setting but it would just stretch the card more at the bottom, I’m looking more for a way to bring the elements of the card closer to each other.

Agreed. I love this card, not only does it look great, but the customization options are amazing so thank you very much to Kalkih. Losing some of the whitespace however would take it to the next level, pushing min/max up to the same line as actual as an example would reduce the overall size by ~20%

2 Likes

Hi all, I have temperature and humidity showing on the same card. Is it possible to show ave, min and max values on the card for both entities? No matter where I place the show code it only seems to apply to the temperature entity which is the primary or first entity.

image

name: Greenhouse
hours_to_show: 48
icon: 'mdi:home-floor-g'
show:
  extrema: true
  average: true
entities:
  - sensor.greenhouse_temperature
  - sensor.greenhouse_humidity
y_axis: secondary
1 Like

@kalkih Hi Karl is it possible to set a target line over the history line?

Not really, you could create a template sensor and give it the target value and use that entity in the graph, would that do it?

thats a clever work around yep it won’t change so that will do

1 Like

Can I have a combo of line and bar on the same card?

Is it possible to use the mini graph card to display the data directly from a sensor attribute (today and tomorrow)?

In this case the sensor updates once an hour, today contains electricity price for every hour of the day, likewise for attribute tomorrow.

If not, any ideas how to display the data as a graph?

No

No not possible, and I am unfortunately not aware of a solution, maybe grafana?