`R/dif.R`

, `R/summary.GDINA.R`

`dif.Rd`

This function is used to detect differential item functioning based on the models estimated
in the `GDINA`

function using the Wald test (Hou, de la Torre, & Nandakumar, 2014) and the likelihood ratio
test (Ma, Terzi, Lee, & de la Torre, 2017). It can only detect DIF for two groups currently.

dif( dat, Q, group, model = "GDINA", method = "wald", anchor.items = NULL, dif.items = "all", p.adjust.methods = "holm", approx = FALSE, SE.type = 2, ... ) # S3 method for dif summary(object, ...)

dat | item responses from two groups; missing data need to be coded as |
---|---|

Q | Q-matrix specifying the association between items and attributes |

group | a numerical vector with integer 1, 2, ..., # of groups indicating the group each individual belongs to. It must start from 1 and its length must be equal to the number of individuals. |

model | model for each item. |

method | DIF detection method; It can be |

anchor.items | which items will be used as anchors? Default is |

dif.items | which items are subject to DIF detection? Default is |

p.adjust.methods | adjusted p-values for multiple hypothesis tests. This is conducted using |

approx | Whether an approximated LR test is implemented? If TRUE, parameters of items except the studied one will not be re-estimated. |

SE.type | Type of standard error estimation methods for the Wald test. |

... | arguments passed to GDINA function for model calibration |

object | dif object for S3 method |

A data frame giving the Wald statistics and associated p-values.

`summary`

: print summary information

Hou, L., de la Torre, J., & Nandakumar, R. (2014). Differential item functioning assessment in cognitive diagnostic modeling: Application of the Wald test to
investigate DIF in the DINA model. *Journal of Educational Measurement, 51*, 98-125.

Ma, W., Terzi, R., Lee, S., & de la Torre, J. (2017, April). Multiple group cognitive diagnosis models and their applications in detecting differential item functioning. Paper presented at the Annual Meeting ofthe American Educational Research Association, San Antonio, TX.

if (FALSE) { set.seed(123456) N <- 3000 Q <- sim10GDINA$simQ gs <- matrix(c(0.1,0.2, 0.1,0.2, 0.1,0.2, 0.1,0.2, 0.1,0.2, 0.1,0.2, 0.1,0.2, 0.1,0.2, 0.1,0.2, 0.1,0.2),ncol = 2, byrow = TRUE) # By default, individuals are simulated from uniform distribution # and deltas are simulated randomly sim1 <- simGDINA(N,Q,gs.parm = gs,model="DINA") sim2 <- simGDINA(N,Q,gs.parm = gs,model=c(rep("DINA",9),"DINO")) dat <- rbind(extract(sim1,"dat"),extract(sim2,"dat")) gr <- c(rep(1,N),rep(2,N)) dif.out <- dif(dat,Q,group=gr) dif.out2 <- dif(dat,Q,group=gr,method="LR") }