在python中拟合负二项式

2023-11-21

在 scipy 中,不支持使用数据拟合负二项式分布 (可能是因为 scipy 中的负二项式只是离散的)。

对于正态分布我会这样做:

from scipy.stats import norm
param = norm.fit(samp)

其他库中是否有类似的“随时可用”功能?


Statsmodels有discrete.discrete_model.NegativeBinomial.fit(),请参见这里:https://www.statsmodels.org/dev/ generated/statsmodels.discrete.discrete_model.NegativeBinomial.fit.html#statsmodels.discrete.discrete_model.NegativeBinomial.fit

本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)

在python中拟合负二项式 的相关文章