Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 5b00412

Browse files
thangleiterQuLogic
andauthored
Use more readable np.column_stack
Co-authored-by: Elliott Sales de Andrade <[email protected]>
1 parent d3c674c commit 5b00412

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

lib/mpl_toolkits/tests/test_mplot3d.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -513,7 +513,7 @@ def test_add_collection3d_zs_array():
513513
x = r * np.sin(theta)
514514
y = r * np.cos(theta)
515515

516-
points = np.array([x, y, z]).T.reshape(-1, 1, 3)
516+
points = np.column_stack([x, y, z]).reshape(-1, 1, 3)
517517
segments = np.concatenate([points[:-1], points[1:]], axis=1)
518518

519519
fig = plt.figure()
@@ -541,7 +541,7 @@ def test_add_collection3d_zs_scalar():
541541
x = r * np.sin(theta)
542542
y = r * np.cos(theta)
543543

544-
points = np.array([x, y]).T.reshape(-1, 1, 2)
544+
points = np.column_stack([x, y]).reshape(-1, 1, 2)
545545
segments = np.concatenate([points[:-1], points[1:]], axis=1)
546546

547547
fig = plt.figure()

0 commit comments

Comments
 (0)