Spaces:
Sleeping
Sleeping
Upload app.py
Browse filesreset fig_price plot to unscaled
app.py
CHANGED
|
@@ -1012,21 +1012,17 @@ def plot_electricity_prices(m, dt, col, df, df_residual_load_duration):
|
|
| 1012 |
with col:
|
| 1013 |
st.plotly_chart(fig_duration)
|
| 1014 |
|
| 1015 |
-
if st.session_state.level == "undergraduate":
|
| 1016 |
# Line plot for electricity prices
|
| 1017 |
-
|
| 1018 |
-
|
| 1019 |
-
|
| 1020 |
-
|
| 1021 |
-
|
| 1022 |
-
|
| 1023 |
-
|
| 1024 |
-
fig_price
|
| 1025 |
-
|
| 1026 |
-
|
| 1027 |
-
labels={'dual': '', 't': ''}
|
| 1028 |
-
)
|
| 1029 |
-
|
| 1030 |
with col:
|
| 1031 |
st.plotly_chart(fig_price)
|
| 1032 |
|
|
|
|
| 1012 |
with col:
|
| 1013 |
st.plotly_chart(fig_duration)
|
| 1014 |
|
|
|
|
| 1015 |
# Line plot for electricity prices
|
| 1016 |
+
fig_price = px.line(df_price, y='dual', x='t',
|
| 1017 |
+
title=df.loc['plot_label_electricity_prices', st.session_state.lang],
|
| 1018 |
+
# range_y = [0, 250],
|
| 1019 |
+
labels={'dual': '', 't': ''}
|
| 1020 |
+
)
|
| 1021 |
+
|
| 1022 |
+
if st.session_state.level == "undergraduate":
|
| 1023 |
+
fig_price.update_yaxes(range=[0, 300], autorange=True) # Set initial view, autoscale remains available
|
| 1024 |
+
|
| 1025 |
+
|
|
|
|
|
|
|
|
|
|
| 1026 |
with col:
|
| 1027 |
st.plotly_chart(fig_price)
|
| 1028 |
|