#[repr(i32)]pub enum PointMetrics<T: Fp> {
Manhattan = 1,
Euclidean = 2,
Chebyshev = 3,
Minkowski(T),
Canberra = 11,
Gower = 12,
}Variants§
Manhattan = 1
Manhattan distance, equivalent to Minkowski distance with p=1
Euclidean = 2
Euclidean distance, equivalent to Minkowski distance with p=2
Chebyshev = 3
Chebyshev distance, equivalent to Minkowski distance with p=Inf
Minkowski(T)
Minkowski distance where p=1, 2, …, Inf
Canberra = 11
Canberra distance, d=∑|Pi−Qi|/(|Pi|+|Qi|)
Gower = 12
Gower distance, d=∑|Pi−Qi|/n
Trait Implementations§
Source§impl<T: Clone + Fp> Clone for PointMetrics<T>
impl<T: Clone + Fp> Clone for PointMetrics<T>
Source§fn clone(&self) -> PointMetrics<T>
fn clone(&self) -> PointMetrics<T>
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl<T: Fp> StructuralPartialEq for PointMetrics<T>
Auto Trait Implementations§
impl<T> Freeze for PointMetrics<T>where
T: Freeze,
impl<T> RefUnwindSafe for PointMetrics<T>where
T: RefUnwindSafe,
impl<T> Send for PointMetrics<T>where
T: Send,
impl<T> Sync for PointMetrics<T>where
T: Sync,
impl<T> Unpin for PointMetrics<T>where
T: Unpin,
impl<T> UnwindSafe for PointMetrics<T>where
T: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more