plotICC | R Documentation |
Function provides item characteristic plots for each item. To date, only dichotomous 1pl and 2pl models are supported.
plotICC ( resultsObj, defineModelObj, items = NULL, personPar = c("WLE", "EAP", "PV"),
personsPerGroup = 30, pdfFolder = NULL, smooth = 7 )
resultsObj |
The object returned by |
defineModelObj |
The object returned by |
items |
Optional: A vector of items for which the ICC should be plotted. If NULL, ICCs of all items
will be collected in a common pdf. The |
personPar |
Which person parameter should be used for plotting? To mimic the
behavior of the S3 plot method of |
personsPerGroup |
Specifies the number of persons in each interval of the theta scale for dividing the persons in various groups according to mean EAP score. |
pdfFolder |
Optional: A folder with writing access for the pdf file. Necessary only if ICCs for more than one item should be plotted. |
smooth |
Optional: A parameter (integer value) for smoothing the plot. If the number of examinees is high, the
icc plot may become scratchy. |
This function is beta! Use with care...
Sebastian Weirich
data(trends)
# choose only 2010
dat <- trends[which(trends[,"year"] == 2010),]
# choose reading
dat <- dat[which(dat[,"domain"] == "reading"),]
# first reshape the data set into wide format
datW <- reshape2::dcast(dat, idstud~item, value.var="value")
# defining the model: specifying q matrix is not necessary
mod1 <- defineModel(dat=datW, items= -1, id="idstud", software = "tam")
# run the model
run1 <- runModel(mod1)
# get the results
res1 <- getResults(run1)
# plot for one item
plotICC ( resultsObj = res1, defineModelObj = mod1, items = "T04_04")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.