mst: Computerized Multistage Testing Simulation

Description

mst creates a multistage (MST) object

mst.route.index.search is a helper function for finding the index of a given route vector

mst.get.index is a helper function for getitng route (in topdown method) or module (in bottomup method) indices

mst.route manipulates routes in the mst

mst.objective adds objective functions to the mst

mst.constraint adds constraints to the mst

mst.stage.length sets the minimal and maximal length for a stage

mst.assemble assembles items

mst.get.items extracts items from results

mst.sim performs a simulation for an assembled mst

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
mst(pool, design, npanel, method)

mst.route.index.search(x, route)

mst.get.index(x, indices)

mst.route(x, route, op)

mst.objective(x, theta, indices = NULL, target = NULL, flatten = NULL,
  theta.step = 2)

mst.constraint(x, coef, min = NA, max = NA, level = NULL,
  indices = NULL)

mst.stage.length(x, stages, min = NA, max = NA)

mst.assemble(x, ...)

## S3 method for class 'mst'
print(x, ...)

## S3 method for class 'mst'
plot(x, ...)

mst.get.items(x, panel, stage = NULL, module = NULL, route = NULL)

mst.sim(x, theta.true)

Arguments

pool

a data frame of items

design

a numeric vector to specify the MST design (e.g., 1-2-3, or 1-2-2)

npanel

the number of panels

method

the design method (i.e., 'topdown' or 'bottomup')

x

the mst object

route

a index number or a vector of module index

indices

the index of the route (topdown) or the module (bottomup) for adding objectives

op

"+" for adding a route and "-" for removing a route

theta

a theta point or range for optimization

target

the target valus of the TIF objectives. NULL for maximization

flatten

the parameter for getting a flat TIF

theta.step

the step parameters to bridge theta.lb and theta.ub

coef

the coefficients of the constraint

min

the minimal value of the contraint

max

the maximal value of the contraint

level

the level value for a categorical constraint

stages

the stage index

...

further arguments

panel

the index of panel

stage

the index of stage

module

the index of module

theta.true

the true value of theta parameter

Details

The mst object contains an item pool (pool), a test assembler (assembler), a route map (route), a stage-module map (module), a design method (method), and several constants such as npanel, nstage, nmodule, nroute.
Two indices are used to index modules/testlets. form number is a unique identifier for all modules, which is used for automated test assembly. index is a panel-wise unique identifier, which is used for routing.
There are two design methods for mst: 'bottomup' and 'topdown'. In the bottomup approach, constraitns are imposed on individual modules; however, in the topdown approach, constraints are imposed on routes.

plot.mst draws module information functions if byroute=FALSE and route information functions if byroute=TRUE

Value

mst returns a mst object

mst.get.index returns a selected route- or module-map in the mst

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
## Not run: 
# ex. 1: 1-2-2 MST, 2 panels, topdown, 20 items, content = c(10, 5, 5)
# maximize information at -1 for easy routes and 1 for hard routes
pool <- irt.model()$gen.data(1,300)$items
pool$content <- sample(1:3, nrow(pool), replace=TRUE)
pool$time <- round(exp(rnorm(nrow(pool), log(60), .2)))
x <- mst(pool, design=c(1,2,2), npanel=2, method='topdown')
x$route
x <- mst.objective(x, theta=-1, indices=1:2)
x <- mst.objective(x, theta=1, indices=3:4)
x <- mst.constraint(x, 1, 20, 20)
x <- mst.constraint(x, "content", 10, 10, level=1)
x <- mst.constraint(x, "content", 5, 5, level=2)
x <- mst.constraint(x, "content", 5, 5, level=3)
x <- mst.stage.length(x, c(1,2,3), min=5)
x <- mst.assemble(x)
freq(mst.get.items(x, panel=1,route=1)$content, 1:3)$n
freq(mst.get.items(x, panel=2,route=4)$content, 1:3)$n
plot(x)
plot(x, byroute=TRUE)
mst.sim(x, 1)
mst.sim(x, -1)
# ex. 2: 1-2-2 MST, 2 panels, bottomup, 10 items per stage, content = c(4, 3, 3)
# maximize information at -1 for easy modules, 0 for medium modules and 1 for hard modules
x <- mst(pool, design=c(1,2,2), npanel=2, method='bottomup')
x$module
x <- mst.objective(x, theta=0, indices=1)
x <- mst.objective(x, theta=-1, indices=c(2,4))
x <- mst.objective(x, theta=1, indices=c(3,5))
x <- mst.constraint(x, 1, 10, 10)
x <- mst.constraint(x, "content", 4, 4, level=1)
x <- mst.constraint(x, "content", 3, 3, level=2)
x <- mst.constraint(x, "content", 3, 3, level=3)
x <- mst.assemble(x)
freq(mst.get.items(x, panel=1,route=1)$content, 1:3)$n
freq(mst.get.items(x, panel=2,route=4)$content, 1:3)$n
plot(x)
plot(x, byroute=TRUE)
mst.sim(x, 1)
mst.sim(x, -1)
# ex. 3: 1-2-3 MST, 2 panels, topdown, 30 items, 
# content = c(10, 10, 10), prohibit routes with radical changes
# maximize information at -1 for easy, 0 for medium and 1 for hard routes
x <- mst(pool, design=c(1,2,3), npanel=2, method='topdown')
x <- mst.route(x, c(1,2,6), "-")
x <- mst.route(x, c(1,3,4), "-")
x$route
x <- mst.objective(x, -1, indices=1)
x <- mst.objective(x,  0, indices=2:3)
x <- mst.objective(x,  1, indices=4)
x <- mst.constraint(x, 1, 30, 30)
x <- mst.constraint(x, "content", 10, 10, level=1)
x <- mst.constraint(x, "content", 10, 10, level=2)
x <- mst.constraint(x, "content", 10, 10, level=3)
x <- mst.stage.length(x, c(1,2,3), min=3)
x <- mst.assemble(x, timeout=5*60)
freq(mst.get.items(x, panel=1,route=1)$content, 1:3)$n
freq(mst.get.items(x, panel=2,route=4)$content, 1:3)$n
plot(x)
plot(x, byroute=TRUE)
mst.sim(x, 1)
mst.sim(x, .2)
mst.sim(x, -.2)
mst.sim(x, -1)
# ex. 4: 1-2-3 MST, 2 panels, bottomup, 10 items per stage, 
# content = c(4, 3, 3), prohibit routes with radical changes
# target information at 6 (theta=-1) for easy, 6 (theta=0) for medium 
# and 6 (theta=1) for hard modules
x <- mst(pool, design=c(1,2,3), npanel=2, method='bottomup')
x <- mst.route(x, c(1,2,6), "-")
x <- mst.route(x, c(1,3,4), "-")
x$module
x <- mst.objective(x, -1, indices=c(2,4), target=6)
x <- mst.objective(x,  0, indices=c(1,5), target=6)
x <- mst.objective(x,  1, indices=c(3,6), target=6)
x <- mst.constraint(x, 1, 10, 10)
x <- mst.constraint(x, "content", 4, 4, level=1)
x <- mst.constraint(x, "content", 3, 3, level=2)
x <- mst.constraint(x, "content", 3, 3, level=3)
x <- mst.stage.length(x, c(1,2,3), min=3)
x <- mst.assemble(x, timeout=5*60)
freq(mst.get.items(x, panel=1,route=1)$content, 1:3)$n
freq(mst.get.items(x, panel=2,route=4)$content, 1:3)$n
plot(x)
plot(x, byroute=TRUE)
mst.sim(x, 1)
mst.sim(x, .2)
mst.sim(x, -.2)
mst.sim(x, -1)

## End(Not run)

Questions? Problems? Suggestions? or email at ian@mutexlabs.com.

All documentation is copyright its authors; we didn't write any of that.