kmeans.getk: Estimation of the number of clusters for _K_-means

Description Usage Arguments Value See Also Examples

Description

Estimate the optimal number of cluster of the K-means clustering method.

Usage

1
2
3
4
5
6
7
8
kmeans.getk(
  d,
  max = 9,
  criterion = "pseudo-F",
  graph = TRUE,
  nstart = 10,
  seed = NULL
)

Arguments

d

The dataset (matrix or data.frame).

max

The maximum number of clusters. Values from 2 to max are evaluated.

criterion

The criterion to be optimized. "pseudo-F" is the only criterion implemented in the current version.

graph

A logical indicating whether or not a graphic should be plotted.

nstart

The number of random sets chosen for kmeans initialization.

seed

A specified seed for random number generation.

Value

The optimal number of cluster of the K-means clustering method according to the chosen criterion.

See Also

pseudoF, kmeans

Examples

1
2
3
require (datasets)
data (iris)
kmeans.getk (iris [, -5])

Example output

Loading required package: arules
Loading required package: Matrix

Attaching package:arulesThe following objects are masked frompackage:base:

    abbreviate, write

Loading required package: mclust
Package 'mclust' version 5.4.7
Type 'citation("mclust")' for citing this R package in publications.
Loading required package: nnet
Loading required package: pls

Attaching package:plsThe following object is masked frompackage:stats:

    loadings

[1] 3

fdm2id documentation built on Oct. 29, 2021, 5:07 p.m.

Related to kmeans.getk in fdm2id...