clustering {Clustering} | R Documentation |
Clustering algorithm.
Description
Discovering the behavior of attributes in a set of clustering packages based on evaluation metrics.
Usage
clustering(
path = NULL,
df = NULL,
packages = NULL,
algorithm = NULL,
min = 3,
max = 4,
metrics = NULL
)
Arguments
path |
The path of file. |
df |
data matrix or data frame, or dissimilarity matrix. |
packages |
character vector with the packets running the algorithm.
|
algorithm |
character vector with the algorithms implemented within the
package. |
min |
An integer with the minimum number of clusters This data is
necessary to indicate the minimum number of clusters when grouping the data.
The default value is |
max |
An integer with the maximum number of clusters. This data is
necessary to indicate the maximum number of clusters when grouping the data.
The default value is |
metrics |
Character vector with the metrics implemented to evaluate the
distribution of the data in clusters. |
Details
The operation of this algorithm is to evaluate how the attributes of a dataset or a set of datasets behave in different clustering algorithms. To do this, it is necessary to indicate the type of evaluation you want to make on the distribution of the data. To be able to execute the algorithm it is necessary to indicate the number of clusters.
min
and max
, the algorithms algorithm
or packages.
packages
that we want to cluster and the metrics metrics
.
Value
A matrix with the result of running all the metrics of the algorithms contained in the packages indicated. We also obtain information with the types of metrics, algorithms and packages executed.
result It is a list with the algorithms, metrics and variables defined in the execution of the algorithm.
has_internal_metrics Boolean field to indicate if there are internal metrics such as: dunn, silhoutte and connectivity.
has_external_metrics Boolean field to indicate if there are external metrics such as: precision, recall, f-measure, entropy, variation information and fowlkes-mallows.
algorithms_execute Character vector with the algorithms executed. These algorithms have been mentioned in the definition of the parameters.
measures_execute Character vector with the measures executed. These measures have been mentioned in the definition of the parameters.
Examples
Clustering::clustering(
df = cluster::agriculture,
min = 3,
max = 3,
algorithm='clara',
metrics=c('Precision')
)