zhoufcumt的个人博客分享 http://blog.sciencenet.cn/u/zhoufcumt

博文

Python:求分位数

已有 10065 次阅读 2019-6-24 17:45 |个人分类:Python|系统分类:科研笔记| Python, 分位数

       分位数(Quantile),亦称分位点,是指将一个随机变量概率分布范围分为几个等份的数值点,常用的有中位数(即二分位数)、四分位数百分位数等。


Python求不同的分位数(以GNSS定位东向误差为算例):

import numpy as np

abs_east = np.fabs(pos_east)  #pos_east为list类型

pos_east_95 = np.percentile(abs_east,95)

pos_east_68 = np.percentile(abs_east,68)

pos_east_50 = np.percentile(abs_east,50)  #即中位数



https://wap.sciencenet.cn/blog-350278-1186664.html

上一篇:2019年重新回归科研,继续更新博客,加油!
下一篇:Windows下GMT 6绘图学习--安装与入门
收藏 IP: 219.218.130.*| 热度|

0

该博文允许注册用户评论 请点击登录 评论 (0 个评论)

数据加载中...
扫一扫,分享此博文

Archiver|手机版|科学网 ( 京ICP备07017567号-12 )

GMT+8, 2024-5-21 19:27

Powered by ScienceNet.cn

Copyright © 2007- 中国科学报社

返回顶部