关闭 Seaborn Bar Plot 中的误差线 [英] Turn off error bars in Seaborn Bar Plot

查看:137
本文介绍了关闭 Seaborn Bar Plot 中的误差线的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在matplotlib中使用GridSpec创建一个具有9个子图的页面.子图之一是使用以下代码创建的Seaborn条形图:

I'm using GridSpec in matplotlib to create a page that has 9 subplots. One of the subplots is a Seaborn bar plot created with the following code:

import seaborn as sns
sns.barplot(x=df['Time'], y=df['Volume_Count'], ax=ax7)

是否可以关闭条形图的垂直误差线?如果没有,是否可以减小钢筋的水平宽度?

Is there a way to turn off the vertical error bars of the bar plot? If not, is it possible to reduce the horizontal width of the bars?

谢谢!

推荐答案

您是否尝试过 ci 参数?根据文档:

Have you tried the ci argument? According to the documentation:

ci : 浮动或无,可选围绕估计值绘制的置信区间的大小.如果 None ,将不执行引导程序,并且会出现错误栏不会被绘制.

ci : float or None, optional Size of confidence intervals to draw around estimated values. If None, no bootstrapping will be performed, and error bars will not be drawn.

sns.barplot(x=df['Time'], y=df['Volume_Count'], ax=ax7, ci=None)

这篇关于关闭 Seaborn Bar Plot 中的误差线的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆