#Statistics graph Card, what am I missing?

1 messages · Page 1 of 1 (latest)

ionic root
#

I'm pretty new to Home Assistant, but despite that I've (miraculously) achieved to create a rest integration that is now shown in Entities, with correct device class, and is now importing the numbers (pm2.5 and temp) into HA. I can see data in History and also in a History graph card.

But i would like to show the data in Statistics graph Card. The entities dropdown says "You don't have any statistics". I looked at the documentation, but I guess I'm missing the point of whatever I'm missing. What's the missing step? Do i need to set up a Recorder? Or some sort of aggregating component?

Thanks!

thorny jay
#

You will need to create a statistics helper from your entities. Statistic is available in the helper section

ionic root
mint heron
#

Sorry that's the wrong advice. Statistics helper has nothing to do with Long Term Statistics/Statistics graph.

#

To be recorded for statistics an entity must have a state_class, does your entity have a state_class attribute?

ionic root
#

They show up now in the dropdown, so far so good

#

But still see this:

#

I have verified with History graph that data is coming in

#

Scratch that... i didn't revert the change per previous advice

#

in the card entity dropdown

mint heron
#

Is entity listed in developer-tools/statistics? Does it have any issue?

ionic root
#

listed and no issue

#

hmm... ok, when I switch to bar, i see something

#

i can choose Mean, min and max, all good

#

but line shows nothing etm

#

atm

mint heron
#

Are you choosing hourly or 5m?

ionic root
#

hourly

#

default

#

when i stat graph cars is added, does it take historical data or only from when card was created? wondering if I just need to leave it

#

ok, 5 min helped...

mint heron
#

no when the card was created doesn't matter

#

if you just setup the entity (or fixed the state_class) though you probably need to wait another 20m till the next hour?

ionic root
#

ah yeah ok... well, history graph has been showing data for a while now. However, state_class and unit is a very recent change (HA let me fix old values from "" to the new unit which is pm25 and C)

mint heron
#

Yeah it won't start recording LTS until you had all that sorted.