Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents da88f66 + 7fd3b7b commit cbebc61Copy full SHA for cbebc61
1 file changed
lib/matplotlib/lines.py
@@ -1505,8 +1505,8 @@ def get_transform(self):
1505
points_transform.transform([self._xy1, self._xy2])
1506
dx = x2 - x1
1507
dy = y2 - y1
1508
- if np.allclose(x1, x2):
1509
- if np.allclose(y1, y2):
+ if dx == 0:
+ if dy == 0:
1510
raise ValueError(
1511
f"Cannot draw a line through two identical points "
1512
f"(x={(x1, x2)}, y={(y1, y2)})")
0 commit comments