Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -212,7 +212,7 @@ with tab2:
|
|
| 212 |
del st.session_state[key]
|
| 213 |
display_portfolio = hold_portfolio
|
| 214 |
st.session_state.display_portfolio = display_portfolio
|
| 215 |
-
st.session_state.player_freq = pd.DataFrame(np.column_stack(np.unique(st.session_state.display_portfolio.iloc[:,0:
|
| 216 |
columns=['Player','Freq']).sort_values('Freq', ascending=False).reset_index(drop=True)
|
| 217 |
st.session_state.player_freq['Freq'] = st.session_state.player_freq['Freq'].astype(int)
|
| 218 |
with col2:
|
|
@@ -324,14 +324,8 @@ with tab2:
|
|
| 324 |
|
| 325 |
hold_container = st.empty()
|
| 326 |
with st.container():
|
| 327 |
-
proj_container = st.empty()
|
| 328 |
-
display_container = st.empty()
|
| 329 |
-
display_dl_container = st.empty()
|
| 330 |
-
freq_container = st.empty()
|
| 331 |
col1, col2 = st.columns([7, 2])
|
| 332 |
with col1:
|
| 333 |
-
with proj_container:
|
| 334 |
-
proj_container = st.empty()
|
| 335 |
if 'display_portfolio' in st.session_state:
|
| 336 |
st.dataframe(st.session_state.display_portfolio.style.background_gradient(axis=0).background_gradient(cmap='RdYlGn').format(precision=2), use_container_width = True)
|
| 337 |
|
|
@@ -340,8 +334,6 @@ with tab2:
|
|
| 340 |
# if 'final_Proj' in st.session_state:
|
| 341 |
# st.dataframe(st.session_state.final_Proj.style.background_gradient(axis=0).background_gradient(cmap='RdYlGn').format(precision=2), use_container_width = True)
|
| 342 |
with col2:
|
| 343 |
-
with freq_container:
|
| 344 |
-
freq_container = st.empty()
|
| 345 |
if 'player_freq' in st.session_state:
|
| 346 |
st.dataframe(st.session_state.player_freq.style.background_gradient(axis=0).background_gradient(cmap='RdYlGn').format(precision=2), use_container_width = True)
|
| 347 |
|
|
|
|
| 212 |
del st.session_state[key]
|
| 213 |
display_portfolio = hold_portfolio
|
| 214 |
st.session_state.display_portfolio = display_portfolio
|
| 215 |
+
st.session_state.player_freq = pd.DataFrame(np.column_stack(np.unique(st.session_state.display_portfolio.iloc[:,0:8].values, return_counts=True)),
|
| 216 |
columns=['Player','Freq']).sort_values('Freq', ascending=False).reset_index(drop=True)
|
| 217 |
st.session_state.player_freq['Freq'] = st.session_state.player_freq['Freq'].astype(int)
|
| 218 |
with col2:
|
|
|
|
| 324 |
|
| 325 |
hold_container = st.empty()
|
| 326 |
with st.container():
|
|
|
|
|
|
|
|
|
|
|
|
|
| 327 |
col1, col2 = st.columns([7, 2])
|
| 328 |
with col1:
|
|
|
|
|
|
|
| 329 |
if 'display_portfolio' in st.session_state:
|
| 330 |
st.dataframe(st.session_state.display_portfolio.style.background_gradient(axis=0).background_gradient(cmap='RdYlGn').format(precision=2), use_container_width = True)
|
| 331 |
|
|
|
|
| 334 |
# if 'final_Proj' in st.session_state:
|
| 335 |
# st.dataframe(st.session_state.final_Proj.style.background_gradient(axis=0).background_gradient(cmap='RdYlGn').format(precision=2), use_container_width = True)
|
| 336 |
with col2:
|
|
|
|
|
|
|
| 337 |
if 'player_freq' in st.session_state:
|
| 338 |
st.dataframe(st.session_state.player_freq.style.background_gradient(axis=0).background_gradient(cmap='RdYlGn').format(precision=2), use_container_width = True)
|
| 339 |
|