Struct stats::Unsorted [] [src]

pub struct Unsorted<T> { /* fields omitted */ }

A commutative data structure for lazily sorted sequences of data.

The sort does not occur until statistics need to be computed.

Note that this works on types that do not define a total ordering like f32 and f64. When an ordering is not defined, an arbitrary order is returned.

Methods

impl<T: PartialOrd> Unsorted<T>
[src]

[src]

Create initial empty state.

[src]

Add a new element to the set.

[src]

Return the number of data points.

impl<T: PartialOrd + Eq + Clone> Unsorted<T>
[src]

[src]

impl<T: PartialOrd + Clone> Unsorted<T>
[src]

[src]

Returns the mode of the data.

impl<T: PartialOrd + ToPrimitive> Unsorted<T>
[src]

[src]

Returns the median of the data.

Trait Implementations

impl<T: Clone> Clone for Unsorted<T>
[src]

[src]

Returns a copy of the value. Read more

1.0.0
[src]

Performs copy-assignment from source. Read more

impl<T: PartialOrd> Commute for Unsorted<T>
[src]

[src]

Merges the value other into self.

[src]

Merges the values in the iterator into self.

impl<T: PartialOrd> Default for Unsorted<T>
[src]

[src]

Returns the "default value" for a type. Read more

impl<T: PartialOrd> FromIterator<T> for Unsorted<T>
[src]

[src]

Creates a value from an iterator. Read more

impl<T: PartialOrd> Extend<T> for Unsorted<T>
[src]

[src]

Extends a collection with the contents of an iterator. Read more

Auto Trait Implementations

impl<T> Send for Unsorted<T> where
    T: Send

impl<T> Sync for Unsorted<T> where
    T: Sync