Description Usage Arguments Details Value Author(s) See Also Examples
batchsom.default
is used to fit a Self-Organising Map to vector
data, using a batch algorithm.
1 2 3 4 5 6 7 8 | ## Default S3 method:
batchsom(data, somgrid, init=c("pca","random"),
prototypes,weights,
mode = c("continuous","stepwise"), min.radius, max.radius,
steps, decrease = c("power", "linear"), max.iter,
kernel = c("gaussian", "linear"), normalised,
assignment = c("single", "heskes"), cut = 1e-07,
verbose = FALSE, keepdata = TRUE, ...)
|
data |
the data to which the SOM will be fitted. This can be, a matrix or data frame of observations (which should be scaled) |
somgrid |
an object of class |
init |
the initialisation method (defaults to |
prototypes |
a matrix of initial values for the
prototypes (it must have the same number of columns as |
weights |
optional weights for the data points |
mode |
annealing mode:
|
min.radius |
the minimum neighbourhood influence radius. If
missing, the value depends on the one of |
max.radius |
the maximal neighbourhood influence radius. If missing two third of the prior structure diameter plus one |
steps |
the number of radii to use during annealing |
decrease |
the radii generating formula ( |
max.iter |
maximal number of epochs for one radius in the
|
kernel |
the kernel used to transform distances in the prior structure into influence coefficients |
normalised |
switch for normalising the neighbouring
interactions. Has no influence with the |
assignment |
the assignment method used to compute the best matching unit (BMU) of an observation during training:
|
cut |
minimal value below wich neighbouring interactions are not take into account |
verbose |
switch for tracing the fitting process |
keepdata |
if |
... |
additional arguments to be passed to the initialisation method |
This methods implements the standard batch algorithm for Self-Organising
Map. It applies to a matrix or a data frame of observations. It is
recommended to use the "single"
assignment method
which seems to perform better in general. If the initial value of
prototypes
is not provided, it is obtained by a call to
a function specified by the init
parameter. If its value is
"pca"
proprototypes are obtained by a call to
sominit.pca.default
(this is also the case when
init
is not specified), while
sominit.random.default
is called when init
is
"random"
. In both case, the additional parameters submitted to
the method are transmitted to the initialisation method.
An object of class "som"
, a list with components including
somgrid |
as in the arguments to |
prototypes |
a matrix containing the coordinates of the prototypes (also called the code book vectors) |
classif |
a vector of integer indicating to which unit each observation has been assigned |
errors |
a vector containing the evolution of the quantisation error during the fitting process |
control |
a list containing all the parameters used to fit the SOM |
data |
the original data if the function is called with
|
weights |
the weights of the data points if the function is called with
|
The object is also of class
"somnum"
.
Fabrice Rossi
See sominit.pca.default
and
sominit.random.default
for some control on the initial configuration of the prototypes som.tune
for the optimisation of some magic
parameters (such as the radii), umatrix
and
distance.grid
for visual analysis of the distances
between the prototypes.
1 2 3 4 5 6 7 8 9 10 11 12 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.