In groupingAndSorting.py, line 23 calls longSuspense = suspensions.groupby(['team']).games.agg([min, max]) which should gather data together by the team column and proceed to find the minimum and maximum number in the games column for each team.
Right now, however, the output shows some incorrect values for min and max. Also, some of the minimums are greater than the maximums for each team (e.g. for team ARI, it shows a minimum of 16 for games while showing a 4 for maximum for games).
We need to correctly output the data in this format:
[Team Name] [Minimum of the numbers in the game column for that team] [ Maximum of the numbers in the game column for that team].
Currently, the only correct part is that the rows for each team have been grouped together.
Any help is greatly appreciated!
Update:
I think it's an issue with the groupby object because when I run `suspensions.groupby("team").games.min(), it returns the same min values agg produces.
In groupingAndSorting.py, line 23 calls
longSuspense = suspensions.groupby(['team']).games.agg([min, max])which should gather data together by the team column and proceed to find the minimum and maximum number in the games column for each team.Right now, however, the output shows some incorrect values for min and max. Also, some of the minimums are greater than the maximums for each team (e.g. for team ARI, it shows a minimum of 16 for games while showing a 4 for maximum for games).
We need to correctly output the data in this format:
[Team Name] [Minimum of the numbers in the game column for that team] [ Maximum of the numbers in the game column for that team].
Currently, the only correct part is that the rows for each team have been grouped together.
Any help is greatly appreciated!
Update:
I think it's an issue with the groupby object because when I run `suspensions.groupby("team").games.min(), it returns the same min values agg produces.