catatis {ClustBlock} | R Documentation |
Perform the CATATIS method on different blocks from a CATA experiment
Description
CATATIS method. Additional outputs are also computed. Non-binary data are accepted and weights can be tested.
Usage
catatis(Data,nblo,NameBlocks=NULL, NameVar=NULL, Graph=TRUE, Graph_weights=TRUE,
Test_weights=FALSE, nperm=100)
Arguments
Data |
data frame or matrix where the blocks of binary variables are merged horizontally. If you have a different format, see |
nblo |
integer. Number of blocks (subjects). |
NameBlocks |
string vector. Name of each block (subject). Length must be equal to the number of blocks. If NULL, the names are S1,...Sm. Default: NULL |
NameVar |
string vector. Name of each variable (attribute, the same names for each subject). Length must be equal to the number of attributes. If NULL, the colnames of the first block are taken. Default: NULL |
Graph |
logical. Show the graphical representation? Default: TRUE |
Graph_weights |
logical. Should the barplot of the weights be plotted? Default: TRUE |
Test_weights |
logical. Should the the weights be tested? Default: FALSE |
nperm |
integer. Number of permutation for the weight tests. Default: 100 |
Value
a list with:
S: the S matrix: a matrix with the similarity coefficient among the subjects
compromise: a matrix which is the compromise of the subjects (akin to a weighted average)
weights: the weights associated with the subjects to build the compromise
weights_tests: the weights tests results
lambda: the first eigenvalue of the S matrix
overall error: the error for the CATATIS criterion
error_by_sub: the error by subject (CATATIS criterion)
error_by_prod: the error by product (CATATIS criterion)
s_with_compromise: the similarity coefficient of each subject with the compromise
homogeneity: homogeneity of the subjects (in percentage)
CA: the results of correspondence analysis performed on the compromise dataset
eigenvalues: the eigenvalues associated to the correspondence analysis
inertia: the percentage of total variance explained by each axis of the CA
scalefactors: the scaling factors of each subject
nb_1: the number of 1 in each block, i.e. the number of checked attributes by subject.
param: parameters called
References
Llobell, F., Cariou, V., Vigneau, E., Labenne, A., & Qannari, E. M. (2019). A new approach for the analysis of data and the clustering of subjects in a CATA experiment. Food Quality and Preference, 72, 31-39.
Bonnet, L., Ferney, T., Riedel, T., Qannari, E.M., Llobell, F. (September 14, 2022) .Using CATA for sensory profiling: assessment of the panel performance. Eurosense, Turku, Finland.
See Also
plot.catatis
, summary.catatis
, cluscata
, change_cata_format
, change_cata_format2
Examples
data(straw)
res.cat=catatis(straw, nblo=114)
summary(res.cat)
plot(res.cat)
#Vertical format with sessions
data("fish")
chang=change_cata_format2(fish, nprod= 6, nattr= 27, nsub = 12, nsess= 3)
res.cat2=catatis(Data= chang$Datafinal, nblo = 12, NameBlocks = chang$NameSub, Test_weights=TRUE)
#Vertical format without sessions
Data=fish[1:66,2:30]
chang2=change_cata_format2(Data, nprod= 6, nattr= 27, nsub = 11, nsess= 1)
res.cat3=catatis(Data= chang2$Datafinal, nblo = 11, NameBlocks = chang2$NameSub)