Multimodal density estimation is a fundamental problem in scientific computing, but Python has lacked a cohesive implementation of critical bandwidth analysis and related mode-counting tools. We present critband, a Python package for Silverman-style critical bandwidth detection and multimodality assessment based on Gaussian kernel density estimation. The package provides a hybrid binary-Brent critical bandwidth solver, FFT-accelerated KDE for large samples, bootstrap confidence intervals with explicit failure accounting, support for arbitrary mode-count thresholds, component decomposition, bimodality strength scoring, and excess-mass estimation. We validate the implementation on twelve benchmark mixtures spanning well-separated, borderline, unequal-variance, unequal-weight, trimodal, and small-sample cases, and cross-check results against the R multimode package. Across the tested cases, critband reproduces critical bandwidth behavior closely and provides substantially faster runtime for the core search routine. The package is distributed on PyPI and is designed to integrate cleanly into the Python scientific computing stack.


翻译:多峰密度估计是科学计算中的基本问题,但Python此前缺乏临界带宽分析及相关模态计数工具的完整实现。本文提出critband——一个基于高斯核密度估计实现Silverman式临界带宽检测与多峰性评估的Python包。该包提供混合二分-Brent临界带宽求解器、面向大样本的FFT加速KDE、含显式失败计数的Bootstrap置信区间、任意模态计数阈值支持、成分分解、双峰强度评分及超额质量估计功能。我们在十二个基准混合分布上验证了实现效果,涵盖充分分离、边界情形、不等方差、不等权重、三峰及小样本案例,并与R语言multimode包进行交叉验证。在测试案例中,critband紧密复现了临界带宽行为,且核心搜索过程的运行时间显著缩短。该包已通过PyPI发布,旨在无缝集成至Python科学计算生态中。

0
下载
关闭预览

相关内容

专知会员服务
92+阅读 · 2021年4月12日
【干货书】Python数据科学分析,413页pdf
专知会员服务
93+阅读 · 2020年8月22日
【干货书】Python高级数据科学分析,424页pdf
专知会员服务
117+阅读 · 2020年8月7日
手把手教你用Python库Keras做预测(附代码)
数据派THU
14+阅读 · 2018年5月30日
荐书丨Python数据分析从入门到精通
程序人生
19+阅读 · 2018年3月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
3+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
3+阅读 · 2014年12月31日
国家自然科学基金
1+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
VIP会员
最新内容
学习数据的几何:形状空间分析数学综述
专知会员服务
3+阅读 · 6月17日
定向能反无人机系统最新发展动态
专知会员服务
6+阅读 · 6月17日
从燃煤战舰到算法战争:水面指挥的永恒要求
专知会员服务
3+阅读 · 6月17日
相关基金
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
3+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
3+阅读 · 2014年12月31日
国家自然科学基金
1+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
Top
微信扫码咨询专知VIP会员