Description Usage Arguments Details Value References See Also Examples
Recursive partitioning (also known as trees) based on Rasch models.
1 2 3 4 5 6 7 8 9 10 11 12 13  raschtree(formula, data, na.action,
reltol = 1e10, deriv = c("sum", "diff", "numeric"), maxit = 100L,
...)
## S3 method for class 'raschtree'
predict(object, newdata = NULL,
type = c("probability", "cumprobability", "mode", "median", "mean",
"categoryinformation", "iteminformation", "testinformation", "node"),
personpar = 0, ...)
## S3 method for class 'raschtree'
plot(x, type = c("profile", "regions"), terminal_panel = NULL,
tp_args = list(...), tnex = 2L, drop_terminal = TRUE, ...)

formula 
A symbolic description of the model to be fit. This
should be of type 
data 
a data frame containing the variables in the model. 
na.action 
a function which indicates what should happen when the data
contain missing values ( 
deriv 
character. Which type of derivatives should be used for computing
gradient and Hessian matrix? Analytical with sum algorithm ( 
reltol, maxit 
arguments passed via 
... 
arguments passed to the underlying functions, i.e., to

object, x 
an object of class 
newdata 
optional data frame with partitioning variables for which predictions should be computed. By default the learning data set is used. 
type 
character specifying the type of predictions or plot. For the

personpar 
numeric person parameter (of length 1) at which the predictions are evaluated. 
terminal_panel, tp_args, tnex, drop_terminal 
arguments passed to

Rasch trees are an application of modelbased recursive partitioning
(implemented in mob
) to Rasch models
(implemented in raschmodel
).
Various methods are provided for "raschtree"
objects, most of them
inherit their behavior from "modelparty"
objects (e.g., print
, summary
,
etc.). For the Rasch models in the nodes of a tree, coef
extracts all item
parameters except the first one which is always restricted to be zero. itempar
extracts all item parameters (including the first one) and by default restricts their
sum to be zero (but other restrictions can be used as well). The plot
method
by default employs the node_profileplot
panelgenerating function and
the node_regionplot
panelgenerating function is provided as an alternative.
Rasch tree models are introduced in Strobl et al. (2015), whose analysis
for the SPISA
data is replicated in
vignette("raschtree", package = "psychotree")
. Their illustration
employing artificial data is replicated below.
An object of S3 class "raschtree"
inheriting from class "modelparty"
.
Strobl C, Kopf J, Zeileis A (2015). Rasch Trees: A New Method for Detecting Differential Item Functioning in the Rasch Model. Psychometrika, 80(2), 289–316. doi: 10.1007/s1133601393883
mob
, raschmodel
,
rstree
, pctree
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  o < options(digits = 4)
## artificial data
data("DIFSim", package = "psychotree")
## fit Rasch tree model
rt < raschtree(resp ~ age + gender + motivation, data = DIFSim)
plot(rt)
## extract item parameters
coef(rt)
itempar(rt)
## inspect parameter stability tests in all splitting nodes
library("strucchange")
sctest(rt, node = 1)
sctest(rt, node = 2)
## highlight items 3 and 14 with DIF
ix < rep(1, 20)
ix[c(3, 14)] < 2
plot(rt, ylines = 2.5, cex = c(0.4, 0.8)[ix],
pch = c(19, 19)[ix], col = gray(c(0.5, 0))[ix])
options(digits = o$digits)

Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.