mlr_learners_clust.kkmeans: Kernel K-Means Clustering Learner

mlr_learners_clust.kkmeansR Documentation

Kernel K-Means Clustering Learner

Description

A LearnerClust for kernel k-means clustering implemented in kernlab::kkmeans(). kernlab::kkmeans() doesn't have a default value for the number of clusters. Therefore, the centers parameter here is set to 2 by default. Kernel parameters have to be passed directly and not by using the kpar list in kkmeans. The predict method finds the nearest center in kernel distance to assign clusters for new data points.

Dictionary

This Learner can be instantiated via the dictionary mlr_learners or with the associated sugar function lrn():

mlr_learners$get("clust.kkmeans")
lrn("clust.kkmeans")

Meta Information

  • Task type: “clust”

  • Predict Types: “partition”

  • Feature Types: “logical”, “integer”, “numeric”

  • Required Packages: mlr3, mlr3cluster, kernlab

Parameters

Id Type Default Levels Range
centers untyped 2 -
kernel character rbfdot vanilladot, polydot, rbfdot, tanhdot, laplacedot, besseldot, anovadot, splinedot -
sigma numeric - [0, \infty)
degree integer 3 [1, \infty)
scale numeric 1 [0, \infty)
offset numeric 1 (-\infty, \infty)
order integer 1 (-\infty, \infty)
alg character kkmeans kkmeans, kerninghan -
p numeric 1 (-\infty, \infty)

Super classes

mlr3::Learner -> mlr3cluster::LearnerClust -> LearnerClustKKMeans

Methods

Public methods

Inherited methods

Method new()

Creates a new instance of this R6 class.

Usage
LearnerClustKKMeans$new()

Method clone()

The objects of this class are cloneable with this method.

Usage
LearnerClustKKMeans$clone(deep = FALSE)
Arguments
deep

Whether to make a deep clone.

Examples

if (requireNamespace("kernlab")) {
  learner = mlr3::lrn("clust.kkmeans")
  print(learner)

  # available parameters:
  learner$param_set$ids()
}

mlr3cluster documentation built on March 31, 2023, 11:11 p.m.