Skip to content

Commit

Permalink
feat: Add negative binomial distribution (#113)
Browse files Browse the repository at this point in the history
* distributions: add negative binomial distribution

* distributions::negative_binomial: rustfmt

* distributions::negative_binomial: minor doc fixes

* distributions::negative_binomial: choose more interesting CDF test values

* Address PR comments

* distributions::negative_binomial: floor x in CDF calculation which allows the test_discrete tests to pass

* distributions::negative_binomial: Minor cleanup
  • Loading branch information
danyx23 committed Jul 6, 2020
1 parent 72c767f commit 660eb9e
Show file tree
Hide file tree
Showing 3 changed files with 470 additions and 1 deletion.
2 changes: 2 additions & 0 deletions src/distribution/mod.rs
Expand Up @@ -16,6 +16,7 @@ pub use self::erlang::Erlang;
pub use self::exponential::Exponential;
pub use self::fisher_snedecor::FisherSnedecor;
pub use self::gamma::Gamma;
pub use self::negative_binomial::NegativeBinomial;
pub use self::geometric::Geometric;
pub use self::hypergeometric::Hypergeometric;
pub use self::inverse_gamma::InverseGamma;
Expand Down Expand Up @@ -53,6 +54,7 @@ mod log_normal;
mod multinomial;
mod multivariate_normal;
mod normal;
mod negative_binomial;
mod pareto;
mod poisson;
mod students_t;
Expand Down

0 comments on commit 660eb9e

Please sign in to comment.