matplotlib.axes.Axes.errorbar 误差bar图像
2017-09-08 08:43
393 查看
matplotlib.axes.Axes.errorbar
Axes.errorbar(x, y, yerr=None, xerr=None, fmt=”, ecolor=None, elinewidth=None, capsize=None, barsabove=False, lolims=False, uplims=False, xlolims=False, xuplims=False, errorevery=1, capthick=None, **kwargs)画一个误差的图像。
x, y, xerr, and yerr can all be scalars, which plots a single error bar at x, y.
import numpy as np import matplotlib.pyplot as plt x = np.linspace(0, 10, 20) y = np.sin(x) xerr = np.random.uniform(size=20)/3 yerr = np.random.normal(0, 2, size=20)/40 fig = plt.figure(figsize=(8, 8), dpi=100) axe = fig.add_subplot(1, 1, 1) axe.errorbar(x, y, yerr=yerr, xerr=xerr, marker='o', markerfacecolor='red', mec='green', markersize=10) axe.set_xlim(-2, 12) axe.set_ylim(-1.5, 1.5) plt.show()
详细的说明请看这里
相关文章推荐
- matplotlib利用scatter绘制彩色图像:NameError: name 'array' is not defined
- matplotlib命令与格式:图像(figure)与子区域(axes)布局与规划
- matplotlib命令与格式:图像(figure)与子区域(axes)布局与规划
- 图像显示—关于matplotlib.pyplot.imshow()函数
- %matplotlib inline syntax error
- matplotlib.pyplot.bar()条形图
- Python中matplotlib图像里的中文输出问题
- matplotlib figure图像-【老鱼学matplotlib】
- 用Matplotlib绘制二维图像
- matplotlib 的 subplot, axes and axis
- Numpy、matplotlib实现二维数据到图像的转换,添加colormap,无边距显示
- jupyter notebook import error: no module named 'matplotlib'
- 【matplotlib】绘制简单二维、三维图像
- Matplotlib 中文用户指南 3.2 图像教程
- ImportError: No module named matplotlib.pyplot
- vs2013在图像处理中的应用(3):用matplotlib进行绘图
- matplotlib入门之图像处理
- skimage读取图像——matplotlib显示图像
- Python使用matplotlib模块绘制图像并设置标题与坐标轴等信息示例
- 使用matplotlib时pyplot.show()不显示图像的问题