clustering: Performs a clustering on PCA results

Description Usage Arguments Value Note Examples

Description

This function will perform a clustering from PCA results.

Usage

1
clustering(tab, tab2, results, nb.max.clusters = 10, size.min = 30)

Arguments

tab

A data.table object containing the data on which the PCA has been performed.

tab2

A data.table object containing variables you want to add after performing the clustering for the description in each group.

results

A list with the results of a PCA.

nb.max.clusters

A numeric indicating the maximum number of clusters you want to have. Default value is 10.

size.min

A numeric indicating how many individuals a cluster must contain at least. Default value is 30.

Value

A dataframe with original data and the clusters associated to each individual.

Note

Clusters with a size inferior to what is specified inside the argument size.min will be removed. Results will be added only after the clustering is done, as it is a non-supervised one.

Examples

1
2
3
## You want to get a maximum of 8 clusters with at least 20 individuals in each of them :

donnees <- clustering(res_pca,nb.max.clusters = 8, size.min = 20)

guillaumelf/BarchenPackage documentation built on May 31, 2019, 11:50 p.m.