I have the following dataframe df_male:
And I used groupby() to see mean value of gagne_sum_t column on each risk_percentile, df_male.groupby(["risk_percentile","race"]).aggregate(np.mean):
I want to scatterplot this gagne_sum_t vs risk_percentile grouped by race, for something like:

With this legend for the plot:

However, I am not too sure how to proceed from here... How do I use groupby() again from here?

