NumPy.百分位数即使我已经升级到最新版本,也不能使用“插值”

2024-04-24 09:14:38 发布

您现在位置:Python中文网/ 问答频道 /正文

我们的项目在代码中使用它:

W_percentile[x, y] = np.percentile(np.array(l), 75, interpolation='lower')

但我不断地犯错误:

**TypeError: percentile() got an unexpected keyword argument 'interpolation'**

我看到一些答案说这是由于旧版本的numpy。但是我的numpy版本是1.10.1。有人知道我为什么会犯这个错误吗?谢谢!你知道吗


Tags: 项目代码numpyannpargumentarraylower