Description Usage Arguments Value Examples
Perform k-means clustering analysis on the dataset.
1 | kmeans_clustering(dataset, num.clusters, type = "samples")
|
dataset |
list representing the dataset from a metabolomics experiment. |
num.clusters |
the number of clusters. |
type |
a string indicating if k-means will be performed on samples ("samples") or on variables ("variables") |
An object of class kmeans with the clustering results.
1 2 3 4 5 | ## Example of kmeans clustering
library(specmine.datasets)
data(cachexia)
kmeans.result = kmeans_clustering(cachexia,
num.clusters = 4, type = "samples")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.