projects
/
swc-testing-nose.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8e87750
)
Fixed bug in close_line.py
author
Anthony Scopatz
<scopatz@gmail.com>
Tue, 3 Apr 2012 17:19:43 +0000
(12:19 -0500)
committer
W. Trevor King
<wking@tremily.us>
Fri, 1 Nov 2013 03:23:55 +0000
(20:23 -0700)
W. Trevor King: I dropped everything from the original
c7a23ca
except
for the 5-Testing/ modification.
Conflicts:
.gitignore
6-Documentation/close_line.py
5-Testing/close_line.py
patch
|
blob
|
history
diff --git
a/5-Testing/close_line.py
b/5-Testing/close_line.py
index bed15db3727b668ae209e431f904a2eba5e7ffd4..a6a5c5ed9644fea74f1978e3dd387cbaaabf19e2 100644
(file)
--- a/
5-Testing/close_line.py
+++ b/
5-Testing/close_line.py
@@
-19,7
+19,7
@@
def closest_data_to_line1(data, p1, p2):
dists = np.empty(len(data), dtype=float)
for i, pdata in enumerate(data):
x = fmin(dist_from_line1, p1[0], (pdata, p1, p2), disp=False)[0]
- dists[i] = dist_from_line1(x, pdata)
+ dists[i] = dist_from_line1(x, pdata
, p1, p2
)
imin = np.argmin(dists)
return imin, data[imin]