James McCool commited on
Commit
4b49951
·
1 Parent(s): fb18971

Add data load tab functions to app.py and adjust GOLF flex rank calculation in predict_dupes.py for accurate portfolio predictions.

Browse files
Files changed (2) hide show
  1. app.py +2 -0
  2. global_func/predict_dupes.py +2 -1
app.py CHANGED
@@ -1312,6 +1312,8 @@ except:
1312
  key='tab_selector'
1313
  )
1314
 
 
 
1315
  if selected_tab == 'Data Load':
1316
  col1, col2, col3 = st.columns(3)
1317
 
 
1312
  key='tab_selector'
1313
  )
1314
 
1315
+ # Data Load Tab Functions
1316
+ # Necessary starting page and UI
1317
  if selected_tab == 'Data Load':
1318
  col1, col2, col3 = st.columns(3)
1319
 
global_func/predict_dupes.py CHANGED
@@ -189,7 +189,8 @@ def predict_dupes(portfolio, maps_dict, site_var, type_var, Contest_Size, streng
189
 
190
  # Assign ranks back to individual columns using the same rank scale
191
  if sport_var == 'GOLF':
192
- flex_ranks = calculate_flex_ranks_efficient(portfolio, 1, 7, maps_dict)
 
193
 
194
  portfolio['FLEX1_Own_percent_rank'] = flex_ranks[0]
195
  portfolio['FLEX2_Own_percent_rank'] = flex_ranks[1]
 
189
 
190
  # Assign ranks back to individual columns using the same rank scale
191
  if sport_var == 'GOLF':
192
+ # GOLF Showdown has no CPT - all 6 positions are FLEX in columns 0-5
193
+ flex_ranks = calculate_flex_ranks_efficient(portfolio, 0, 6, maps_dict)
194
 
195
  portfolio['FLEX1_Own_percent_rank'] = flex_ranks[0]
196
  portfolio['FLEX2_Own_percent_rank'] = flex_ranks[1]