python(numpy,pandas12)——pandas plot 画图
生活随笔
收集整理的這篇文章主要介紹了
python(numpy,pandas12)——pandas plot 画图
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
文章目錄
- 前言
- plot.scatter
前言
根據 莫煩Python的教程 總結寫成,以便自己復習和使用,這里我就不喲林地掛原創了🐶。
data = pd.DataFrame(np.random.randn(1000,4),index = np.arange(1000),columns = ['A','B','C','D']) data = data.cumsum() print(data.head()) # 取出前五行數據plot.scatter
ax = data.plot.scatter(x='A',y='B',color= 'Blue',label = 'Class 1') ax = data.plot.scatter(x='A',y='D',color='Yellow',label='Class 2',ax = ax) data.plot.scatter(x='A',y='C',color= 'Green',label = 'Class 3',ax = ax)總結
以上是生活随笔為你收集整理的python(numpy,pandas12)——pandas plot 画图的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: python(numpy,pandas1
- 下一篇: python(matplotlib1)—