I am trying to use residplot on the tips data with hue as below:
tips = sns.load_dataset("tips")
sns.residplot(data=tips, x="total_bill", y="tip", scatter_kws={"hue":"sex"})
I have also tried:
sns.residplot(data=tips, x="total_bill", y="tip", scatter_kws=dict(hue="sex"))
But on both occasions the error message is the same
AttributeError: PathCollection.set() got an unexpected keyword argument 'hue'
I can always manually recreate the residuals with sns.scatterplot() and use hue there
sns.scatterplot(... ,hue="sex")
but was hoping to achieve it in one line.