Description Usage Arguments Value Examples
View source: R/generate-data.R
This function takes a data set with polytomous items and an irtree_model
and returns the recoded items, the so-called pseudoitems.
1 | irtree_recode(object = NULL, data = NULL, keep = FALSE)
|
object |
Object of class |
data |
Data frame containing containing one row per respondent and one
column per variable. The variable names must correspond to those used in
|
keep |
Logical indicating whether to append the original items to the data frame of the generated pseudoitems |
Data frame
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | m1 <- "
IRT:
t BY x1;
e BY x1;
m BY x1;
Equations:
1 = (1-m)*(1-t)*e
2 = (1-m)*(1-t)*(1-e)
3 = m
4 = (1-m)*t*(1-e)
5 = (1-m)*t*e
Class:
Tree
"
model1 <- irtree_model(m1)
dat <- data.frame(x1 = 1:5)
irtree_recode(model1, dat, keep = TRUE)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.