Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

get maximum values in a column by a subgroup of a dataframe pandas

df.sort_values('count', ascending=False).drop_duplicates(['Sp','Mt'])
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #maximum #values #column #subgroup #dataframe #pandas
ADD COMMENT
Topic
Name
1+2 =