Last chance! 50% off unlimited learning
Sale ends in
This function returns maximum likelihood estimates of item parameters for cognitive diagnostic models when examinee ability patterns are known. This function can either be used independently or called in the JMLE
function. Currently supported cognitive diagnostic models include the DINA model, the DINO model, the NIDA model, the G-NIDA model, and the R-RUM model.
ParMLE(Y, Q, alpha, model = c("DINA", "DINO", "NIDA", "GNIDA", "RRUM"))
A matrix of binary responses. Rows represent persons and columns represent items. 1=correct, 0=incorrect.
The Q-matrix of the test. Rows represent items and columns represent attributes. 1=attribute required by the item, 0=attribute not required by the item.
Examinee attribute profiles. Rows represent persons and columns represent attributes. 1=examinee masters the attribute, 0=examinee does not master the attribute.
Currently support five models: "DINA"
, "DINO"
, "NIDA"
, "GNIDA"
, and "RRUM"
. The default is "DINA"
.
For the DINA, DINO, and NIDA models:
a vector of slip parameters.
a vector of guessing parameters.
a vector of the standard errors for slip parameters.
a vector of the standard errors for guessing parameters.
a matrix (# items by # attributes) of slip parameters.
a matrix (# items by # attributes) of guessing parameters.
a matrix (# items by # attributes) of the standard errors for slip parameters.
a matrix (# items by # attributes) of the standard errors for guessing parameters.
a vector of pi parameters for each item.
a matrix (# items by # attributes) of r parameters.
a vector of the standard errors for pi parameters.
a matrix (# items by # attributes) of the standard errors for r parameters.
Additionally, for all models:
The chosen model.
The Q-matrix of the test.
# NOT RUN {
# Generate item and examinee profiles
natt <- 3
nitem <- 4
nperson <- 5
Q <- rbind(c(1, 0, 0), c(0, 1, 0), c(0, 0, 1), c(1, 1, 1))
alpha <- rbind(c(0, 0, 0), c(1, 0, 0), c(0, 1, 0), c(0, 0, 1), c(1, 1, 1))
# Generate DINA model-based response data
slip <- c(0.1, 0.15, 0.2, 0.25)
guess <- c(0.1, 0.15, 0.2, 0.25)
my.par <- list(slip=slip, guess=guess)
data <- matrix(NA, nperson, nitem)
eta <- matrix(NA, nperson, nitem)
for (i in 1:nperson) {
for (j in 1:nitem) {
eta[i, j] <- prod(alpha[i,] ^ Q[j, ])
P <- (1 - slip[j]) ^ eta[i, j] * guess[j] ^ (1 - eta[i, j])
u <- runif(1)
data[i, j] <- as.numeric(u < P)
}
}
# Using the function to estimate item parameters
parMLE.result <- ParMLE(data, Q, alpha, model="DINA")
print(parMLE.result) # Print the estimated item parameters and standard errors
ItemFit(parMLE.result)
ModelFit(parMLE.result)
# }
Run the code above in your browser using DataLab