probs.GGUM: Compute model probabilities for the GGUM

View source: R/IRT_models.R

probs.GGUMR Documentation

Compute model probabilities for the GGUM

Description

probs.GGUM computes model probabilities for the GGUM (and the GUM) for given item and person parameters.

Usage

probs.GGUM(alpha, delta, taus, theta, C)

Arguments

alpha

A vector of length I with the discrimination parameters.

delta

A vector of length I with the difficulty parameters.

taus

An I\times M matrix with the threshold parameters (M = 2\times\max{C}+1).

theta

A vector of length N with the person parameters.

C

C is the number of observable response categories minus 1 (i.e., the item scores will be in the set \{0, 1, ..., C\}). It should either be a vector of I elements or a scalar. In the latter case, it is assumed that C applies to all items.

Value

The function returns an N\times I\times K array with the GGUM probabilities, with K=\max{C}+1. To retrieve the GUM-based probabilities just constrain alpha to a unit vector of length I (i.e., alpha = rep(1, I)). In this case, make sure C is constant across items.

Details

This function computes the GGUM-based probabilities for all (person, item, response category) combinations. For the GGUM formula see the help for function GGUM (GGUM).

Author(s)

Jorge N. Tendeiro, tendeiro@hiroshima-u.ac.jp

Examples

C <- c(3, 3, 3, 5, 5)
gen <- GenData.GGUM(10, 5, C, seed = 456)
gen.alpha <- gen$alpha.gen
gen.delta <- gen$delta.gen
gen.taus  <- gen$taus.gen
gen.theta <- gen$theta.gen
 
# Compute model probabilities for the parameters above:
Ps <- probs.GGUM(gen.alpha, gen.delta, gen.taus, gen.theta, C)
Ps
# In particular, the sum of the probabilities across all response options 
# (i.e., the third dimension) should be 1 for all (person, item) combinations:
apply(Ps, 1:2, sum)

GGUM documentation built on Sept. 8, 2023, 5:38 p.m.