def get_min(x):
    return x.loc[(x.date.idxmin()), :]

def get_max(x):
    return x.loc[(x.date.idxmax()), :]

def app_by_month(df, f):
    return df.groupby(df.date.dt.month).apply(f)
df2 = pd.concat([app_by_month(df, f) for f in [get_min, get_max]], axis=1,
    keys=['first', 'last']).sort_index(axis=1, level=1)
df2.columns = df2.columns.to_series().str.join('_').values
print(df2)
group data by date based on values using pandas