View source: R/cluster.carac.R
cluster.carac | R Documentation |
It makes the characterization of the classes or cluster considering the variables in tabla. These variables can be quantitative, qualitative or frequencies.
cluster.carac( tabla,class,tipo.v="d",v.lim= 2,dn=3,dm=3,neg=TRUE)
tabla |
object data.frame with variables of characterization, the variables must be of a single type (quantitative, qualitative or frequencies) |
class |
vector that determines the partition of the table |
tipo.v |
type of variables: quantitative("continuas"), qualitative ("nominales") or frequencies("frecuencia") |
v.lim |
test value to show the variable or category like characteristic. |
dn |
number of decimal digits for the p and test values. |
dm |
number of decimal digits for the means. |
neg |
if neg=TRUE, the variables or categories with negative test values are showed. |
For nominal or frecuency variables it compares the percentage of the categories within each class with the global percentage. For continuous variables it compares the average within each class with the general average. Categories and variables are ordered within each class by the test values and it shows only those that pass the threshold v.lim.
Object of class list. It has the characterization of each class or cluster.
Pedro Cesar del Campo pcdelcampon@unal.edu.co, Campo Elias Pardo cepardot@unal.edu.co, Mauricio Sadinle msadinleg@unal.edu.co
Lebart, L. and Morineau, A. and Piron, M. (1995) Statisitique exploratoire multidimensionnelle, Paris.
data(DogBreeds)
DB.act <- DogBreeds[-7] # active variables
DB.function <- subset(DogBreeds,select=7)
cluster.carac(DB.act,DB.function,"ca",2.0) # nominal variables
data(iris)
iris.act <- Fac.Num(iris)$numeric
class <- Fac.Num(iris)$factor
cluster.carac(iris.act,class,"co",2.0) # continuous variables
# frequency variables
data(DogBreeds)
attach(DogBreeds)
weig<-table(FUNC,WEIG)
weig<-data.frame(weig[,1],weig[,2],weig[,3])
cluster.carac(weig, row.names(weig), "fr", 2) # frequency variables
detach(DogBreeds)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.