Learn R Programming

CDM (version 2.7-7)

data.dcm: Dataset from Book 'Diagnostic Measurement' of Rupp, Templin and Henson (2010)

Description

Dataset from chapter 9 of the book 'Diagnostic Measurement' (Rupp, Templin & Henson, 2010).

Usage

data(data.dcm)

Arguments

format

The format of the data is a list containing the dichotomous item response data data (10000 persons at 7 items) and the Q-matrix q.matrix (7 items and 3 skills): List of 2 $ data :'data.frame': ..$ id: int [1:10000] 1 2 3 4 5 6 7 8 9 10 ... ..$ D1: num [1:10000] 0 0 0 0 1 0 1 0 0 1 ... ..$ D2: num [1:10000] 0 0 0 0 0 1 1 1 0 1 ... ..$ D3: num [1:10000] 1 0 1 0 1 1 0 0 0 1 ... ..$ D4: num [1:10000] 0 0 1 0 0 1 1 1 0 0 ... ..$ D5: num [1:10000] 1 0 0 0 1 1 1 0 1 0 ... ..$ D6: num [1:10000] 0 0 0 0 1 1 1 0 0 1 ... ..$ D7: num [1:10000] 0 0 0 0 0 1 1 0 1 1 ... $ q.matrix: num [1:7, 1:3] 1 0 0 1 1 0 1 0 1 0 ... ..- attr(*, "dimnames")=List of 2 .. ..$ : chr [1:7] "D1" "D2" "D3" "D4" ... .. ..$ : chr [1:3] "skill1" "skill2" "skill3"

source

For supplementary material of the Rupp, Templin and Henson book (2010) see http://dcm.coe.uga.edu/. The dataset was downloaded from http://dcm.coe.uga.edu/supplemental/chapter9.html.

References

Rupp, A. A., Templin, J., & Henson, R. A. (2010). Diagnostic Measurement: Theory, Methods, and Applications. New York: The Guilford Press.

Examples

Run this code
data(data.dcm)

# Model 1: DINA model
mod1 <- din( data.dcm$data[,-1] , q.matrix=data.dcm$q.matrix )
summary(mod1)

# Model 2: DINO model
mod2 <- din( data.dcm$data[,-1] , q.matrix=data.dcm$q.matrix , rule="DINO")
summary(mod2)

# Model 3: log-linear model (LCDM): this model is the GDINA model with the
#    logit link function
mod3 <- gdina( data.dcm$data[,-1] , q.matrix=data.dcm$q.matrix , link="logit")
summary(mod3)

# Model 4: GDINA model with identity link function
mod4 <- gdina( data.dcm$data[,-1] , q.matrix=data.dcm$q.matrix )
summary(mod4)

# Model 5: GDINA additive model identity link function
mod5 <- gdina( data.dcm$data[,-1] , q.matrix=data.dcm$q.matrix , rule="ACDM")
summary(mod5)

# Model 6: GDINA additive model logit link function
mod6 <- gdina( data.dcm$data[,-1] , q.matrix=data.dcm$q.matrix , link="logit" , 
          rule="ACDM")
summary(mod6)

# Model 7: reduced RUM model
mod7 <- gdina( data.dcm$data[,-1] , q.matrix=data.dcm$q.matrix , rule="RRUM")
summary(mod7)

# Model 8: latent class model with 3 classes
# randomLCA package: 4 trials
library(randomLCA)
mod8a <- randomLCA( data.dcm$data[,-1], nclass= 3 , verbose=TRUE , notrials=4)
# rasch.mirtlc function in sirt package
library(sirt)
mod8b <- rasch.mirtlc( data.dcm$data[,-1] , Nclasses=3 , nstarts=4 )
summary(mod8a)
summary(mod8b)

Run the code above in your browser using DataLab