James McCool
commited on
Commit
·
6ba45c0
1
Parent(s):
4af194e
Refactor salary processing in app.py: update salary conversion to drop NaN values before converting to integers, ensuring cleaner data handling and enhancing the robustness of projections.
Browse files
app.py
CHANGED
@@ -145,7 +145,7 @@ with tab1:
|
|
145 |
st.write('replaced salary symbols')
|
146 |
except:
|
147 |
pass
|
148 |
-
projections['salary'] = projections['salary'].astype(int)
|
149 |
projections = projections.apply(lambda x: x.replace(player_wrong_names_mlb, player_right_names_mlb))
|
150 |
st.dataframe(projections.head(10))
|
151 |
|
|
|
145 |
st.write('replaced salary symbols')
|
146 |
except:
|
147 |
pass
|
148 |
+
projections['salary'] = projections['salary'].dropna().astype(int)
|
149 |
projections = projections.apply(lambda x: x.replace(player_wrong_names_mlb, player_right_names_mlb))
|
150 |
st.dataframe(projections.head(10))
|
151 |
|