pub struct HierarchicalCluster<T: Float>(/* private fields */);
Expand description
Agglomerative hierarchical clustering
In this clustering algorithm, each point is first considered as a separate cluster. During each step, two points are merged into new clusters, until a stopping criterion is reached. The distance between the points is computed as the negative-log transform of the similarity kernel.
Implementations§
Source§impl<F: Float> HierarchicalCluster<F>
impl<F: Float> HierarchicalCluster<F>
Sourcepub fn with_method(self, method: Method) -> HierarchicalCluster<F>
pub fn with_method(self, method: Method) -> HierarchicalCluster<F>
Select a merging method
Sourcepub fn num_clusters(self, num_clusters: usize) -> HierarchicalCluster<F>
pub fn num_clusters(self, num_clusters: usize) -> HierarchicalCluster<F>
Stop merging when a certain number of clusters are reached
In the fitting process points are merged until a certain criterion is reached. With this option the merging process will stop, when the number of clusters drops below this value.
Sourcepub fn max_distance(self, max_distance: F) -> HierarchicalCluster<F>
pub fn max_distance(self, max_distance: F) -> HierarchicalCluster<F>
Stop merging when a certain distance is reached
In the fitting process points are merged until a certain criterion is reached. With this option the merging process will stop, then the distance exceeds this value.
Trait Implementations§
Source§impl<T: Clone + Float> Clone for HierarchicalCluster<T>
impl<T: Clone + Float> Clone for HierarchicalCluster<T>
Source§fn clone(&self) -> HierarchicalCluster<T>
fn clone(&self) -> HierarchicalCluster<T>
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl<T: Default + Float> Default for HierarchicalCluster<T>
impl<T: Default + Float> Default for HierarchicalCluster<T>
Source§fn default() -> HierarchicalCluster<T>
fn default() -> HierarchicalCluster<T>
Source§impl<F: Float> ParamGuard for HierarchicalCluster<F>
impl<F: Float> ParamGuard for HierarchicalCluster<F>
Source§type Checked = ValidHierarchicalCluster<F>
type Checked = ValidHierarchicalCluster<F>
Source§type Error = HierarchicalError<F>
type Error = HierarchicalError<F>
Source§fn check_ref(&self) -> Result<&Self::Checked, Self::Error>
fn check_ref(&self) -> Result<&Self::Checked, Self::Error>
Source§fn check(self) -> Result<Self::Checked, Self::Error>
fn check(self) -> Result<Self::Checked, Self::Error>
Source§fn check_unwrap(self) -> Self::Checkedwhere
Self: Sized,
fn check_unwrap(self) -> Self::Checkedwhere
Self: Sized,
check()
and unwraps the resultimpl<T: Float> StructuralPartialEq for HierarchicalCluster<T>
impl<F: Float> TransformGuard for HierarchicalCluster<F>
Auto Trait Implementations§
impl<T> Freeze for HierarchicalCluster<T>where
T: Freeze,
impl<T> RefUnwindSafe for HierarchicalCluster<T>where
T: RefUnwindSafe,
impl<T> Send for HierarchicalCluster<T>
impl<T> Sync for HierarchicalCluster<T>
impl<T> Unpin for HierarchicalCluster<T>
impl<T> UnwindSafe for HierarchicalCluster<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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more