residuals-method: Compute model residuals

Description Usage Arguments References Examples

Description

Return model implied residuals for linear dependencies between items or at the person level.

Usage

1
2
3
4
5
## S4 method for signature 'SingleGroupClass'
residuals(object, type = "LD", df.p = FALSE,
  full.scores = FALSE, QMC = FALSE, printvalue = NULL, tables = FALSE,
  verbose = TRUE, Theta = NULL, suppress = 1, theta_lim = c(-6, 6),
  quadpts = NULL, ...)

Arguments

object

an object of class SingleGroupClass or MultipleGroupClass. Bifactor models are automatically detected and utilized for better accuracy

type

type of residuals to be displayed. Can be either 'LD' or 'LDG2' for a local dependence matrix based on the X2 or G2 statistics (Chen & Thissen, 1997), 'Q3' for the statistic proposed by Yen (1984), or 'exp' for the expected values for the frequencies of every response pattern. For the 'LD' and 'LDG2' types, the upper diagonal elements represent the standardized residuals in the form of signed Cramers V coefficients

df.p

logical; print the degrees of freedom and p-values?

full.scores

logical; compute relevant statistics for each subject in the original data?

QMC

logical; use quasi-Monte Carlo integration? If quadpts is omitted the default number of nodes is 5000

printvalue

a numeric value to be specified when using the res='exp' option. Only prints patterns that have standardized residuals greater than abs(printvalue). The default (NULL) prints all response patterns

tables

logical; for LD type, return the observed, expected, and standardized residual tables for each item combination?

verbose

logical; allow information to be printed to the console?

Theta

a matrix of factor scores used for statistics that require empirical estimates (i.e., Q3). If supplied, arguments typically passed to fscores() will be ignored and these values will be used instead

suppress

a numeric value indicating which parameter local dependency combinations to flag as being too high. Absolute values for the standardized estimates greater than this value will be returned, while all values less than this value will be set to NA

theta_lim

range for the integration grid

quadpts

number of quadrature nodes to use. The default is extracted from model (if available) or generated automatically if not available

...

additional arguments to be passed to fscores()

References

Chalmers, R., P. (2012). mirt: A Multidimensional Item Response Theory Package for the R Environment. Journal of Statistical Software, 48(6), 1-29. doi: 10.18637/jss.v048.i06

Chen, W. H. & Thissen, D. (1997). Local dependence indices for item pairs using item response theory. Journal of Educational and Behavioral Statistics, 22, 265-289.

Yen, W. (1984). Effects of local item dependence on the fit and equating performance of the three parameter logistic model. Applied Psychological Measurement, 8, 125-145.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
## Not run: 

x <- mirt(Science, 1)
residuals(x)
residuals(x, tables = TRUE)
residuals(x, type = 'exp')
residuals(x, suppress = .15)

# with and without supplied factor scores
Theta <- fscores(x)
residuals(x, type = 'Q3', Theta=Theta)
residuals(x, type = 'Q3', method = 'ML')


## End(Not run)

xzhaopsy/MIRT documentation built on May 29, 2019, 12:42 p.m.