Spaces:
Running
Running
James McCool
commited on
Commit
·
3c53f01
1
Parent(s):
6f594e5
Update scoring percentage columns in app.py to include specific slate types for DraftKings and FanDuel, ensuring accurate data representation and enhancing user experience.
Browse files
app.py
CHANGED
@@ -88,7 +88,7 @@ def init_baselines():
|
|
88 |
team_frame = pd.DataFrame(cursor)
|
89 |
scoring_percentages = team_frame.drop(columns=['_id'])
|
90 |
scoring_percentages = scoring_percentages[['Names', 'Avg First Inning', 'First Inning Lead Percentage', 'Avg Fifth Inning', 'Fifth Inning Lead Percentage', 'Avg Score', '8+ runs', 'Win Percentage',
|
91 |
-
'Main Slate', 'Secondary Slate', 'Turbo Slate', 'Top Score']]
|
92 |
scoring_percentages['8+ runs'] = scoring_percentages['8+ runs'].replace('%', '', regex=True).astype(float)
|
93 |
scoring_percentages['Win Percentage'] = scoring_percentages['Win Percentage'].replace('%', '', regex=True).astype(float)
|
94 |
scoring_percentages['Top Score'] = scoring_percentages['Top Score'].replace('', np.nan).astype(float)
|
|
|
88 |
team_frame = pd.DataFrame(cursor)
|
89 |
scoring_percentages = team_frame.drop(columns=['_id'])
|
90 |
scoring_percentages = scoring_percentages[['Names', 'Avg First Inning', 'First Inning Lead Percentage', 'Avg Fifth Inning', 'Fifth Inning Lead Percentage', 'Avg Score', '8+ runs', 'Win Percentage',
|
91 |
+
'DK Main Slate', 'DK Secondary Slate', 'DK Turbo Slate', 'FD Main Slate', 'FD Secondary Slate', 'FD Turbo Slate', 'Top Score']]
|
92 |
scoring_percentages['8+ runs'] = scoring_percentages['8+ runs'].replace('%', '', regex=True).astype(float)
|
93 |
scoring_percentages['Win Percentage'] = scoring_percentages['Win Percentage'].replace('%', '', regex=True).astype(float)
|
94 |
scoring_percentages['Top Score'] = scoring_percentages['Top Score'].replace('', np.nan).astype(float)
|