Struct plotters::prelude::Quartiles [−][src]
pub struct Quartiles { /* fields omitted */ }
Expand description
The quartiles
Implementations
impl Quartiles
[src]
impl Quartiles
[src]pub fn new<T: Into<f64> + Copy + PartialOrd>(s: &[T]) -> Self
[src]
pub fn new<T: Into<f64> + Copy + PartialOrd>(s: &[T]) -> Self
[src]Create a new quartiles struct with the values calculated from the argument.
s
: The array of the original values- returns The newly created quartiles
use plotters::prelude::*; let quartiles = Quartiles::new(&[7, 15, 36, 39, 40, 41]); assert_eq!(quartiles.median(), 37.5);
pub fn values(&self) -> [f32; 5]
[src]
pub fn values(&self) -> [f32; 5]
[src]Get the quartiles values.
- returns The array [lower fence, lower quartile, median, upper quartile, upper fence]
use plotters::prelude::*; let quartiles = Quartiles::new(&[7, 15, 36, 39, 40, 41]); let values = quartiles.values(); assert_eq!(values, [-9.0, 20.25, 37.5, 39.75, 69.0]);
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for Quartiles
impl Send for Quartiles
impl Sync for Quartiles
impl Unpin for Quartiles
impl UnwindSafe for Quartiles
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
pub fn borrow_mut(&mut self) -> &mut T
[src]Mutably borrows from an owned value. Read more
impl<T> SetParameter for T
impl<T> SetParameter for T
fn set<T>(&mut self, value: T) -> <T as Parameter<Self>>::Result where
T: Parameter<Self>,
fn set<T>(&mut self, value: T) -> <T as Parameter<Self>>::Result where
T: Parameter<Self>,
Sets value
as a parameter of self
.
impl<T> ToOwned for T where
T: Clone,
[src]
impl<T> ToOwned for T where
T: Clone,
[src]type Owned = T
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn to_owned(&self) -> T
[src]Creates owned data from borrowed data, usually by cloning. Read more
pub fn clone_into(&self, target: &mut T)
[src]
pub fn clone_into(&self, target: &mut T)
[src]🔬 This is a nightly-only experimental API. (toowned_clone_into
)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more