Learn R Programming

specmine (version 1.0)

hierarchical_clustering: Perform hierarchical clustering analysis

Description

Perform hierarchical clustering analysis on the dataset.

Usage

hierarchical_clustering(dataset, distance = "euclidean", clustMethod = "complete", hc.type = "samples")

Arguments

dataset
list representing the dataset from a metabolomics experiment.
distance
the distance measure to be used to compute the distances between the rows of a data matrix. Possible types are "euclidean", "manhattan", "pearson" or "spearman".
clustMethod
the agglomeration method to be used. Possible values are "ward", "single", "complete", "average", "mcquitty", "median" or "centroid".
hc.type
a string indicating if hierarchical cluster analysis will be performed on samples ("samples") or on variables ("variables")

Value

An object of class hclust with the clustering results.

Examples

Run this code
  ## Example of hierarchical clustering
  data(cachexia)
  hc.result = hierarchical_clustering(cachexia, 
	      distance = "euclidean", clustMethod = "complete", 
	      hc.type = "samples")

Run the code above in your browser using DataLab