pub trait RankExt<A, S, D>where
S: Data<Elem = A>,{
// Required methods
fn rank(&self, method: RankMethod) -> Array<usize, D>;
fn discretize(&self, method: RankMethod, buckets: usize) -> Array<usize, D>;
}
Required Methods§
Sourcefn rank(&self, method: RankMethod) -> Array<usize, D>
fn rank(&self, method: RankMethod) -> Array<usize, D>
Returns an array of the same size as the original, where each value is replaced with a rank. Zero is reserved for elements whose rank cannot be computed (i.e. NaN values in floating point matrices). The lowest rank is one.
Sourcefn discretize(&self, method: RankMethod, buckets: usize) -> Array<usize, D>
fn discretize(&self, method: RankMethod, buckets: usize) -> Array<usize, D>
Returns an array of the same size of the original, where each value is replaced with a bucket identifier. Zero is reserved for elements whose bucket cannot be computed (i.e. NaN values in floating point matrices). The lowest bucket is one and the maximum bucket is the given number.