aaa.csv
-------------
>>>importpandasaspd>>>data=pd.read_csv("aaa.csv")>>>data#查看表格xyz012Y124Y238Y3416N4532N>>>data.columns#查看表格有哪些列,可以看到有x, y, z列Index([u'x',u'y',u'z'],dtype='object')>>>data['x']#查看x列0112233445Name:x,dtype:int64>>>data['y']#查看y列021428316432Name:y,dtype:int64>>>data['z']#查看z列0Y1Y2Y3N4NName:z,dtype:object>>>importmatplotlib.pyplotasplt>>>plt.bar(data['x'],data['y'])#画柱状图<Containerobjectof5artists>>>>plt.title('example')#设置标题>>>plt.xlabel('x')#横坐标加说明文字'x'<matplotlib.text.Textobjectat0x110e06110>>>>plt.ylabel('y')#纵坐标加说明文字'y'<matplotlib.text.Textobjectat0x10e80d890>>>>plt.show()#显示图形