wizirt: Estimate an IRT model

Description Usage Arguments Value Examples

View source: R/parsnip_style_functions.R

Description

Estimate an IRT model using various engines

Usage

1
2
3
4
5
6
7
8
wizirt(
  data,
  rownames = NULL,
  item_type = "Rasch",
  engine = "mirt",
  tol = 1e-05,
  abs_fit = T
)

Arguments

data

An Person x Items matrix or dataframe of dichotomous response values (e.g. correct/incorrect). Rows are persons and columns are items, one row per person, one column per item. No other information allowed.

rownames

Optional unique row IDs for the data (i.e. examinee IDs). If omitted, uses 1:nrow(data).

item_type

Character. Must be one of "Rasch", "1PL", "2PL" or "3PL".

engine

Character. Currently supported engines are "mirt" and "ltm" for Rasch, 1PL, 2PL, and 3PL models. "eRm" is supported for Rasch models only.

tol

Numeric. Convergence criterion. Currently only implemented when engine is mirt.

abs_fit

Logical. Should absolute fit statistics be calculated? Increases time for estimation. Currently supported engine is "mirt".

Value

Returns a list of class wizirt. spec is a list of information for the parsnip backend. Printing spec prints a summary of the model run. elapsed contains the time it took the model to run. fit contains the model information:

Examples

1
2
3
4
5
6
7
8
data("responses")
my_model <- wizirt(data = responses[, -1], item_type = "2PL", tol = 1e-4, engine = "mirt")
print(my_model, type = "tech")
print(my_model, type = "desc")
print(my_model, type = "item")
print(my_model, type = "person")
print(my_model, type = "na_item")
anova(my_model)

Pflegermeister/wizirt documentation built on Nov. 22, 2020, 8:27 p.m.