I am plotting a dataframe, df containing x and y in a scatter plot. Clearly in many cases, for each x value, y-values may be scattered. I want to remove y-outliers for each x. This is different from bulk outlier removal using IQRs.
Can anyone assist with the same?
I was not able to find any ready-made code for this. Thre are codes that remove outliers in bulk, not selectively for each x.