James McCool commited on
Commit
0b4291c
·
1 Parent(s): 91ab4fb

Add 'Similarity Score' to data handling in app.py

Browse files

This update incorporates 'Similarity Score' into various sections of app.py, enhancing the data structure for trimming variables and ensuring consistent handling across the application. The changes improve the overall functionality and flexibility of the data processing related to player lineups.

Files changed (1) hide show
  1. app.py +5 -2
app.py CHANGED
@@ -952,6 +952,7 @@ with tab2:
952
  'Lineup Edge': st.session_state['working_frame']['Lineup Edge'],
953
  'Weighted Own': st.session_state['working_frame']['Weighted Own'],
954
  'Geomean': st.session_state['working_frame']['Geomean'],
 
955
  }
956
 
957
  if 'trimming_dict_maxes' not in st.session_state:
@@ -960,7 +961,8 @@ with tab2:
960
  'Geomean': st.session_state['working_frame']['Geomean'].max(),
961
  'Weighted Own': st.session_state['working_frame']['Weighted Own'].max(),
962
  'median': st.session_state['working_frame']['median'].max(),
963
- 'Finish_percentile': st.session_state['working_frame']['Finish_percentile'].max()
 
964
  }
965
 
966
  col1, col2 = st.columns([2, 8])
@@ -971,7 +973,8 @@ with tab2:
971
  'Geomean': 500.0,
972
  'Weighted Own': 500.0,
973
  'median': 500.0,
974
- 'Finish_percentile': 1.0
 
975
  }
976
  with st.expander('Macro Filter Options'):
977
  with st.form(key='macro_filter_form'):
 
952
  'Lineup Edge': st.session_state['working_frame']['Lineup Edge'],
953
  'Weighted Own': st.session_state['working_frame']['Weighted Own'],
954
  'Geomean': st.session_state['working_frame']['Geomean'],
955
+ 'Similarity Score': st.session_state['working_frame']['Similarity Score']
956
  }
957
 
958
  if 'trimming_dict_maxes' not in st.session_state:
 
961
  'Geomean': st.session_state['working_frame']['Geomean'].max(),
962
  'Weighted Own': st.session_state['working_frame']['Weighted Own'].max(),
963
  'median': st.session_state['working_frame']['median'].max(),
964
+ 'Finish_percentile': st.session_state['working_frame']['Finish_percentile'].max(),
965
+ 'Similarity Score': st.session_state['working_frame']['Similarity Score'].max()
966
  }
967
 
968
  col1, col2 = st.columns([2, 8])
 
973
  'Geomean': 500.0,
974
  'Weighted Own': 500.0,
975
  'median': 500.0,
976
+ 'Finish_percentile': 1.0,
977
+ 'Similarity Score': 1.0
978
  }
979
  with st.expander('Macro Filter Options'):
980
  with st.form(key='macro_filter_form'):