使用numpy和matplotlib的numpy发现的直方图

Part 2 of Guide to statistics using Numpy series

使用Numpy系列进行统计指南的第2部分

介绍: (Introduction:)

When we first look at a dataset, we want to be able to quickly understand certain things about it:

当我们第一次查看数据集时,我们希望能够快速了解​​有关它的某些信息:

  • Do some values occur more often than others?

    某些价值观比其他价值观更经常出现吗?
  • What is the range of the dataset (i.e., the min and the max values)?

    数据集的范围是多少(即最小值和最大值)?
  • Are there a lot of outliers?

    有很多离群值吗?

We can visualize this information using a chart called a histogram.

我们可以使用称为直方图的图表来可视化此信息。

For instance, suppose that we have the following dataset:

例如,假设我们具有以下数据集:

d = [1, 1, 1, 2, 2, 2, 2, 2, 3, 3, 4, 4, 4, 4, 5]

d = [1,1,1,2,2,2,2,2,3,3,4,4,4,4,4,5]

A simple histogram might show us how many 1’s, 2’s, 3’s, etc. we have in this dataset.

一个简单的直方图可以显示我们在此数据集中有多少个1、2、3等。

When graphed, our histogram would look like this:

绘制图表时,我们的直方图如下所示:

Image for post

直方图vs条形图 (Histog

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值