Struct ndarray_stats::histogram::strategies::Auto
source · pub struct Auto<T> { /* private fields */ }Expand description
Maximum of the Sturges and FreedmanDiaconis strategies.
Provides good all around performance.
A compromise to get a good value. For small datasets the Sturges value will usually be chosen,
while larger datasets will usually default to FreedmanDiaconis. Avoids the overly
conservative behaviour of FreedmanDiaconis and Sturges for
small and large datasets respectively.
Implementations
Trait Implementations
sourceimpl<T> BinsBuildingStrategy for Auto<T>where
T: Ord + Clone + FromPrimitive + NumOps + Zero,
impl<T> BinsBuildingStrategy for Auto<T>where
T: Ord + Clone + FromPrimitive + NumOps + Zero,
sourcefn from_array<S>(a: &ArrayBase<S, Ix1>) -> Selfwhere
S: Data<Elem = Self::Elem>,
fn from_array<S>(a: &ArrayBase<S, Ix1>) -> Selfwhere
S: Data<Elem = Self::Elem>,
Panics if IQR==0, the array is constant, or a.len()==0.
type Elem = T
sourcefn build(&self) -> Bins<T>
fn build(&self) -> Bins<T>
Returns a
Bins instance, built accordingly to the parameters
inferred from observations in from_array. Read moresourcefn n_bins(&self) -> usize
fn n_bins(&self) -> usize
Returns the optimal number of bins, according to the parameters
inferred from observations in
from_array. Read moreAuto Trait Implementations
impl<T> RefUnwindSafe for Auto<T>where
T: RefUnwindSafe,
impl<T> Send for Auto<T>where
T: Send,
impl<T> Sync for Auto<T>where
T: Sync,
impl<T> Unpin for Auto<T>where
T: Unpin,
impl<T> UnwindSafe for Auto<T>where
T: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more