Learn R Programming

DiscriMiner (version 0.1-29)

disqual: Discriminant Analysis on Qualitative Variables

Description

Implementation of the DISQUAL methodology. Disqual performs a Fishers Discriminant Analysis on components from a Multiple Correspondence Analysis

Usage

disqual(variables, group, validation = NULL, learn = NULL, test = NULL, autosel = TRUE, prob = 0.05)

Arguments

variables
data frame with qualitative explanatory variables (coded as factors)
group
vector or factor with group memberships
validation
type of validation, either "crossval" or "learntest". Default NULL
learn
optional vector of indices for a learn-set. Only used when validation="learntest". Default NULL
test
optional vector of indices for a test-set. Only used when validation="learntest". Default NULL
autosel
logical indicating automatic selection of MCA components
prob
probability level for automatic selection of MCA components. Default prob = 0.05

Value

An object of class "disqual", basically a list with the following elements:
raw_coefs
raw coefficients of discriminant functions
norm_coefs
normalizaed coefficients of discriminant functions, ranging from 0 - 1000
confusion
confusion matrix
scores
discriminant scores for each observation
classification
assigned class
error_rate
misclassification error rate

Details

When validation=NULL there is no validation When validation="crossval" cross-validation is performed by randomly separating the observations in ten groups. When validation="learntest" validationi is performed by providing a learn-set and a test-set of observations.

References

Lebart L., Piron M., Morineau A. (2006) Statistique Exploratoire Multidimensionnelle. Dunod, Paris.

Saporta G. (2006) Probabilites, analyse des donnees et statistique. Editions Technip, Paris.

Saporta G., Niang N. (2006) Correspondence Analysis and Classification. In Multiple Correspondence Analysis and Related Methods, Eds. Michael Greenacre and Jorg Blasius, 371-392. Chapman and Hall/CRC

See Also

easyMCA, classify, binarize

Examples

Run this code
## Not run: 
#   # load insurance dataset
#   data(insurance)
# 
#   # disqual analysis with no validation
#   my_disq1 = disqual(insurance[,-1], insurance[,1], validation=NULL)
#   my_disq1
# 
#   # disqual analysis with cross-validation
#   my_disq2 = disqual(insurance[,-1], insurance[,1], validation="crossval")
#   my_disq2
#   ## End(Not run)

Run the code above in your browser using DataLab