Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -575,9 +575,13 @@ def server(input, output, session):
|
|
575 |
|
576 |
if df_combined_t.values[[10],[1]] < 0:
|
577 |
if df_combined_t.values[[10],[0]] < 0:
|
578 |
-
|
579 |
-
|
580 |
-
|
|
|
|
|
|
|
|
|
581 |
else:
|
582 |
norm = Normalize(vmin=0.8, vmax=1.2)
|
583 |
colour_df[[10],[0]] = tuple(colormap(norm(-df_combined_t.values[[10],[0]] / df_combined_t.values[[10],[1]])))
|
@@ -586,14 +590,16 @@ def server(input, output, session):
|
|
586 |
|
587 |
if df_combined_t.values[[10],[2]] < 0:
|
588 |
if df_combined_t.values[[10],[1]] < 0:
|
589 |
-
|
590 |
-
|
591 |
-
|
|
|
|
|
|
|
|
|
592 |
else:
|
593 |
norm = Normalize(vmin=0.8, vmax=1.2)
|
594 |
-
colour_df[[10],[
|
595 |
-
|
596 |
-
|
597 |
|
598 |
ax1 = plt.subplot(1,3,1)
|
599 |
ax2 = plt.subplot(3,3,2)
|
|
|
575 |
|
576 |
if df_combined_t.values[[10],[1]] < 0:
|
577 |
if df_combined_t.values[[10],[0]] < 0:
|
578 |
+
if df_combined_t.values[[10],[1]] < 0
|
579 |
+
cmap_flip = matplotlib.colors.LinearSegmentedColormap.from_list("", ["#FBBC04","white","#4285F4"])
|
580 |
+
norm = Normalize(vmin=-1.2, vmax=-0.8)
|
581 |
+
colour_df[[10],[0]] = tuple(cmap_flip(norm(df_combined_t.values[[10],[0]] / df_combined_t.values[[10],[1]])))
|
582 |
+
else:
|
583 |
+
norm = Normalize(vmin=0.8, vmax=1.2)
|
584 |
+
colour_df[[10],[0]] = tuple(colormap(norm(-df_combined_t.values[[10],[0]] / df_combined_t.values[[10],[1]])))
|
585 |
else:
|
586 |
norm = Normalize(vmin=0.8, vmax=1.2)
|
587 |
colour_df[[10],[0]] = tuple(colormap(norm(-df_combined_t.values[[10],[0]] / df_combined_t.values[[10],[1]])))
|
|
|
590 |
|
591 |
if df_combined_t.values[[10],[2]] < 0:
|
592 |
if df_combined_t.values[[10],[1]] < 0:
|
593 |
+
if df_combined_t.values[[10],[1]] < 0
|
594 |
+
cmap_flip = matplotlib.colors.LinearSegmentedColormap.from_list("", ["#FBBC04","white","#4285F4"])
|
595 |
+
norm = Normalize(vmin=-1.2, vmax=-0.8)
|
596 |
+
colour_df[[10],[0]] = tuple(cmap_flip(norm(df_combined_t.values[[10],[1]] / df_combined_t.values[[10],[2]])))
|
597 |
+
else:
|
598 |
+
norm = Normalize(vmin=0.8, vmax=1.2)
|
599 |
+
colour_df[[10],[0]] = tuple(colormap(norm(-df_combined_t.values[[10],[1]] / df_combined_t.values[[10],[2]])))
|
600 |
else:
|
601 |
norm = Normalize(vmin=0.8, vmax=1.2)
|
602 |
+
colour_df[[10],[0]] = tuple(colormap(norm(-df_combined_t.values[[10],[1]] / df_combined_t.values[[10],[2]])))
|
|
|
|
|
603 |
|
604 |
ax1 = plt.subplot(1,3,1)
|
605 |
ax2 = plt.subplot(3,3,2)
|