简体   繁体   English

Python和统计资料:适合混合发行吗?

[英]Python & Stats: fitting to mixed distribution?

Sometimes, the data is not from a single distribution, but from several distributions. 有时,数据不是来自单个分布,而是来自多个分布。

For example, y = 0.4*X + 0.6*Y , y has 40% chance of coming from distribution X , and 60% chance of coming from distribution Y . 例如, y = 0.4*X + 0.6*Yy有40%的概率来自分布X ,而60%的概率来自分布Y A intro could be find here: http://www.r-bloggers.com/a-brief-introduction-to-mixture-distributions/ . 可以在以下位置找到简介: http : //www.r-bloggers.com/a-brief-introduction-to-mixture-distributions/

The problem is, given the dataset, is there any good way to fit them in python ? 问题是,给定数据集,是否有什么好方法可以将它们适合python

I find a tutorial about R : http://www.r-bloggers.com/fitting-mixture-distributions-with-the-r-package-mixtools/ , but didn't find anything about python . 我找到了有关R的教程: http : //www.r-bloggers.com/fitting-mixture-distributions-with-the-r-package-mixtools/ ,但是没有找到有关python任何东西。

If your distributions are Gaussian, then scikit-learn has some good methods to fit to mixed distributions, so called Gaussian mixing models. 如果您的分布是高斯分布,那么scikit-learn有一些适合混合分布的好方法,即所谓的高斯混合模型。 There is a good explanation here . 这是一个很好的解释在这里 They also use expectation maximization, just like the R package mentioned in your link. 它们也使用期望最大化,就像您的链接中提到的R包一样。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM