NordPool-core integration with ApexCharts?

We have now NordPool integration in HA Core, which is great thing itself. Previously we had to use NordPool custom integration, which is great integration generally. However, moving to Core integration from HACS version broke my ApexCharts graphs on NordPool prices (today and tomorrow).

Tried to understand data_generator of ApexCharts, it was no-go for me. Naturally I changed data generator to read new NordPool sensor, however, it returns values slighlty differently comapred to HACS Nordpool? For example, whole day and next day are returned as part of sensor.average_electricity_price_today

Has anyone changed to Core-version of NordPool integration and working ApexCharts config to share? Thanks in advance!

3 Likes

It seems I made mistake about sensor.average_electricity_price_today, it’s sensor by Entso-e platform, I had it also installed because of redundancy.

Could you provide your code that works to show the prices of today and tomorrow ?

Mine is no longer working and I get only today or tomorrow.

  series:
    - entity: sensor.nordpool_kwh_ger_eur_4_10_0
      name: "\_PREIS"
      unit: "\_CENT / kWh"
      yaxis_id: first
      show:
        in_header: before_now
        name_in_header: false
        extremas: true
      color_threshold:
        - value: 17.5
          color: 4DD0E1
        - value: 20
          color: 26A69A
        - value: 22.5
          color: 4CAF50
        - value: 25
          color: 7CB342
        - value: 30
          color: FBC02D
        - value: 35
          color: EF6C00
        - value: 40
          color: B71C1C
      type: line
      curve: stepline
      extend_to: false
      stroke_width: 4
      float_precision: 1
      data_generator: |
        return entity.attributes.raw_today.map((start, index) => {
          return [new Date(start["start"]).getTime(), entity.attributes.raw_today[index]["value"]];
        });
1 Like

Have you managed to solve it? I’m also having the same issue. I can’t find a way to show the prices in a chart (preferably Apexcharts) for yesterday and today.

1 Like

My solution was to continue using Entso-e platform (from HACS), integrated Nordpool isn’t mature enough IMO. I’ll give it a try later, when it has more features. With Entso-e, it’s easy to work with Apex Charts.

:embarassed: not sure either how to solve this

… so, I made a 2nd sensor that always uses the date today to fill while the other takes tomorrow as soon as possible so in the afternoon it switches to tomorrow while in the morning it is today

anyone know how to show forecast/tomorrow data presumably saved earlier in the sensor, please share!!

There is another thread about this that has the solution:

Tomorrows price unavailable with Nordpool core integration

It’s the 30th September, so it was time to test Tomorrows data which has moved from 24 hourly elements to 15 minute elements (96 in total).
The top right hand Tool Bar helps viewing this amount of data.

And now it’s the 1st of October. Small change in graph values is due to my provider reducing the Purchase charge from €0.04840 to €0.02 at midnight.

1 Like

this is with the core integration of Nordpool?

In that case: can you share the code for it please? I can’t find it anywhere…