Learn R Programming

xxIRT (version 1.1.0)

mst: Multistage Testing

Description

mst creates a multistage (MST) object

mst.route adds/removes a route to/from the mst object

mst.info.obj adds information objective functions

mst.constraint sets constraints

mst.stagelength sets the min/max length for a stage

mst.assemble solves the LP object and assembles items

mst.summary summarized an assembled mst object

mst.get retreives items from an assembled mst object

mst.sim conducts a simulation for MST

mst.assemble.sequence assembles panels in sequence rather than simultaneously.

Usage

mst(pool, design, npanel)
"print"(x, ...)
mst.route(x, route, op, print = FALSE)
mst.objective(x, thetas, target, routes = NULL)
mst.constraint(x, var, level, min, max, routes = NULL)
mst.stagelength(x, stage, min, max)
mst.assemble(x, ...)
mst.summary(x, ...)
"plot"(x, ...)
mst.get(x, panel, module.index = NULL, route.index = NULL)
mst.sim(x, theta, routing = NULL, estimator = estimate.theta.mle)
mst.assemble.sequence(x, ...)

Arguments

pool
an item pool (data.frame)
design
a vector of number of modules in stages
npanel
the number of panels
x
the mst object
...
further arugments passed to lp.control or choose if summarize results by.route
route
a vector of module index, and check route table in a mst object for routes
op
"+" for adding a route and "-" for removing a route
print
TRUE to print intermediate results
thetas
a vector of theta points where information targets are set
target
a single or vector of numeric values for targets, Inf for maximizing inforation
routes
a vector of route index to add objective functions, or NULL for all routes
var
the constrained variable. "len" for test length
level
the constrained level for a categorical variable. NA or NULL for continuous variable
min
the minimum value
max
the maximum value
stage
the stage being constrained
panel
the panel index
module.index
the module index
route.index
the route index
theta
the value of true theta
routing
a list of routing cut scores or NULL for auto routing
estimator
an ability estimation method.

Value

mst returns a mst object

Details

The mst object contains pool (item pool), route (permissilbe routes), lp (test assembly object), items (assembled items after the lp is solve), nstage (number of stage), nmodule (number of modules), npanel (number of panels), nroute (number of routes), module (module information).

In mst.summary, passing by.route=TRUE to summarize results by routes; otherwise, by modules. A list, consisting of data and plot, is return.

In plot.mst, use by.route=TRUE to plot TIFs for routes; otherwise, TIFs for modules.

In mst.sim, auto routing method routes a test taker to one of the permissible modules that has the largest information. Users can use any theta estimator from the Estimation module. See estimate.theta.mle, estimate.theta.map, and estimate.theta.eap for example. When writing new estimator, make sure it takes arguments as foo(u, a, b, c).

Use mst.assemble.sequence when the LP problem is too large to be solved in mst.assemble. The results will ievitably favor the panels assembled earlier than later. Try to run another round of mst.assemble using those assembled items (perhapse, plus a bit more randomly selected items) to reduce the unparallelism between panels.

Examples

Run this code
# generate an item pool
pool <- gen.irt(1, 200)$items
pool$content <- sample(1:3, nrow(pool), replace=TRUE)
# 1-2-3 design with 2 parallel panels
x <- mst(pool, c(1, 2, 3), 2)
# remove route with radical changes from the 1-3-3 design
x <- mst.route(x, c(1, 2, 6), "-", print=TRUE)
x <- mst.route(x, c(1, 3, 4), "-", print=TRUE)
# maximize information at -1.0/0/1.0 for low-/mid-/high-ability routes
x <- mst.objective(x, -1.0, Inf, routes=1)
x <- mst.objective(x,  0.0, Inf, routes=2:3)
x <- mst.objective(x,  1.0, Inf, routes=4)
# all routes to have 10 items
x <- mst.constraint(x, "len", NA, 10, 10)
x <- mst.constraint(x, "content", 1, 3, 3)
# all least 2 items each stage
x <- mst.stagelength(x, 1, 2, 10)
x <- mst.stagelength(x, 2, 2, 10)
x <- mst.stagelength(x, 3, 2, 10)
# assemble
x <- mst.assemble(x)
# check content
for(p in 1:x$npanel){
 for(r in 1:x$nroute){
   cat("Panel #", p, " Route #", r, ", Content Area 1 has ",
   freq(mst.get(x, panel=p, route=r)$content, 1:3)$n[1], " items.\n", sep="")
 }
}
# check TIFs
plot(x, by.route=TRUE)
# run simulation
mst.sim(x,  1.5)
mst.sim(x,  0.5)
mst.sim(x, -0.5)
mst.sim(x, -1.5)
# Solve a big problem in sequence
rm("x")
pool <- gen.irt(1, 1000)$items
pool$content <- sample(1:3, nrow(pool), replace=TRUE)
x <- mst(pool, c(1, 2, 3), 3)
x <- mst.route(x, c(1, 2, 6), "-")
x <- mst.route(x, c(1, 3, 4), "-")
x <- mst.objective(x, -1.0, Inf, routes=1)
x <- mst.objective(x,  0.0, Inf, routes=2:3)
x <- mst.objective(x,  1.0, Inf, routes=4)
x <- mst.constraint(x, "len", NA, 10, 10)
x <- mst.constraint(x, "content", 1, 3, 3)
x <- mst.stagelength(x, 1, 2, 10)
x <- mst.stagelength(x, 2, 2, 10)
x <- mst.stagelength(x, 3, 2, 10)
# unlikely to be solved simulatanouesly within 1 minute
# invisible(mst.assemble(x, timeout=60))
# may be solved in sequence within 1 minute
x <- mst.assemble.sequence(x, timeout=60)
plot(x, by.route=TRUE)

Run the code above in your browser using DataLab