natexcvi commited on
Commit
9567b04
1 Parent(s): df9b0ed

Fix formatting

Browse files
Files changed (1) hide show
  1. style.py +3 -4
style.py CHANGED
@@ -6,8 +6,7 @@ def recommendation_table_styler(styler):
6
  "proba_weak_down",
7
  "proba_strong_down",
8
  ]
9
- for col in proba_cols:
10
- styler = styler.background_gradient(subset=[col], cmap="viridis_r")
11
  styler = styler.format({col: "{:.2%}" for col in proba_cols})
12
  styler = styler.background_gradient(subset=["actual"], cmap="viridis")
13
  return styler
@@ -21,6 +20,6 @@ def portfolio_table_styler(styler):
21
  "weak down",
22
  "strong down",
23
  ]
24
- styler = styler.background_gradient(subset=proba_cols, cmap="viridis")
25
- styler = styler.format({col: "{:.2f}" for col in proba_cols})
26
  return styler
 
6
  "proba_weak_down",
7
  "proba_strong_down",
8
  ]
9
+ styler = styler.background_gradient(subset=proba_cols, cmap="viridis_r", axis=1)
 
10
  styler = styler.format({col: "{:.2%}" for col in proba_cols})
11
  styler = styler.background_gradient(subset=["actual"], cmap="viridis")
12
  return styler
 
20
  "weak down",
21
  "strong down",
22
  ]
23
+ styler = styler.background_gradient(subset=proba_cols, cmap="viridis", axis=1)
24
+ styler = styler.format({col: "{:.2%}" for col in proba_cols})
25
  return styler