我喜欢在用matplotlib绘制图形之后用y轴切换x轴?任何简单的方法呢?提前致谢。如何在matplotlib中切换轴?
12
A
回答
-2
您可以简单地切换x和y参数的绘图功能:
I[3]: x = np.linspace(0,2*np.pi, 100)
I[4]: y = np.sin(x)
I[5]: plt.plot(x,y)
I[6]: plt.figure(); plt.plot(y,x)
+4
谢谢,但它不是我正在寻找的答案。我绘制完所有数据后,如何切换x和y轴。 – 2010-03-03 04:47:53
+0
@DaehyokShin,你找到了正确的方法吗? – has 2017-04-25 12:39:10
相关问题
- 1. 如何在matplotlib/Python中切换后端
- 2. 如何在matplotlib/python中缩小y轴?
- 3. 如何在matplotlib中设置偏置轴?
- 4. 在matplotlib中,如何绘制从轴向外的R型轴蜱?
- 5. 如何在Selenium中切换和切换
- 6. 如何禁用matplotlib中轴标签的自动交换?
- 7. 如何更改3D轴设置在matplotlib
- 8. 如何更改matplotlib中的x轴
- 9. 如何操作matplotlib中的y轴?
- 10. 如何绘制matplotlib中的多个X轴或Y轴?
- 11. Matplotlib boxplot x轴
- 12. Matplotlib x轴
- 13. Matplotlib轴标签
- 14. 偏轴matplotlib`ticklabels`从轴
- 15. Matplotlib指示点在X轴和Y轴
- 16. 更改X轴在matplotlib
- 17. 虚线,以轴在matplotlib
- 18. 移动Y轴在matplotlib
- 19. 制作方轴在matplotlib
- 20. matplotlib中的轴重叠行
- 21. 如何删除matplotlib相对位移轴
- 22. 如何设置matplotlib x轴的起点?
- 23. 如何设置轴从角落Matplotlib
- 24. 如何更改matplotlib图的轴值?
- 25. Matplotlib/pyplot:如何执行轴范围?
- 26. python matplotlib如何获得多个轴柄
- 27. matplotlib,如何压缩x轴的部分
- 28. 如何从现有的轴与Matplotlib
- 29. 如何获取X轴和Y轴在matplotlib中看起来像这样
- 30. 如何在时间轴上正确放置seaborn/matplotlib中的x轴?
http://stackoverflow.com/questions/15767781/python-matplotlib-way-to-transpose-axes/15859177#15859177本帖子的更新的副本 – tacaswell 2013-04-07 05:26:27