Multichem commited on
Commit
6dbe3a8
·
verified ·
1 Parent(s): 3cdcbfb

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -6
app.py CHANGED
@@ -209,12 +209,12 @@ with tab1:
209
  # i.e. clear values from both square and cube
210
  st.cache_data.clear()
211
  roo_table, lck_overall_stacks, lck_win_stacks, lck_loss_stacks, lcs_overall_stacks, lcs_win_stacks, lcs_loss_stacks, lec_overall_stacks, lec_win_stacks, lec_loss_stacks, lck_bo1, lck_bo3, lck_bo5, lcs_bo1, lcs_bo3, lcs_bo5, lec_bo1, lec_bo3, lec_bo5 = init_baselines()
212
- league_choice1 = st.radio("What table would you like to display?", ('LCK/LPL', 'LCS', 'LCK'), key='league_var1')
213
  if league_choice1 == 'LCK/LPL':
214
  league_hold = lck_overall_stacks
215
  elif league_choice1 == 'LCS':
216
  league_hold = lcs_overall_stacks
217
- elif league_choice1 == 'LCK':
218
  league_hold = lec_overall_stacks
219
  display = league_hold.set_index('Team')
220
  st.dataframe(display.style.background_gradient(axis=0).background_gradient(cmap='RdYlGn').format(precision=2), use_container_width = True)
@@ -231,13 +231,13 @@ with tab2:
231
  # i.e. clear values from both square and cube
232
  st.cache_data.clear()
233
  roo_table, lck_overall_stacks, lck_win_stacks, lck_loss_stacks, lcs_overall_stacks, lcs_win_stacks, lcs_loss_stacks, lec_overall_stacks, lec_win_stacks, lec_loss_stacks, lck_bo1, lck_bo3, lck_bo5, lcs_bo1, lcs_bo3, lcs_bo5, lec_bo1, lec_bo3, lec_bo5 = init_baselines()
234
- league_choice2 = st.radio("What table would you like to display?", ('LCK/LPL', 'LCS', 'LCK'), key='league_var2')
235
  if league_choice2 == 'LCK/LPL':
236
  league_hold = roo_table[roo_table['league'] == 'LCK']
237
  elif league_choice2 == 'LCS':
238
  league_hold = roo_table[roo_table['league'] == 'LCS']
239
- elif league_choice2 == 'LCK':
240
- league_hold = roo_table[roo_table['league'] == 'LCK']
241
  model_choice = st.radio("What table would you like to display?", ('Overall', 'Wins', 'Losses'), key='roo_table')
242
  if model_choice == 'Overall':
243
  hold_display = league_hold[league_hold['type'] == 'Overall']
@@ -268,7 +268,7 @@ with tab3:
268
  # i.e. clear values from both square and cube
269
  st.cache_data.clear()
270
  roo_table, lck_overall_stacks, lck_win_stacks, lck_loss_stacks, lcs_overall_stacks, lcs_win_stacks, lcs_loss_stacks, lec_overall_stacks, lec_win_stacks, lec_loss_stacks, lck_bo1, lck_bo3, lck_bo5, lcs_bo1, lcs_bo3, lcs_bo5, lec_bo1, lec_bo3, lec_bo5 = init_baselines()
271
- league_choice3 = st.radio("What table would you like to display?", ('LCK/LPL', 'LCS', 'LCK'), key='league_var3')
272
  gametype_choice = st.radio("What format are the games being played?", ('Best of 1', 'Best of 3', 'Best of 5'), key='player_stats')
273
  pos_var2 = st.selectbox('View specific position?', options = ['All', 'TOP', 'JNG', 'MID', 'ADC', 'SUP'], key = 'proj_posvar')
274
  team_var2 = st.multiselect('View specific team?', options = hold_display['Team'].unique(), key = 'proj_teamvar')
 
209
  # i.e. clear values from both square and cube
210
  st.cache_data.clear()
211
  roo_table, lck_overall_stacks, lck_win_stacks, lck_loss_stacks, lcs_overall_stacks, lcs_win_stacks, lcs_loss_stacks, lec_overall_stacks, lec_win_stacks, lec_loss_stacks, lck_bo1, lck_bo3, lck_bo5, lcs_bo1, lcs_bo3, lcs_bo5, lec_bo1, lec_bo3, lec_bo5 = init_baselines()
212
+ league_choice1 = st.radio("What table would you like to display?", ('LCK/LPL', 'LCS', 'LEC'), key='league_var1')
213
  if league_choice1 == 'LCK/LPL':
214
  league_hold = lck_overall_stacks
215
  elif league_choice1 == 'LCS':
216
  league_hold = lcs_overall_stacks
217
+ elif league_choice1 == 'LEC':
218
  league_hold = lec_overall_stacks
219
  display = league_hold.set_index('Team')
220
  st.dataframe(display.style.background_gradient(axis=0).background_gradient(cmap='RdYlGn').format(precision=2), use_container_width = True)
 
231
  # i.e. clear values from both square and cube
232
  st.cache_data.clear()
233
  roo_table, lck_overall_stacks, lck_win_stacks, lck_loss_stacks, lcs_overall_stacks, lcs_win_stacks, lcs_loss_stacks, lec_overall_stacks, lec_win_stacks, lec_loss_stacks, lck_bo1, lck_bo3, lck_bo5, lcs_bo1, lcs_bo3, lcs_bo5, lec_bo1, lec_bo3, lec_bo5 = init_baselines()
234
+ league_choice2 = st.radio("What table would you like to display?", ('LCK/LPL', 'LCS', 'LEC'), key='league_var2')
235
  if league_choice2 == 'LCK/LPL':
236
  league_hold = roo_table[roo_table['league'] == 'LCK']
237
  elif league_choice2 == 'LCS':
238
  league_hold = roo_table[roo_table['league'] == 'LCS']
239
+ elif league_choice2 == 'LEC':
240
+ league_hold = roo_table[roo_table['league'] == 'LEC']
241
  model_choice = st.radio("What table would you like to display?", ('Overall', 'Wins', 'Losses'), key='roo_table')
242
  if model_choice == 'Overall':
243
  hold_display = league_hold[league_hold['type'] == 'Overall']
 
268
  # i.e. clear values from both square and cube
269
  st.cache_data.clear()
270
  roo_table, lck_overall_stacks, lck_win_stacks, lck_loss_stacks, lcs_overall_stacks, lcs_win_stacks, lcs_loss_stacks, lec_overall_stacks, lec_win_stacks, lec_loss_stacks, lck_bo1, lck_bo3, lck_bo5, lcs_bo1, lcs_bo3, lcs_bo5, lec_bo1, lec_bo3, lec_bo5 = init_baselines()
271
+ league_choice3 = st.radio("What table would you like to display?", ('LCK/LPL', 'LCS', 'LEC'), key='league_var3')
272
  gametype_choice = st.radio("What format are the games being played?", ('Best of 1', 'Best of 3', 'Best of 5'), key='player_stats')
273
  pos_var2 = st.selectbox('View specific position?', options = ['All', 'TOP', 'JNG', 'MID', 'ADC', 'SUP'], key = 'proj_posvar')
274
  team_var2 = st.multiselect('View specific team?', options = hold_display['Team'].unique(), key = 'proj_teamvar')