Finding 'edge cases' in a dataset
I think what you want is a variance plot. Create a dictionary for distinct x values. Put each distinct value of y in a list associated with each x. Find the stdev (np.std) of the list associated with each x say "s". Plot the s vs. x.
i apologize in advance for not being very precise, as a i dont know the mathematical expression for what i want. 
i am using matplotlib to analyze a large dataset. What i have now is a distribution of x,y points. I want to find out the cases in which the x values of my function are the same, but y differs the greatest. So if i plot it, one part of the cases is at the top of my graph, the other is the botton of the graph. 
So how do i get the points(x,y), (x,y') where f(x)=y and f(x)=y' and y-y'=max ?
cheers