高斯分布和二项式分布
daigle-dist的Python项目详细描述
分布分析仪
这个软件包允许用户对高斯分布和二项分布的基本元素进行一些简单的分析。
这个包主要是作为将包加载到PyPi的测试用例/POC,但也可能对其他人有用。
要使用此软件包:
pip install daigle-dist
- 运行Python
- 输入
from distributions import Gaussian, Binomial
3a.Gaussian(mean, stdev)
3b.Binomial(mean,stdev)
- 属性包括:
read_data_file()
: assigns the distribution object some data from a .txt filemean
: returns the distribution object's meanstdev
: returns the distribution object's standard deviationcalculate_mean()
: assigns and returns a distribution object's meancalculate_stdev()
: assigns and returns a distribution object's standard deviationreplace_stats_with_data()
: update attributes of p and n of binomial distribution objectplot_bar
: bar chart plot of the outcomes and frequencies of a distribution objectpdf()
: calculates the probability density function for a distribution objectplot_bar_pdf
: bar chart plot of the probability density function of a distribution object
- 神奇的方法包括:
__add__
: allows two distribution objects to be added to each other as well as calculate the mean and standard deviation of each other__repr__
: outputs the characteristics of a distribution object
- 项目
标签: