James McCool commited on
Commit
e27c5f8
·
1 Parent(s): 1c3dbe0

Filter out empty points in team matchup data to ensure accurate numeric conversion

Browse files
Files changed (1) hide show
  1. src/streamlit_app.py +1 -0
src/streamlit_app.py CHANGED
@@ -159,6 +159,7 @@ def init_macro_tables():
159
 
160
  team_matchup_json = requests.get(NBA_DATA + '?sheet=Team%20Matchups').json()
161
  team_matchup_frame = pd.DataFrame(team_matchup_json)
 
162
  team_matchup_frame = team_matchup_frame.reset_index(drop=True)
163
  team_matchup_frame = team_matchup_frame.apply(pd.to_numeric, errors='coerce').fillna(team_matchup_frame)
164
 
 
159
 
160
  team_matchup_json = requests.get(NBA_DATA + '?sheet=Team%20Matchups').json()
161
  team_matchup_frame = pd.DataFrame(team_matchup_json)
162
+ team_matchup_frame = team_matchup_frame[team_matchup_frame['t_Pts'] != ""]
163
  team_matchup_frame = team_matchup_frame.reset_index(drop=True)
164
  team_matchup_frame = team_matchup_frame.apply(pd.to_numeric, errors='coerce').fillna(team_matchup_frame)
165