computes k-means from nb_iter subsets taken from dataPCA

get_kmeans(
  rast_sample,
  nb_iter,
  nb_clusters = 50,
  nbCPU = 1,
  algorithm = "Hartigan-Wong",
  progressbar = TRUE
)

Arguments

rast_sample

numeric. initial dataset sampled from PCA image

nb_iter

numeric. nb of iterations averaged to compute diversity indices

nb_clusters

numeric. number of clusters used in kmeans

nbCPU

numeric. Number of CPUs available

algorithm

character. algorithm used in the kmeans clustering

progressbar

boolean. set true for progress bar during clustering

Value

list of centroids and parameters needed to center/reduce data