Spaces:
Running
Running
James McCool
commited on
Commit
·
9aa41e4
1
Parent(s):
15c8c2c
Add subscription notice links for Player, Team, and ownership metrics in Simple and Advanced views to enhance user experience
Browse files
app.py
CHANGED
@@ -466,6 +466,8 @@ with tab2:
|
|
466 |
player_roo_disp = player_roo_disp.drop_duplicates(subset=['Player'])
|
467 |
|
468 |
if view_var == "Simple":
|
|
|
|
|
469 |
try:
|
470 |
player_roo_disp = player_roo_disp[['Player', 'Position', 'Team', 'Salary', 'Median', 'Ceiling', 'Own%']]
|
471 |
st.dataframe(player_roo_disp.style.background_gradient(axis=0).background_gradient(cmap='RdYlGn').format(player_roo_format, precision=2),
|
@@ -507,6 +509,8 @@ with tab2:
|
|
507 |
}, height=750, use_container_width = True, hide_index = True)
|
508 |
|
509 |
elif view_var == "Advanced":
|
|
|
|
|
510 |
try:
|
511 |
st.dataframe(player_roo_disp.style.background_gradient(axis=0).background_gradient(cmap='RdYlGn').format(player_roo_format, precision=2),
|
512 |
column_config={
|
|
|
466 |
player_roo_disp = player_roo_disp.drop_duplicates(subset=['Player'])
|
467 |
|
468 |
if view_var == "Simple":
|
469 |
+
for col in ['Player', 'Team', 'Own%']:
|
470 |
+
player_roo_disp[col] = 'https://paydirtdfs.com/subscriptions-choices/'
|
471 |
try:
|
472 |
player_roo_disp = player_roo_disp[['Player', 'Position', 'Team', 'Salary', 'Median', 'Ceiling', 'Own%']]
|
473 |
st.dataframe(player_roo_disp.style.background_gradient(axis=0).background_gradient(cmap='RdYlGn').format(player_roo_format, precision=2),
|
|
|
509 |
}, height=750, use_container_width = True, hide_index = True)
|
510 |
|
511 |
elif view_var == "Advanced":
|
512 |
+
for col in ['Player', 'Team', 'Own%', 'Small Field Own%', 'Large Field Own%', 'Cash Own%']:
|
513 |
+
player_roo_disp[col] = 'https://paydirtdfs.com/subscriptions-choices/'
|
514 |
try:
|
515 |
st.dataframe(player_roo_disp.style.background_gradient(axis=0).background_gradient(cmap='RdYlGn').format(player_roo_format, precision=2),
|
516 |
column_config={
|