利用python进行数据分析——histogram


DataFrame.hist(datacolumn=Noneby=Nonegrid=Truexlabelsize=Nonexrot=Noneylabelsize=Noneyrot=None,ax=Nonesharex=Falsesharey=Falsefigsize=Nonelayout=Nonebins=10**kwds)


data : DataFrame

column : string or sequence 字符串或序列


by : object, optional

If passed, then used to form histograms(直方图) for separate groups

grid : boolean, default True 网格线,默认为使用


xlabelsize : int, default None

If specified changes the x-axis label size

xrot : float, default None

rotation of x axis labels 

ylabelsize : int, default None

If specified changes the y-axis label size

yrot : float, default None

rotation of y axis labels

ax : 轴对象,默认为空

sharex : boolean, default True if ax is None else False

In case subplots=True, share x axis and set some x axis labels to invisible; defaults to True if ax is None otherwise False if an ax is passed in; Be aware, that passing in both an ax and sharex=True will alter all x axis labels for all subplots in a figure!

sharey : boolean, default False

In case subplots=True, share y axis and set some y axis labels to invisible

figsize : tuple

The size of the figure to create in inches by default

layout : tuple, optional

Tuple of (rows, columns) for the layout of the histograms

bins : integer, default 10

直方图(柱状图)分箱数目,默认为10

kwds : other plotting keyword arguments

To be passed to hist function


文章来自:http://emily18.blog.51cto.com/7121141/1927657
© 2021 jiaocheng.bubufx.com  联系我们
ICP备案:鲁ICP备09046678号-3