, - , , . , , Axes3D.plot ( Axes.plot, ) , . , , . - Axes.plot, , . - , Axes3D, .
, Axes3D.scatter PathCollection (cast to PathCollection3D), . , ( 2d) ._offsets, ndarray, . .
plot, , . :
import numpy as np
import matplotlib.pyplot as plt
fig,ax = plt.subplots()
x = np.arange(3)
y = np.array([0.0,0.0,0.0])
pl, = ax.plot(x,y,'o-')
ax.set_ylim([0,4])
print(pl.get_xdata().base is x)
print(pl.get_ydata().base is y)
y[:] = [1,2,3]
fig.canvas.draw()
plt.show()
:

, print , , , plot, ( ) , .
:
import numpy as np
import matplotlib.pyplot as plt
from mpl_toolkits.mplot3d import Axes3D
fig = plt.figure()
ax = fig.add_subplot(111,projection='3d')
x = np.arange(3)
y = np.array([0.0,0.0,0.0])
z = np.array([0.0,0.0,0.0])
pl, = ax.plot(x,y,z,'o-')
ax.set_ylim([0,4])
ax.set_zlim([0,4])
y[:] = [1,2,3]
z[:] = [1,2,3]
fig.canvas.draw()
plt.show()
3D- ( ), :

, , 2- .
, ; Axes3D.plot outsources Axes.plot (, 2d ), . Axes.plot, , .
Axes3D.scatter Axes.scatter 2d-. , plot 2d 3d, : PathCollection(3D) .
, , , ( ) xs,ys,zs. , , , , . Axes3D.plot , , , ; Axes3D.scatter , , .
, 3d- ndarray:
import numpy as np
import matplotlib.pyplot as plt
from mpl_toolkits.mplot3d import Axes3D
fig = plt.figure()
ax = fig.add_subplot(111,projection='3d')
x = np.arange(3)
y = [0.0,0.0,0.0]
z = [0.0,0.0,0.0]
pl, = ax.plot(x,y,z,'o-')
ax.set_ylim([0,4])
ax.set_zlim([0,4])
y[:] = [1,2,3]
z[:] = [1,2,3]
fig.canvas.draw()
plt.show()
, ndarrays, , , , . :

-, y , z . ! :
print(pl._verts3d)
# (array([0, 1, 2]), array([ 0., 0., 0.]), [1, 2, 3])
print(pl._verts3d[2] is z)
# True
Axes3D.plot z , mplot3d.art3d.line_2d_to_3d, x y 2d z .
, Axes.plot y , y . , z , , , . y, z, z.
matplotlib 2d. , , 2d- , . , 3d- -, .
, , . , , pl.set_xdata(). , ( x/ydata ). , , . , , matplotlib . , . - , , , , , , , .