python matplotlib模块

-----------------------------------------------------------------------------
颜色:
c-青色  r-红色 m-品红 g-绿色 b-蓝色 y-黄色 k-黑色 w-白色
线条:
- 直线
--虚线
-.-.形式
:细小虚线

点的样式:
s 方形
h 六角形
H 六角形
* 星行
+ 加号
x  x型
d 菱形
D 菱形
p 五边形
^ 实体三角形
------------------------------------------------------------------------------------------------------
import matplotlib.pylab as pyl
import numpy as np
x=[1,2,3]
y=[3,4,5]
pyl.title("添加标题")
pyl.xlabel("x轴名称")
pyl.ylabel("y轴名称")
pyl.xlim(开始位置,终止位置)#设置x轴轴长
pyl.ylim(开始位置,终止位置)#设置y轴轴长
data1=np.random.random_integers(最小值,最大值,个数)
正态分布:
data2=npy.random.normal(均值,西格玛,个数)

 

猜你喜欢

转载自blog.csdn.net/qq_24726509/article/details/82981609