9
嗨有没有人知道是否有一种方式来保存matplotlib 3D旋转图的格式,让他们仍然可以旋转?也许一个特定的程序?保存matplotlib 3D旋转图
代码是:
from numpy import *
import pylab as p
import mpl_toolkits.mplot3d.axes3d as p3
A=transpose(genfromtxt("Z:/Desktop/Project/bhmqntm-code/RichardsonRK4.csv", unpack=True, delimiter=','))
T=A[:,0]
X=A[:,1]
P=A[:,2]
fig=p.figure()
ax = p3.Axes3D(fig)
ax.scatter(X,P,T,s=1,cmap=cm.jet)
ax.set_xlabel('X')
ax.set_ylabel('P')
ax.set_zlabel('T')
p.show()#I would like this to be something like savefig('Z:/Desktop/Project/bhmqntm-code/plot3d_ex.png') but with a file ending of a program that would save the 3d capability
我不知道,如果一个程序,做到这一点确实存在,但如果一个人都知道这将是非常有益的。谢谢。
也许腌制,然后你可以重新打开另一个Python会话。 – tacaswell
嗨,我得到了阴谋腌菜并最终重新加载,但重新加载的地块没有旋转。 :(有没有人有过这样的成功,或者我正在做些什么工作? – user2023134
对不起,在进一步考虑(和任何测试)这现在似乎是一个坏主意(我甚至无法让'figure'对象腌制)。 – tacaswell