All notable changes to this project will be documented in this file.
min()/max()now returnOption<f64>instead off64. Use.unwrap()or.unwrap_or(f64::NAN)to recover old behavior.estimate_quantile()now returnsOption<f64>instead off64. Use.unwrap()or.unwrap_or(0.0)to recover old behavior.mean()now returnsOption<f64>instead off64. Use.unwrap()or.unwrap_or(0.0)to recover old behavior.new()now takesOption<f64>forminandmaxparameters. Wrap existing values inSome(...).Eqremoved fromTDigest. UsePartialEqonly.#[non_exhaustive]added toTDigestandCentroid. Use constructors orDefaultinstead of struct literals.- The
ordered-floatdependency has been removed. No action needed by consumers. - Serde wire format changed: The
minandmaxfields are nowOption<f64>(serialized asnullwhen empty) instead off64(which usedNaNas a sentinel). Data serialized with 0.2.x cannot be deserialized by 1.0.0 without manual migration.
- Fixed
merge_digestsk_limit off-by-one: the first centroid bucket was absorbing more weight than intended becausek_limitwas not incremented after the initialq_limit_times_countcomputation. - Fixed hardcoded
100innew()re-compression: when centroids exceededmax_size, the constructor ignored the caller-suppliedmax_size. - Fixed
merge_digestsempty-input losingmax_size: previously returnedTDigest::default()(max_size=100) instead of preserving the caller's max_size.
- Dropped
ordered-floatdependency; usesf64::total_cmp(stable since Rust 1.62). - Replaced custom
clampfunction withf64::clamp(). - Replaced
external_merge(~90 lines of custom merge sort) withcentroids.sort(). - Simplified
merge_unsortedto sort in-place without intermediate allocation. - Added
centroids()accessor to expose&[Centroid]. - Added
#[must_use]annotations to methods returning new values. - Added
debug_assertvalidation in constructors for NaN and missing min/max.
- Removed Travis CI configuration.
- Updated GitHub Actions CI: replaced deprecated
actions-rs/*withdtolnay/rust-toolchain, added MSRV check job. - Declared MSRV as Rust 1.62 via
rust-versioninCargo.toml. - Removed
Cargo.lockfrom version control (library convention).