tabcontrib.Rd
Identifies the categories that contribute the most to a given dimension of a Multiple Correspondence Analysis and organizes these informations into a fancy table.
tabcontrib(resmca, dim = 1,
best = TRUE, limit = NULL,
dec = 2, shortlabs = FALSE)
object created with MCA
, speMCA
, csMCA
, wcMCA
or bcMCA
function
dimension to describe (default is 1st dimension)
if FALSE, displays all the categories; if TRUE (default), displays only categories which contribute the most (see limit argument below)
numerical value between 0 and 100. If best = TRUE (see above), only categories with percentage of contribution higher or equal to limit are displayed. If best = TRUE and limit = NULL (default), only categories with contributions higher or equal to average are displayed.
integer. The number of decimals for the results (default is 2)
logical. If TRUE, the data frame will have short column names, so that all columns can be displayed side by side on a laptop screen. Default is FALSE (long explicit column names).
A data frame with the following contributions.:
names of the variables
names of the categories
weights of the categories
quality of representation (squared cosine) of the categories on the axis
contributions of the categories located on one side of the axis
contributions of the categories located on the other side of the axis
contributions summed by variable
cumulated sum of the contributions
for each variable, contribution of the deviation between the barycenter of the categories located on one side of the axis and the barycenter of those located on the other side
contribution of deviation expressed as a proportion of the contribution of the variable
Le Roux B. and Rouanet H., Multiple Correspondence Analysis, SAGE, Series: Quantitative Applications in the Social Sciences, Volume 163, CA:Thousand Oaks (2010).
Le Roux B. and Rouanet H., Geometric Data Analysis: From Correspondence Analysis to Stuctured Data Analysis, Kluwer Academic Publishers, Dordrecht (June 2004).
# specific MCA of Music example data set
data(Music)
junk <- c("FrenchPop.NA", "Rap.NA", "Rock.NA", "Jazz.NA", "Classical.NA")
mca <- speMCA(Music[,1:5], excl = junk)
# main contributions on axis 1
tabcontrib(mca, 1)
#> Variable Category Weight Quality of representation
#> 2 Classical Yes 142 0.539
#> 1 No 351 0.505
#> 3 Jazz Yes 95 0.608
#> Contribution (negative side) Contribution (positive side) Total contribution
#> 2 27.72 38.52
#> 1 10.8
#> 3 35.34 35.34
#> Cumulated contribution Contribution of deviation Proportion to variable
#> 2 38.52 38.52 99.99
#> 1
#> 3 73.87 35.34 80.59
# main contributions on axis 2
tabcontrib(mca, 2)
#> Variable Category Weight Quality of representation
#> 3 Rock Yes 135 0.456
#> 2 No 360 0.435
#> 1 Rap Yes 77 0.525
#> Contribution (negative side) Contribution (positive side) Total contribution
#> 3 30.57 41.76
#> 2 11.19
#> 1 40.74 40.74
#> Cumulated contribution Contribution of deviation Proportion to variable
#> 3 41.76 41.75 100
#> 2
#> 1 82.49 40.74 84.35