Spaces:
Sleeping
Sleeping
Upload app.py
Browse files
app.py
CHANGED
|
@@ -962,25 +962,48 @@ def plot_electricity_prices(m, dt, col, df, df_residual_load_duration):
|
|
| 962 |
))
|
| 963 |
|
| 964 |
# Layout mit separaten Achsen
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 965 |
fig_duration.update_layout(
|
| 966 |
-
|
| 967 |
-
|
| 968 |
-
|
| 969 |
-
|
| 970 |
-
|
| 971 |
-
|
| 972 |
-
|
| 973 |
-
|
| 974 |
-
tickfont=dict(color='blue') # Blue ticks for primary axis
|
| 975 |
),
|
| 976 |
-
|
| 977 |
-
|
| 978 |
-
|
| 979 |
-
|
| 980 |
-
|
| 981 |
-
|
| 982 |
-
|
| 983 |
),
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 984 |
legend=dict(
|
| 985 |
x=1, # Positioniert die Legende am rechten Rand
|
| 986 |
y=1, # Positioniert die Legende am oberen Rand
|
|
|
|
| 962 |
))
|
| 963 |
|
| 964 |
# Layout mit separaten Achsen
|
| 965 |
+
# fig_duration.update_layout(
|
| 966 |
+
# title=df.loc['plot_label_price_duration_curve', st.session_state.lang],
|
| 967 |
+
# xaxis=dict(
|
| 968 |
+
# title=df.loc['label_hours', st.session_state.lang] # Common x-axis
|
| 969 |
+
# ),
|
| 970 |
+
# yaxis=dict(
|
| 971 |
+
# title=df.loc['plot_label_price_duration_curve', st.session_state.lang], # Title for primary y-axis
|
| 972 |
+
# range=[-(100/(ax2_max/(ax2_max-ax2_min))-100), 100], # Primary y-axis range
|
| 973 |
+
# titlefont=dict(color='blue'), # Blue color for primary axis title
|
| 974 |
+
# tickfont=dict(color='blue') # Blue ticks for primary axis
|
| 975 |
+
# ),
|
| 976 |
+
# yaxis2=dict(
|
| 977 |
+
# title=df.loc['plot_label_residual_load', st.session_state.lang], # Title for secondary y-axis
|
| 978 |
+
# range=[ax2_min, ax2_max], # Secondary y-axis range
|
| 979 |
+
# titlefont=dict(color='red'), # Red color for secondary axis title
|
| 980 |
+
# tickfont=dict(color='red'), # Red ticks for secondary axis
|
| 981 |
+
# overlaying='y', # Overlay secondary axis on primary
|
| 982 |
+
# side='right' # Place secondary y-axis on the right side
|
| 983 |
+
# ),
|
| 984 |
fig_duration.update_layout(
|
| 985 |
+
title=df.loc['plot_label_price_duration_curve', st.session_state.lang],
|
| 986 |
+
xaxis=dict(
|
| 987 |
+
title=df.loc['label_hours', st.session_state.lang]
|
| 988 |
+
),
|
| 989 |
+
yaxis=dict(
|
| 990 |
+
title=dict(
|
| 991 |
+
text=df.loc['plot_label_price_duration_curve', st.session_state.lang],
|
| 992 |
+
font=dict(color='blue')
|
|
|
|
| 993 |
),
|
| 994 |
+
range=[-(100 / (ax2_max / (ax2_max - ax2_min)) - 100), 100],
|
| 995 |
+
tickfont=dict(color='blue')
|
| 996 |
+
),
|
| 997 |
+
yaxis2=dict(
|
| 998 |
+
title=dict(
|
| 999 |
+
text=df.loc['plot_label_residual_load', st.session_state.lang],
|
| 1000 |
+
font=dict(color='red')
|
| 1001 |
),
|
| 1002 |
+
range=[ax2_min, ax2_max],
|
| 1003 |
+
tickfont=dict(color='red'),
|
| 1004 |
+
overlaying='y',
|
| 1005 |
+
side='right'
|
| 1006 |
+
),
|
| 1007 |
legend=dict(
|
| 1008 |
x=1, # Positioniert die Legende am rechten Rand
|
| 1009 |
y=1, # Positioniert die Legende am oberen Rand
|