May give better results than 'RandomMap' on data where random sampling
is complicated.
This does not use actual kMeans clustering, but re-uses the batch version of
SOM() with tiny radius (which makes it work the same as kMeans). In
consequence, the speedup of SOM function is applied here as well. Additionally,
because we don't need that amount of clustering precision, parameters `batch=F, rlen=1'
may give a satisfactory result very quickly.
Usage
kMeansMap(data, k, coordsFn, batch = T, ...)
Value
map object (without the grid, if coordsFn was not specified)
Arguments
data
Input data matrix, with individual data points in rows
k
How many points to sample
coordsFn
a function to generate embedding coordinates (default none)
batch
Use batch-SOM training (effectively kMeans, default TRUE)
...
Passed to SOM(), useful e.g. for 'parallel=T' or 'rlen=5'