Description Usage Arguments References Examples
Function to produce graphical test plot
1 2 3 4 5 6 7 8 9 10 11 |
object |
anchorpoint object as produced by the function |
shift |
shift in item parameters for the second group, default NULL (for global optimum), else numeric (for user-defined shift) |
highlight |
positive integer(s), numbers of the items to be highlighted |
alpha |
significance level for DIF test |
testColors |
list with colors for the items:
|
TestResults |
Waldtest object from anchorpoint::getWald. If NULL, then they are computed within the function. Default: NULL. |
ask |
logical, ask for next plot. Default = TRUE |
... |
further arguments for plot() like lty, cex.axis, cex.main, cex.lab etc. |
Credit: Part of the code is adapted from the function plotGOF
of the package eRm (Version: 1.32.1):
Mair P, Hatzinger R. Extended Rasch modeling: The eRm package for the application of IRT models in R. Journal of Statistical Software. 2007;20 (9) :1-20.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 | # Load the SPISA data set (general knowledge quiz - more information at ?SPISA)
library("psychotree")
data("SPISA")
# Fit the Rasch Models for the two groups females and males
fit <- raschFit(SPISA, resp.mat.name='spisa', group.name='gender')
# Rasch Model fit for the first and second group
rm1 <- fit$rm1
rm2 <- fit$rm2
# Fit an Anchorpoint object
ap_object <- anchorpoint(rm1,rm2,select = "Gini Index", grid = "sparse")
# Use the Anchorpoint object to get the graphical test
graphicalTest(ap_object)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.