Skip to contents

This function will create publication worthy Item Response Theory based Test information plot using ggplot2 from objects created from mirt pack. Using ggplot2 will enable the user to modify the Item plot.

Usage

ggtestinfo(dataframe, model)

Arguments

dataframe

your data.

model

A mirt package fitted object.

Value

A publication quality Test information plot. Output object is a ggplot object.

Examples

data <- tabledown::Rotter[, 11:31]
model <- mirt::mirt(data, model = 1, itemtype = '2PL')
#> 
Iteration: 1, Log-Lik: -5444.747, Max-Change: 0.56424
Iteration: 2, Log-Lik: -5374.008, Max-Change: 0.30858
Iteration: 3, Log-Lik: -5357.722, Max-Change: 0.17532
Iteration: 4, Log-Lik: -5353.406, Max-Change: 0.09162
Iteration: 5, Log-Lik: -5352.045, Max-Change: 0.06068
Iteration: 6, Log-Lik: -5351.603, Max-Change: 0.03828
Iteration: 7, Log-Lik: -5351.412, Max-Change: 0.01627
Iteration: 8, Log-Lik: -5351.383, Max-Change: 0.01187
Iteration: 9, Log-Lik: -5351.371, Max-Change: 0.00751
Iteration: 10, Log-Lik: -5351.365, Max-Change: 0.00390
Iteration: 11, Log-Lik: -5351.364, Max-Change: 0.00344
Iteration: 12, Log-Lik: -5351.363, Max-Change: 0.00026
Iteration: 13, Log-Lik: -5351.363, Max-Change: 0.00024
Iteration: 14, Log-Lik: -5351.363, Max-Change: 0.00109
Iteration: 15, Log-Lik: -5351.363, Max-Change: 0.00081
Iteration: 16, Log-Lik: -5351.363, Max-Change: 0.00031
Iteration: 17, Log-Lik: -5351.363, Max-Change: 0.00011
Iteration: 18, Log-Lik: -5351.363, Max-Change: 0.00054
Iteration: 19, Log-Lik: -5351.363, Max-Change: 0.00012
Iteration: 20, Log-Lik: -5351.363, Max-Change: 0.00035
Iteration: 21, Log-Lik: -5351.363, Max-Change: 0.00010

plot <- ggtestinfo(data, model)