Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -215,22 +215,29 @@ with tab2:
|
|
215 |
# i.e. clear values from both square and cube
|
216 |
st.cache_data.clear()
|
217 |
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()
|
218 |
-
|
219 |
-
|
220 |
-
|
221 |
-
|
222 |
-
|
223 |
-
|
224 |
-
|
225 |
-
|
226 |
-
|
227 |
-
|
228 |
-
|
229 |
-
|
230 |
-
|
231 |
-
|
232 |
-
|
233 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
234 |
display = hold_display.set_index('Player')
|
235 |
if team_var1:
|
236 |
display = display[display['Team'].isin(team_var1)]
|
|
|
215 |
# i.e. clear values from both square and cube
|
216 |
st.cache_data.clear()
|
217 |
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()
|
218 |
+
with st.container():
|
219 |
+
col1, col2, col3, col4 = st.columns([4, 2, 2, 2])
|
220 |
+
|
221 |
+
with col1:
|
222 |
+
league_choice2 = st.radio("What table would you like to display?", ('LCK/LPL', 'LCS', 'LEC'), key='league_var2')
|
223 |
+
if league_choice2 == 'LCK/LPL':
|
224 |
+
league_hold = roo_table[roo_table['league'] == 'LCK']
|
225 |
+
elif league_choice2 == 'LCS':
|
226 |
+
league_hold = roo_table[roo_table['league'] == 'LCS']
|
227 |
+
elif league_choice2 == 'LEC':
|
228 |
+
league_hold = roo_table[roo_table['league'] == 'LEC']
|
229 |
+
with col2:
|
230 |
+
model_choice = st.radio("What table would you like to display?", ('Overall', 'Wins', 'Losses'), key='roo_table')
|
231 |
+
if model_choice == 'Overall':
|
232 |
+
hold_display = league_hold[league_hold['type'] == 'Overall']
|
233 |
+
elif model_choice == 'Wins':
|
234 |
+
hold_display = league_hold[league_hold['type'] == 'Wins']
|
235 |
+
elif model_choice == 'Losses':
|
236 |
+
hold_display = league_hold[league_hold['type'] == 'Losses']
|
237 |
+
with col3:
|
238 |
+
pos_var1 = st.selectbox('View specific position?', options = ['All', 'TOP', 'JNG', 'MID', 'ADC', 'SUP'], key = 'roo_posvar')
|
239 |
+
with col4:
|
240 |
+
team_var1 = st.multiselect('View specific team?', options = hold_display['Team'].unique(), key = 'roo_teamvar')
|
241 |
display = hold_display.set_index('Player')
|
242 |
if team_var1:
|
243 |
display = display[display['Team'].isin(team_var1)]
|