Quantcast
Channel: Configuration - Home Assistant Community
Viewing all articles
Browse latest Browse all 107330

Apex Charts data_generator, entity.attributes aren't series data

$
0
0

I’m attempting to add a series to an Apex Chart that only return the oldest and newest values. Every example I see has something like…

- entity: sensor.scale
  data_generator: >
     return entity.attributes.weight.map(function() {
        ...
     });

The problem is, the sensors I’m interest only have strings in their .attributes like…

state_class: measurement
unit_of_measurement: kg
icon: mdi:scale-bathroom
friendly_name: Scale Weight

I was under the impression that’s how entity.attributes worked, they’re static info about the sensor itself. So all I have access to is the current entity.state. So my two questions are; why don’t my entities have series data in attributes? How do I get my series data if not available there?

1 post - 1 participant

Read full topic


Viewing all articles
Browse latest Browse all 107330

Trending Articles