My electricity price dashboard (with future prices) #224
Replies: 6 comments 18 replies
-
@edwardtfn Thanks for the quick reply. I am struggling to get the future prices from the array. I use nordpool data. |
Beta Was this translation helpful? Give feedback.
-
I just installed the NordPool integration, so I don't have historical data to try it, so please try and let me know the results: type: custom:plotly-graph
time_offset: 1.5d
refresh_interval: 300
hours_to_show: 84
layout:
xaxis:
rangeselector:
'y': 1.2
buttons:
- count: 7
step: day
- count: 12
step: day
yaxis:
rangemode: tozero
tickformat: .1f
yaxis2:
rangemode: tozero
tickformat: .2f
fixrange: true
yaxis9:
visible: false
fixedrange: true
round: 2
default: null
entities:
- entity: sensor.total_energy_utility_meter
name: Energy consumption
type: bar
marker:
color: rgba(165,165,0,0.6)
texttemplate: ' %{y:.2f} kr/kWh'
statistic: state
period: hour
filters:
- fn: |-
(params) => {
const ys = [];
ys.push(0);
for (let i = 1; i < params.statistics.length; i++){
ys.push(params.statistics[i].state-params.statistics[i-1].state);
}
return { ys };
}
- entity: sensor.nordpool_kwh_se3_sek_3_10_025
name: Electricity price
yaxis: y2
unit_of_measurement: kr/kWh
line:
color: rgba(255, 165, 0, 1)
width: 3
filters:
- store_var: electricity_price
- exponential_moving_average:
alpha: 1
show_value: true
texttemplate: ' %{y:.2f} kr/kWh'
- entity: sensor.nordpool_kwh_se3_sek_3_10_025
yaxis: y2
name: Future price
fill: tozeroy
fillcolor: rgba(255, 165, 0,.1)
line:
color: rgba(255, 165, 0, 1)
width: 1
dash: dot
filters:
- fn: |-
({ meta, vars }) => ({
xs: [vars.electricity_price.xs.slice(-1)[0],...meta.raw_today.concat(...meta.raw_tomorrow).map(({ start }) => new Date(start))],
ys: [vars.electricity_price.ys.slice(-1)[0],...meta.raw_today.concat(...meta.raw_tomorrow).map(({ value }) => value)],
})
- exponential_moving_average:
alpha: 1
- entity: ''
name: Now
yaxis: y9
showlegend: false
line:
width: 1
dash: dot
color: deepskyblue
x: $fn () => [Date.now(), Date.now()]
'y': $fn () => [0,1] |
Beta Was this translation helpful? Give feedback.
-
works perfect. Just made minor adjustments to avoid the overlap from the future prices into current prices with a straight line |
Beta Was this translation helpful? Give feedback.
-
type: custom:plotly-graph
time_offset: 1.1d
refresh_interval: 10
hours_to_show: 84
layout:
xaxis:
rangeselector:
'y': 1.4
buttons:
- count: 7
step: day
- count: 12
step: day
yaxis:
rangemode: tozero
tickformat: .1f
yaxis2:
rangemode: tozero
tickformat: .2f
fixrange: true
yaxis9:
visible: false
fixedrange: true
round: 2
default: null
entities:
- entity: sensor.aidon_energy_monthly
name: Energy consumption
type: bar
marker:
color: rgba(165,165,0,1)
texttemplate: ' %{y:.2f} kr/kWh'
statistic: state
period: hour
filters:
- fn: |-
(params) => {
const ys = [];
ys.push(0);
for (let i = 1; i < params.statistics.length; i++){
ys.push(params.statistics[i].state-params.statistics[i-1].state);
}
return { ys };
}
- entity: sensor.nordpool_kwh_krsand_nok_2_10_025
name: Electricity price
yaxis: y2
unit_of_measurement: kr/kWh
line:
color: rgba(255, 165, 0, 1)
width: 3
filters:
- store_var: electricity_price
- exponential_moving_average:
alpha: 1
show_value: true
texttemplate: ' %{y:.2f} kr/kWh'
- entity: sensor.nordpool_kwh_krsand_nok_2_10_025
yaxis: y2
name: Future price
fill: tozeroy
fillcolor: rgba(255, 165, 0,.1)
line:
color: rgba(255, 165, 0, 1)
width: 1
dash: dot
filters:
- fn: |-
({ meta, vars }) => ({
xs: [vars.electricity_price.xs.slice(-24)[0],...meta.raw_today.concat(...meta.raw_tomorrow).map(({ start }) => new Date(start))],
ys: [vars.electricity_price.ys.slice(-24)[0],...meta.raw_today.concat(...meta.raw_tomorrow).map(({ value }) => value)],
})
- exponential_moving_average:
alpha: 1
- entity: ''
name: Now
yaxis: y9
showlegend: false
line:
width: 1
dash: dot
color: deepskyblue
x: $fn () => [Date.now(), Date.now()]
'y': $fn () => [0,1] |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.
-
I'm new to home assistant and want to try to use this as Want to know my energy cost. How do I set this up? Is there an integration for US prices like Nordpool? |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
My first time playing with this card, I've created an electricity price dashboard where we can see the price per kWh and my consumption (also in kWh), so I can take decision on when to run my appliances and try to save some money.
I've also added a line to show now, with the current price.
You can find here my sensors for electricity price from Tibber. I'm not using the official Tibber integration for that, as I got more stable/reliable sensors with direct REST queries.
In that same repository you can find all my energy consumption calculations per room and total at home, used in an utility meter and.then used as a sensor in this dashboard.
Don't hesitate to ask if you have any question. I would love to help.
Beta Was this translation helpful? Give feedback.
All reactions