Skip to main content

Extract Item Parameters of Item Response Models

Description

A class and generic function for representing and extracting the item parameters of a given item response model.

Usage

  itempar(object, ...)
  ## S3 method for class 'raschmodel'
itempar(object, ref = NULL, alias = TRUE, vcov = TRUE, ...)
  ## S3 method for class 'rsmodel'
itempar(object, ref = NULL, alias = TRUE, vcov = TRUE, ...)
  ## S3 method for class 'pcmodel'
itempar(object, ref = NULL, alias = TRUE, vcov = TRUE, ...)
  ## S3 method for class 'nplmodel'
itempar(object, ref = NULL, alias = TRUE, vcov = TRUE, ...)
  ## S3 method for class 'gpcmodel'
itempar(object, ref = NULL, alias = TRUE, vcov = TRUE, ...)
  ## S3 method for class 'btmodel'
itempar(object, ref = NULL, alias = TRUE, vcov = TRUE, log = FALSE, ...)

Arguments

object a fitted model or tree object whose item parameters should be extracted.
ref a vector of labels or position indices of item parameters or a contrast matrix which should be used as restriction/for normalization. If NULL (the default) for all models except models estimated via MML, all items are used (sum zero restriction). For models estimated via MML (nplmodels and gpcmodels), the parameters are by default identified via the distributional parameters of the person parameters (mean and variance of a normal distribution). Nevertheless, a restriction on the interval scale can be applied.
alias logical. If TRUE (the default), the aliased parameter is included in the return vector (and in the variance-covariance matrix if vcov = TRUE). If FALSE, it is removed. If the restriction given in ref depends on several parameters, the first parameter of the restriction specified is (arbitrarily) chosen to be removed if alias is FALSE.
vcov logical. If TRUE (the default), the (transformed) variance-covariance matrix of the item parameters is attached as attribute vcov. If FALSE, an NA-matrix is attached.
log logical. Whether to return the estimated model parameters on the logit (TRUE) or preference scale (FALSE).
… further arguments which are currently not used.

Details

itempar is both, a class to represent item parameters of item response models as well as a generic function. The generic function can be used to extract the item parameters of a given item response model.

For Rasch models and n-parameter logistic models, itempar returns the estimated item difficulty parameters \(\hat{\beta}_{j}\) under the restriction specified in argument ref. For rating scale models, itempar returns computed item location parameters \(\hat{\beta}_{j}\) under the restriction specified in argument ref. These are computed from the estimated item-specific parameters \(\hat{\xi}_{j}\) (who mark the location of the first category of an item on the latent theta axis). For partial credit models and generalized partial credit models, itempar returns ‘mean’ absolute item threshold parameters, {j} = {k = 1}^{p_{j}}_{jk}, i.e., a single parameter per item is returned which results as the mean of the absolute item threshold parameters \(\hat{\delta}_{jk}\) of this item. Based upon these ‘mean’ absolute item threshold parameters \(\hat{\beta}_{j}\), the restriction specified in argument ref is applied. For all models, the variance-covariance matrix of the returned item parameters is adjusted according to the multivariate delta rule.

For objects of class itempar, several methods to standard generic functions exist: print, coef, vcov. coef and vcov can be used to extract the estimated calculated item parameters and their variance-covariance matrix without additional attributes. Based on this Wald tests or confidence intervals can be easily computed, e.g., via confint.

Two-sample item-wise Wald tests for DIF in the item parameters can be carried out using the function anchortest.

Value

A named vector with item parameters of class itempar and additional attributes model (the model name), ref (the items or parameters used as restriction/for normalization), alias (either FALSE or a named character vector with the removed aliased parameter, and vcov (the adjusted covariance matrix of the estimates if vcov = TRUE or an NA-matrix otherwise).

See Also

personpar, threshpar, discrpar, guesspar, upperpar

Examples

library("psychotools")

o <- options(digits = 4)

## load verbal aggression data
data("VerbalAggression", package = "psychotools")

## fit a Rasch model to dichotomized verbal aggression data
raschmod <- raschmodel(VerbalAggression$resp2)

## extract item parameters with sum zero or use last two items as anchor
ip1 <- itempar(raschmod)
ip2a <- itempar(raschmod, ref = 23:24) # with position indices
ip2b <- itempar(raschmod, ref = c("S4WantShout", "S4DoShout")) # with item label

ip1
Item response item parameters (RM):
S1WantCurse   S1DoCurse S1WantScold   S1DoScold S1WantShout   S1DoShout 
    -1.3834     -1.3834     -0.7307     -0.5566     -0.2491      0.6981 
S2WantCurse   S2DoCurse S2WantScold   S2DoScold S2WantShout   S2DoShout 
    -1.9093     -1.0367     -0.8727     -0.1131     -0.1810      1.3120 
S3WantCurse   S3DoCurse S3WantScold   S3DoScold S3WantShout   S3DoShout 
    -0.6955      0.0403      0.5136      1.3348      1.3577      2.8709 
S4WantCurse   S4DoCurse S4WantScold   S4DoScold S4WantShout   S4DoShout 
    -1.2450     -0.8727      0.1779      0.2126      0.8711      1.8402 
ip2a
Item response item parameters (RM):
S1WantCurse   S1DoCurse S1WantScold   S1DoScold S1WantShout   S1DoShout 
   -2.73904    -2.73905    -2.08637    -1.91227    -1.60471    -0.65752 
S2WantCurse   S2DoCurse S2WantScold   S2DoScold S2WantShout   S2DoShout 
   -3.26495    -2.39238    -2.22840    -1.46881    -1.53669    -0.04366 
S3WantCurse   S3DoCurse S3WantScold   S3DoScold S3WantShout   S3DoShout 
   -2.05119    -1.31534    -0.84209    -0.02087     0.00205     1.51526 
S4WantCurse   S4DoCurse S4WantScold   S4DoScold S4WantShout   S4DoShout 
   -2.60068    -2.22840    -1.17772    -1.14302    -0.48456     0.48456 
all.equal(ip2a, ip2b)
[1] TRUE
## extract vcov
vc1 <- vcov(ip1)
vc2 <- vcov(ip2a)

## adjusted standard errors,
## smaller with more items used as anchors
sqrt(diag(vc1))
S1WantCurse   S1DoCurse S1WantScold   S1DoScold S1WantShout   S1DoShout 
     0.1400      0.1400      0.1306      0.1294      0.1283      0.1349 
S2WantCurse   S2DoCurse S2WantScold   S2DoScold S2WantShout   S2DoShout 
     0.1535      0.1341      0.1321      0.1284      0.1283      0.1479 
S3WantCurse   S3DoCurse S3WantScold   S3DoScold S3WantShout   S3DoShout 
     0.1303      0.1287      0.1324      0.1485      0.1492      0.2219 
S4WantCurse   S4DoCurse S4WantScold   S4DoScold S4WantShout   S4DoShout 
     0.1374      0.1321      0.1294      0.1296      0.1378      0.1654 
sqrt(diag(vc2))
S1WantCurse   S1DoCurse S1WantScold   S1DoScold S1WantShout   S1DoShout 
     0.1822      0.1822      0.1739      0.1727      0.1715      0.1758 
S2WantCurse   S2DoCurse S2WantScold   S2DoScold S2WantShout   S2DoShout 
     0.1940      0.1770      0.1752      0.1714      0.1714      0.1861 
S3WantCurse   S3DoCurse S3WantScold   S3DoScold S3WantShout   S3DoShout 
     0.1736      0.1715      0.1740      0.1866      0.1872      0.2524 
S4WantCurse   S4DoCurse S4WantScold   S4DoScold S4WantShout   S4DoShout 
     0.1799      0.1752      0.1719      0.1720      0.1098      0.1098 
## Wald confidence intervals
confint(ip1)
               2.5 %    97.5 %
S1WantCurse -1.65779 -1.108969
S1DoCurse   -1.65780 -1.108975
S1WantScold -0.98677 -0.474645
S1DoScold   -0.81017 -0.303037
S1WantShout -0.50057  0.002469
S1DoShout    0.43369  0.962584
S2WantCurse -2.21010 -1.608490
S2DoCurse   -1.29956 -0.773879
S2WantScold -1.13156 -0.613916
S2DoScold   -0.36472  0.138425
S2WantShout -0.43251  0.070440
S2DoShout    1.02215  1.601865
S3WantCurse -0.95101 -0.440049
S3DoCurse   -0.21201  0.292654
S3WantScold  0.25401  0.773120
S3DoScold    1.04370  1.625879
S3WantShout  1.06536  1.650059
S3DoShout    2.43599  3.305848
S4WantCurse -1.51430 -0.975743
S4DoCurse   -1.13156 -0.613916
S4WantScold -0.07573  0.431608
S4DoScold   -0.04146  0.466738
S4WantShout  0.60095  1.141248
S4DoShout    1.51595  2.164496
confint(ip2a)
              2.5 %  97.5 %
S1WantCurse -3.0961 -2.3819
S1DoCurse   -3.0962 -2.3819
S1WantScold -2.4272 -1.7455
S1DoScold   -2.2507 -1.5738
S1WantShout -1.9408 -1.2686
S1DoShout   -1.0022 -0.3129
S2WantCurse -3.6451 -2.8848
S2DoCurse   -2.7393 -2.0454
S2WantScold -2.5717 -1.8850
S2DoScold   -1.8047 -1.1329
S2WantShout -1.8726 -1.2007
S2DoShout   -0.4084  0.3211
S3WantCurse -2.3915 -1.7109
S3DoCurse   -1.6515 -0.9792
S3WantScold -1.1831 -0.5011
S3DoScold   -0.3866  0.3449
S3WantShout -0.3648  0.3689
S3DoShout    1.0206  2.0099
S4WantCurse -2.9533 -2.2481
S4DoCurse   -2.5717 -1.8850
S4WantScold -1.5146 -0.8408
S4DoScold   -1.4802 -0.8058
S4WantShout -0.6998 -0.2694
S4DoShout    0.2694  0.6998
options(digits = o$digits)