Apexchart lovelace card header decimal points

Hi all,
Trying to setup a apex chart lovelace card but even though i can set the y-axis decimals, it still shows up in the header rounded off. Is there any way one can adjust that as well ?

Must be overlooking something.

type: custom:apexcharts-card
header:
  show: true
  title: Average Time Per Shower Today
  show_states: true
  colorize_states: true
series:
  - entity: sensor.first_bathroom_shower_average
    data_generator: ''
    yaxis_id: both
  - entity: sensor.second_bathroom_shower_average
    type: column
    data_generator: ''
    yaxis_id: both
yaxis:
  - id: both
    decimals: 2

I’d like to know this too

You need the float precision

´´´
series:
- entity: sensor.stroom_dagtarief_per_maand
type: column
name: Stroom dagtarief
float_precision: 2
´´´

8 Likes

That did it, thank you very much.

Hi re - float_precision: 2, if say temp is 24.50 C, it shows 24.5,

Is it possible to get it to show the zero? i.e. 24.50

Many thanks.

Maybe you’re more likely to get an answer here.

1 Like

Had a gander, but didnt get an answer. Maybe it cant be done?

Series Options, use the float_precision

Interestingly, even that option doesn’t force the number of decimals: I have a data point 1.899 and with float_precision: 3 I get the correctly “1.899”, but if I set float_precision: 2 I get “1.9” which is not what I expected given the focumentation: “The precision used to display data in the legend and the tooltip. It doesn’t impact how the data is displayed on the graph”.

1 Like