Vinzent Steinberg
547149bfd2
Fix serde support
...
* Use correct Cargo flags.
* Fix tests.
* Fix histogram serialization.
2019-01-22 14:29:29 +01:00
Vinzent Steinberg
a7dde93df8
More idiomatic serde support
...
* Follow the suggestions from the Serde docs.
* Rename the feature from `serde` to `serde1`.
* Fix a doctest.
* Mention the feature in the README.
2018-07-11 12:54:37 +02:00
Vinzent Steinberg
34d33ef21a
Slightly improve calculation of standardized moment
...
Also test more of the trivial cases.
2018-07-11 12:37:06 +02:00
Vinzent Steinberg
663009f358
Make it possible to calculate an arbitrary number of moments
2018-07-10 17:19:57 +02:00
Vinzent Steinberg
e4345f5046
impl FromIterator<&f64> and FromIterator<&(f64, f64)>
...
This allows to write
let k: Kurtosis = a.iter().collect();
instead of
let k: Kurtosis = a.iter().map(|x| *x).collect();
but breaks type inference for code like
let m: Min = (1..6).map(Into::into).collect();
where
let m: Min = (1..6).map(f64::from).collect();
has to be used instead.
Fixes #8 .
2018-02-28 23:44:40 +01:00
Vinzent Steinberg
d539342bf1
Moments: Add serde test
2018-01-11 19:42:41 +01:00
Vinzent Steinberg
383c85c470
Improve test slightly
2018-01-11 19:25:25 +01:00
Vinzent Steinberg
9f2a8ee44f
Moments: Test merge
2018-01-11 19:16:11 +01:00
Vinzent Steinberg
c1fab4722c
Implement incremental calculation of arbitrary moments
2018-01-11 18:29:43 +01:00