Agglomerative Hierarchical Clustering Learner
Source:R/LearnerClustHclust.R
mlr_learners_clust.hclust.Rd
A LearnerClust for agglomerative hierarchical clustering implemented in stats::hclust()
.
Difference Calculation is done by stats::dist()
Dictionary
This Learner can be instantiated via the dictionary mlr_learners or with the associated sugar function lrn()
:
$get("clust.hclust")
mlr_learnerslrn("clust.hclust")
Meta Information
Task type: “clust”
Predict Types: “partition”
Feature Types: “logical”, “integer”, “numeric”
Required Packages: mlr3, mlr3cluster, 'stats'
Parameters
Id | Type | Default | Levels | Range |
method | character | complete | ward.D, ward.D2, single, complete, average, mcquitty, median, centroid | - |
members | untyped | - | ||
distmethod | character | euclidean | euclidean, maximum, manhattan, canberra, binary, minkowski | - |
diag | logical | FALSE | TRUE, FALSE | - |
upper | logical | FALSE | TRUE, FALSE | - |
p | numeric | 2 | \((-\infty, \infty)\) | |
k | integer | 2 | \([1, \infty)\) |
Super classes
mlr3::Learner
-> mlr3cluster::LearnerClust
-> LearnerClustHclust
Examples
if (requireNamespace("stats")) {
learner = mlr3::lrn("clust.hclust")
print(learner)
# available parameters:
learner$param_set$ids()
}
#> <LearnerClustHclust:clust.hclust>: Agglomerative Hierarchical Clustering
#> * Model: -
#> * Parameters: k=2, distmethod=euclidean
#> * Packages: mlr3, mlr3cluster, stats
#> * Predict Types: [partition]
#> * Feature Types: logical, integer, numeric
#> * Properties: complete, exclusive, hierarchical
#> [1] "method" "members" "distmethod" "diag" "upper"
#> [6] "p" "k"