2019-03-27 16:12:09 +00:00
# Changelog
All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog ](http://keepachangelog.com/en/1.0.0/ )
and this project adheres to [Semantic Versioning ](https://semver.org/spec/v2.0.0.html ).
2024-07-08 20:16:19 +02:00
## Unreleased
2024-07-26 14:48:53 +07:00
- The `serde1` feature has been renamed `serde` (#1477 )
2024-10-03 21:18:56 +02:00
- Fix panic in Binomial (#1484 )
- Move some of the computations in Binomial from `sample` to `new` (#1484 )
2024-10-08 10:57:47 +02:00
- Add Kolmogorov Smirnov test for sampling of `Normal` and `Binomial` (#1494 )
2024-07-26 14:48:53 +07:00
2024-07-08 20:16:19 +02:00
### Added
- Add plots for `rand_distr` distributions to documentation (#1434 )
2024-07-16 09:04:49 +01:00
- Add `PertBuilder` , fix case where mode ≅ mean (#1452 )
2024-07-08 20:16:19 +02:00
2024-03-18 19:08:37 +00:00
## [0.5.0-alpha.1] - 2024-03-18
- Target `rand` version `0.9.0-alpha.1`
2024-02-18 17:02:05 +00:00
## [0.5.0-alpha.0] - 2024-02-18
This is a pre-release. To depend on this version, use `rand_distr = "=0.5.0-alpha.0"` to prevent automatic updates (which can be expected to include breaking changes).
### Additions
- Make distributions comparable with `PartialEq` (#1218 )
- Add `WeightedIndexTree` (#1372 )
### Changes
- Target `rand` version `0.9.0-alpha.0`
2021-09-15 19:12:24 +02:00
- Remove unused fields from `Gamma` , `NormalInverseGaussian` and `Zipf` distributions (#1184 )
This breaks serialization compatibility with older versions.
2023-03-18 05:21:59 -04:00
- `Dirichlet` now uses `const` generics, which means that its size is required at compile time (#1292 )
- The `Dirichlet::new_with_size` constructor was removed (#1292 )
2021-09-15 19:12:24 +02:00
2024-02-18 17:02:05 +00:00
### Fixes
- Fix Knuth's method so `Poisson` doesn't return -1.0 for small lambda (#1284 )
- Fix `Poisson` distribution instantiation so it return an error if lambda is infinite (#1291 )
- Fix Dirichlet sample for small alpha values to avoid NaN samples (#1209 )
- Fix infinite loop in `Binomial` distribution (#1325 )
2021-12-28 16:52:13 +03:00
## [0.4.3] - 2021-12-30
- Fix `no_std` build (#1208 )
2021-09-17 19:38:40 +02:00
## [0.4.2] - 2021-09-18
2021-06-16 01:52:16 +02:00
- New `Zeta` and `Zipf` distributions (#1136 )
2021-09-05 21:12:14 +02:00
- New `SkewNormal` distribution (#1149 )
2021-09-07 16:47:47 -05:00
- New `Gumbel` and `Frechet` distributions (#1168 , #1171 )
2021-06-14 01:25:17 +02:00
2021-06-14 10:04:59 +01:00
## [0.4.1] - 2021-06-15
- Empirically test PDF of normal distribution (#1121 )
2021-04-22 02:30:52 +02:00
- Correctly document `no_std` support (#1100 )
- Add `std_math` feature to prefer `std` over `libm` for floating point math (#1100 )
- Add mean and std_dev accessors to Normal (#1114 )
2021-05-13 18:38:24 -03:00
- Make sure all distributions and their error types implement `Error` , `Display` , `Clone` ,
`Copy` , `PartialEq` and `Eq` as appropriate (#1126 )
2021-06-14 10:04:59 +01:00
- Port benchmarks to use Criterion crate (#1116 )
2021-07-09 09:33:10 +01:00
- Support serde for distributions (#1141 )
2021-04-22 02:30:52 +02:00
2020-12-14 16:06:33 +00:00
## [0.4.0] - 2020-12-18
- Bump `rand` to v0.8.0
2020-10-28 00:06:52 +01:00
- New `Geometric` , `StandardGeometric` and `Hypergeometric` distributions (#1062 )
2020-09-07 17:54:19 +02:00
- New `Beta` sampling algorithm for improved performance and accuracy (#1000 )
2020-09-14 18:38:49 +01:00
- `Normal` and `LogNormal` now support `from_mean_cv` and `from_zscore` (#1044 )
- Variants of `NormalError` changed (#1044 )
2020-09-07 01:10:07 +02:00
2020-08-27 09:39:09 +02:00
## [0.3.0] - 2020-08-25
2020-08-01 19:43:16 +02:00
- Move alias method for `WeightedIndex` from `rand` (#945 )
2020-08-27 09:39:09 +02:00
- Rename `WeightedIndex` to `WeightedAliasIndex` (#1008 )
2020-08-01 19:43:16 +02:00
- Replace custom `Float` trait with `num-traits::Float` (#987 )
- Enable `no_std` support via `num-traits` math functions (#987 )
- Remove `Distribution<u64>` impl for `Poisson` (#987 )
- Tweak `Dirichlet` and `alias_method` to use boxed slice instead of `Vec` (#987 )
2020-08-27 09:39:09 +02:00
- Use whitelist for package contents, reducing size by 5kb (#983 )
2020-09-01 00:30:07 +02:00
- Add case `lambda = 0` in the parametrization of `Exp` (#972 )
2020-08-01 19:43:16 +02:00
- Implement inverse Gaussian distribution (#954 )
2020-08-27 09:39:09 +02:00
- Reformatting and use of `rustfmt::skip` (#926 )
2019-12-24 05:04:25 +08:00
- All error types now implement `std::error::Error` (#919 )
- Re-exported `rand::distributions::BernoulliError` (#919 )
2020-08-27 09:39:09 +02:00
- Add value stability tests for distributions (#891 )
2019-12-24 05:04:25 +08:00
2019-09-09 15:44:06 +02:00
## [0.2.2] - 2019-09-10
- Fix version requirement on rand lib (#847 )
- Clippy fixes & suppression (#840 )
2019-06-28 20:37:35 +01:00
## [0.2.1] - 2019-06-29
- Update dependency to support Rand 0.7
- Doc link fixes
2019-06-05 14:49:45 +02:00
## [0.2.0] - 2019-06-06
- Remove `new` constructors for zero-sized types
- Add Pert distribution
- Fix undefined behavior in `Poisson`
- Make all distributions return `Result` s instead of panicking
- Implement `f32` support for most distributions
- Rename `UnitSphereSurface` to `UnitSphere`
- Implement `UnitBall` and `UnitDisc`
## [0.1.0] - 2019-06-06
Initial release. This is equivalent to the code in `rand` 0.6.5.