def get_info(df, group, info=['mean', 'std']):
    """
    Aggregate mean and std with the given group.
    """
    agg = df.groupby(group).agg(info)
    agg.columns = agg.columns.droplevel(0)
    return agg
def get_info ( df , group , info = [ 'mean' , 'std' ] ) : agg = df . groupby ( group ) . agg ( info ) agg . columns = agg . columns . droplevel ( 0 ) return agg
Aggregate mean and std with the given group.