Last chance! 50% off unlimited learning
Sale ends in
personfit
calculates the Zh values from Drasgow, Levine and Williams (1985) for
unidimensional and multidimensional models. For Rasch models infit and outfit statistics are
also produced. The returned object is a data.frame
consisting either of the tabulated data or full data with the statistics appended to the
rightmost columns.
personfit(x, method = "EAP", Theta = NULL, stats.only = TRUE, ...)
a computed model object of class SingleGroupClass
or MultipleGroupClass
type of factor score estimation method. See fscores
for more detail
a matrix of factor scores used for statistics that require emperical estimates. If
supplied, arguments typically passed to fscores()
will be ignored and these values will
be used instead
logical; return only the person fit statistics without their associated response pattern?
additional arguments to be passed to fscores()
Drasgow, F., Levine, M. V., & Williams, E. A. (1985). Appropriateness measurement with polychotomous item response models and standardized indices. British Journal of Mathematical and Statistical Psychology, 38, 67-86.
Reise, S. P. (1990). A comparison of item- and person-fit methods of assessing model-data fit in IRT. Applied Psychological Measurement, 14, 127-137.
Wright B. D. & Masters, G. N. (1982). Rating scale analysis. MESA Press.
# NOT RUN {
# }
# NOT RUN {
#make some data
set.seed(1234)
a <- matrix(rlnorm(20),ncol=1)
d <- matrix(rnorm(20),ncol=1)
items <- rep('dich', 20)
data <- simdata(a,d, 2000, items)
x <- mirt(data, 1)
fit <- personfit(x)
head(fit)
#using precomputed Theta
Theta <- fscores(x, method = 'MAP', full.scores = TRUE)
head(personfit(x, Theta=Theta))
#muliple group Rasch model example
set.seed(12345)
a <- matrix(rep(1, 15), ncol=1)
d <- matrix(rnorm(15,0,.7),ncol=1)
itemtype <- rep('dich', nrow(a))
N <- 1000
dataset1 <- simdata(a, d, N, itemtype)
dataset2 <- simdata(a, d, N, itemtype, sigma = matrix(1.5))
dat <- rbind(dataset1, dataset2)
group <- c(rep('D1', N), rep('D2', N))
models <- 'F1 = 1-15'
mod_Rasch <- multipleGroup(dat, models, itemtype = 'Rasch', group = group)
coef(mod_Rasch, simplify=TRUE)
pf <- personfit(mod_Rasch, method='MAP')
head(pf)
# }
# NOT RUN {
# }
Run the code above in your browser using DataLab