class_docstr: K-means clustering class.
  
  Added in 0.4.1dev
  
  Parameters
  ------------
  k : int
      Number of clusters
  max_iter : int (default: 10)
      Number of iterations during cluster assignment.
      Cluster re-assignment stops automatically when the algorithm
      converged.
  convergence_tolerance : float (default: 1e-05)
      Compares current centroids with centroids of the previous iteration
      using the given tolerance (a small positive float)to determine
      if the algorithm converged early.
  random_seed : int (default: None)
      Set random state for the initial centroid assignment.
  print_progress : int (default: 0)
      Prints progress in fitting to stderr.
      0: No output
      1: Iterations elapsed
      2: 1 plus time elapsed
      3: 2 plus estimated time until completion
  
  Attributes
  -----------
  centroids_ : 2d-array, shape={k, n_features}
      Feature values of the k cluster centroids.
  custers_ : dictionary
      The cluster assignments stored as a Python dictionary;
      the dictionary keys denote the cluster indeces and the items are
      Python lists of the sample indices that were assigned to each
      cluster.
  iterations_ : int
      Number of iterations until convergence.
  
  Examples
  -----------
  For usage examples, please see
  https://rasbt.github.io/mlxtend/user_guide/classifier/Kmeans/
code: def __init__(
      self,
      k,
      max_iter=10,
      convergence_tolerance=1e-05,
      random_seed=None,
      print_progress=0,
  ):
      _BaseModel.__init__(self)
      _Cluster.__init__(self)
      _IterativeModel.__init__(self)
      self.k = k
      self.max_iter = max_iter
      self.convergence_tolerance = convergence_tolerance
      self.random_seed = random_seed
      self.print_progress = print_progress
      self._is_fitted = False
  
file_path: mlxtend/mlxtend/cluster/kmeans.py
imports: import numpy
  from .._base import _BaseModel, _Cluster, _IterativeModel
label_desc: Use image node_id 1 to create a new Kmeans object from inherited base classes: _BaseModel, _Cluster, _IterativeModel with example: obj = Kmeans(k, max_iter, convergence_tolerance, random_seed, print_progress)