Tra*_*nda 5 python plot matplotlib pandas
我想在熊猫中绘制一个散点图,它运行良好。但是在我添加图例后,它运行得非常慢并且卡住了。任何人都可以帮助我吗?
fcdp_data_100HZ[['Second','totCNTs']].plot.scatter(x="Second", y="totCNTs",color='royalblue',s=100,alpha=0.5, ax=axes[1])
axes[1].set_title("Counts")
axes[1].grid()
axes[1].set_ylim([1,100])
axes[1].set_yscale('log')
axes[1].set_ylabel("Counts")
axes[1].legend(['100HZ'])
fcdp_data_20HZ[['Second','totCNTs']].plot.scatter(x="Second", y="totCNTs",color='coral', s=100,alpha=0.5, ax=axes[1])
axes[1].set_title("Counts")
axes[1].grid()
axes[1].set_ylim([1,100])
axes[1].set_yscale('log')
axes[1].set_ylabel("Counts")
axes[1].legend(['20HZ'])
fcdp_data_1HZ[['Second','totCNTs']].plot.scatter(x="Second", y="totCNTs",color='darkslategrey',s=100,alpha=0.5, ax=axes[1])
axes[1].set_title("Counts")
axes[1].grid()
axes[1].set_ylim([1,100])
axes[1].set_yscale('log')
axes[1].set_ylabel("Counts")
axes[1].legend(['1HZ'])
plt.show()
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
64 次 |
| 最近记录: |