simRasch {plRasch} | R Documentation |
Simulate the data matrix from a Rasch Model
simRasch(ncat, nitem, nexaminee, beta = NULL)
ncat |
number of response categories |
nitem |
number of items |
nexaminee |
number of examinees |
beta |
item parameter; if it is NULL, beta will be randomly generated from the standard normal distribution |
data |
data is generated from Rasch model. It is a data frame or matrix with rows indicating individuals, columns indicating items, and the entry values indicating the choices are either 0 or 1 |
beta |
item parameter |
theta |
the underlying latent trait |
Zhushan "Mandy" Li & Feng Hong
Anderson, C.J., Li, Z., & Vermunt, J.K. (2007). Estimation of models in the Rasch family for polytomous items and multiple latent variables. Journal of Statistical Software, 20.
NCAT <- 2; NITEM <- 4; NEXAMINEE <- 50; BETA <- c(-1, 0, 0.5, 1) set.seed(1); rasch.sim <- simRasch(ncat=NCAT, nitem=NITEM, nexaminee=NEXAMINEE, beta=BETA)