Python 入门练习--matplotlib.pyplot画图
5 (x,y) data point: [1,2], [3,4], [5,6],[7,8]. Use Matplotlib to plot out these data points.
1 import matplotlib.pyplot as plt 2 figure1 = plt.plot( [1,3,5,7], [2,4,6,8], 'ro') 3 plt.xlabel('x') 4 plt.ylabel('y')
Get help of plt.plot
1 help(plt.plot)