【文件属性】:
文件名称:stats:统计分布和常用数学函数的表达水晶实现
文件大小:29KB
文件格式:ZIP
更新时间:2021-02-17 17:27:42
statistics statistical-distributions Crystal
迁移到
统计资料
统计分布的表达方式。 与水晶v0.27.0兼容。
安装
将此添加到应用程序的shard.yml :
dependencies :
stats :
git : https://git.sceptique.eu/Sceptique/stats
用法
包括它
require " stats "
include Stats
正态分布
NormaleDistribution .between # less_than, greater_than
standard_deviation: 15 ,
esperance: 100 ,
min: 85 ,
max: 115
# => 0.6826894921370859
二项分布
Math .binomial_distribution(
tries: 3 ,
probability: 0.5 ,
【文件预览】:
stats-master
----.gitignore(148B)
----README.md(3KB)
----shard.yml(100B)
----LICENSE(34KB)
----src()
--------stats()
--------stats.cr(55B)
--------lib()
----spec()
--------stats_spec.cr(133B)
--------binomial_distribution.cr(2KB)
--------math()
--------spec_helper.cr(38B)
--------normale_distribution.cr(2KB)
----.travis.yml(18B)