James McCool
commited on
Commit
·
3eae767
1
Parent(s):
b5858b5
Sort working dataframe by 'actual_fpts' in app.py to enhance data presentation
Browse files- Added sorting functionality to the working dataframe based on 'actual_fpts' in descending order, improving the clarity of data displayed to users.
- This change aims to streamline data visualization and ensure users can easily identify top-performing entries.
app.py
CHANGED
|
@@ -314,6 +314,7 @@ with tab2:
|
|
| 314 |
lambda x: (x <= 10).sum()
|
| 315 |
)
|
| 316 |
|
|
|
|
| 317 |
working_df = working_df.reset_index()
|
| 318 |
working_df['percentile_finish'] = working_df['index'].rank(pct=True)
|
| 319 |
working_df['finish'] = working_df['index']
|
|
@@ -386,7 +387,8 @@ with tab2:
|
|
| 386 |
working_df['under_10'] = working_df.groupby('BaseName')['dupes'].transform(
|
| 387 |
lambda x: (x <= 10).sum()
|
| 388 |
)
|
| 389 |
-
|
|
|
|
| 390 |
working_df = working_df.reset_index()
|
| 391 |
working_df['percentile_finish'] = working_df['index'].rank(pct=True)
|
| 392 |
working_df['finish'] = working_df['index']
|
|
|
|
| 314 |
lambda x: (x <= 10).sum()
|
| 315 |
)
|
| 316 |
|
| 317 |
+
working_df = working_df.sort_values(by='actual_fpts', ascending=False)
|
| 318 |
working_df = working_df.reset_index()
|
| 319 |
working_df['percentile_finish'] = working_df['index'].rank(pct=True)
|
| 320 |
working_df['finish'] = working_df['index']
|
|
|
|
| 387 |
working_df['under_10'] = working_df.groupby('BaseName')['dupes'].transform(
|
| 388 |
lambda x: (x <= 10).sum()
|
| 389 |
)
|
| 390 |
+
|
| 391 |
+
working_df = working_df.sort_values(by='actual_fpts', ascending=False)
|
| 392 |
working_df = working_df.reset_index()
|
| 393 |
working_df['percentile_finish'] = working_df['index'].rank(pct=True)
|
| 394 |
working_df['finish'] = working_df['index']
|