Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

Aggregate on the entire DataFrame without group


def describe(df):
    funcs = dict(Kurt=lambda x: x.kurt(),
                 Skew='skew',
                 Mean='mean',
                 Std='std')
    funcs_for_all = {k: funcs for k in df.columns}
    return df.groupby(lambda _ : True).agg(funcs_for_all).iloc[0].unstack().T

describe(df)

Source by w3programmers.org #
 
PREVIOUS NEXT
Tagged: #Aggregate #entire #DataFrame #group
ADD COMMENT
Topic
Name
2+4 =