From: gidden Date: Sun, 21 Apr 2013 20:03:25 +0000 (-0500) Subject: made the return signature of the 4th close line function the same as all the otehrs X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=3bd71319a159081e633389ea9d9b60bd019861a3;p=swc-testing-nose.git made the return signature of the 4th close line function the same as all the otehrs --- diff --git a/python/testing/close_line.py b/python/testing/close_line.py index a6a5c5e..f49cc9a 100644 --- a/python/testing/close_line.py +++ b/python/testing/close_line.py @@ -64,6 +64,7 @@ def closest_data_to_line3(data, p1, p2): # def closest_data_to_line4(data, p1, p2): - return data[np.argmin(np.sqrt(np.sum((p1 - data)**2, axis=1)) + \ - np.sqrt(np.sum((p2 - data)**2, axis=1)))] + imin = np.argmin(np.sqrt(np.sum((p1 - data)**2, axis=1)) + \ + np.sqrt(np.sum((p2 - data)**2, axis=1))) + return imin, data[imin]