Learn R Programming

FactoClass (version 0.7.7)

FactoClass: Combination of Factorial Methods and Cluster Analysis

Description

Performs the factorial analysis of the data and a cluster analysis using the nfcl first factorial coordinates

Usage

FactoClass( dfact, metodo, dfilu = NULL , nf = 2, nfcl = 10, k.clust = 3, 
            scanFC = TRUE , n.max = 5000 , n.clus = 1000 ,sign = 2.0,
            conso=TRUE , n.indi = 25 )

## S3 method for class 'FactoClass':
print(x, \dots)

analisis.clus(X,W)

Arguments

dfact
object of class data.frame, with the data of active variables.
metodo
function of ade4 for ade4 factorial analysis, dudi.pca,Principal Component Analysis; dudi.coa, Correspondence Analysis; witwit.coa, Internal Correspondence Analysis;
dfilu
ilustrative variables (default NULL)
nf
number of axes to use into the factorial analysis (default 2)
nfcl
number of axes to use in the classification (default 10)
k.clust
number of classes to work (default 3)
scanFC
if is TRUE, it asks in the console the values nf, nfcl y k.clust
n.max
when rowname(dfact)>=n.max, k-means is performed previous to hierarchical clustering (default 5000)
n.clus
when rowname(fact)>=n.max, the previous k-means is performed with n.clus groups (default 1000)
sign
threshold test value to show the characteristic variables and modalities
conso
when conso is TRUE, the process of consolidating the classification is performed (default TRUE)
n.indi
number of indices to draw in the histogram (default 25)
...
x
object of class FactoClass
X
coordinates of the elements of a class
W
weights of the elements of a class

Value

  • object of class FactoClass with the following:
  • dudiobject of class dudi from ade4 with the specifications of the factorial analysis
  • nfclnumber of axes selected for the classification
  • knumber of classes
  • indicestable of indices obtained through WARD method
  • cor.cluscoordinates of the clusters
  • clus.summsummary of the clusters
  • clustervector indicating the cluster of each element
  • carac.catecluster characterization by qualitative variables
  • carac.contcluster characterization by quantitative variables
  • carac.freccluster characterization by frequency active variables

Details

Lebart et al. (1995) present a strategy to analyze a data table using multivariate methods, consisting of an intial factorial analysis according to the nature of the compiled data, followed by the performance of mixed clustering. The mixed clustering combines hierarchic clustering using the Ward's method with K-means clustering. Finally a partition of the data set and the characterization of each one of the classes is obtained, according to the active and illustrative variables, being quantitative, qualitative or frequency. FactoClass is a function that connects procedures of the package ade4 to perform the analysis factorial of the data and from stats for the cluster analysis. The function analisis.clus calculates the geometric characteristics of each class: size, inertia, weight and square distance to the origin. For impression in LaTeX format see FactoClass.tex To draw factorial planes with cluster see plotFactoClass

References

Lebart, L. and Morineau, A. and Piron, M. (1995) Statisitique exploratoire multidimensionnelle, Paris.

Examples

Run this code
# Cluster analysis with Correspondence Analysis
data(ColorAdjective)
FC.col <-FactoClass(ColorAdjective, dudi.coa)
6
10
5

FC.col

FC.col$dudi


# Cluster analysis with Multiple Correspondence Analysis
data(BreedsDogs)

BD.act <- BreedsDogs[-7]  # active variables
BD.ilu <- BreedsDogs[7]   # ilustrative variables

FC.bd <-FactoClass( BD.act, dudi.acm, k.clust = 4,
                       scanFC = FALSE, dfilu = BD.ilu, nfcl = 10)

FC.bd

FC.bd$clus.summ
FC.bd$indices

Run the code above in your browser using DataLab