cluster {GCDkit}R Documentation

Statistics: Hierarchical clustering

Description

Hierarchical cluster analysis on a set of dissimilarities.

Usage

cluster(x=NULL,elems="SiO2,TiO2,Al2O3,FeOt,MnO,MgO,CaO,Na2O,K2O",label.by=1,method="average")

Arguments

x

numerical matrix with compositional data.

elems

numerical columns to be used for cluster analysis, typically major elements.

method

the agglomeration method to be employed. This should be one of (or an unambiguous abbreviation thereof): 'ward.D', 'single', 'complete',

'average', 'mcquitty', 'median', 'centroid'.

label.by

numeric; names for each of the cases (samples).

Details

Even though a list of major elements is assumed as a default, different variables can be specified. In GUI, this is done by the function 'selectColumnsLabels'. Moreover, samples can be selected based on combination of three searching mechanisms (by sample name/label, range or a Boolean condition) - see selectSamples for details.

The user can also specify a label for the individual samples, default are their names (label.by = 1). For label.by) > 1, the number indicates a sequence number of the column in the labels + 1.

In GUI, the individual clusters can be identified after the dendrogram is drawn. For each sample falling into the given group, specified information (e.g. Locality, Rock Type and/or Author) can be printed.

For further details on the clustering algorithm, see the R manual entry of 'hclust'.

Value

None.

Warning

Names of existing numeric data columns and not formulae involving these can be handled at this stage. As only complete cases are used for the cluster analysis, missing values are replaced by 0.

Author(s)

Vojtěch Janoušek, vojtech.janousek@geology.cz

See Also

'hclust'

Examples

    data(sazava)
    accessVar("sazava")

    cluster(WR,elems = LILE,method = "ward")

    cluster(WR,elems = LILE,method = "ward.D",label.by=2) 

[Package GCDkit version 6.1 Index]