Consider the following list of points (x,y):
list = {{1,1}, {2,2}, {3,3}, {2.1,2}, {2.001,2}, {1.001,1.001}, {1.1,1.001} };
How can it be efficiently reduced to:
newList = {{1,1}, {2,2}, {3,3}, {2.1,2}, {1.1,1.001}};
i.e, given a criterion (that can be either the metric distance or rounded number), how can I remove elements from the above list?
DeleteDuplicatesBy? – C. E. Feb 19 '18 at 18:40Union[list, SameTest -> (Norm@#1 - Norm@#2 < 10^-2 &)]– corey979 Feb 19 '18 at 18:44