# set a seed to replicate the results
set.seed(999)
# Simulate person and item parameters
true_theta <- rnorm(1000)
b <- runif(30, -3, 3)
a <- runif(30, 0.6, 2)
parameters <- data.frame(b, a)
# simulate data
data <- sirt::sim.raschtype(true_theta, b = b, fixed.a = a)
stf_uip = uip(data, starting_theta = true_theta, item_par = parameters, num_item = 10)
# check the obtained short test form
stf_uip$item_stf
# check the comparison between the short test form and the full-length test
stf_uip$summary
Run the code above in your browser using DataLab