apply_missing: Apply Missing Data Mechanism (Internal)

View source: R/apply_missing.R

apply_missingR Documentation

Apply Missing Data Mechanism (Internal)

Description

Takes a complete response matrix and introduces missingness according to the study specification.

Usage

apply_missing(data, study, seed = NULL, theta = NULL)

Arguments

data

Numeric matrix (N x n_items). Complete response data.

study

An irt_study object specifying the missing data mechanism.

seed

Integer. Random seed for reproducibility.

theta

Optional numeric vector of length nrow(data). Required when study$missing == "mar".

Value

Numeric matrix of same dimensions as data, with NA values introduced according to the missingness mechanism.


irtsim documentation built on April 24, 2026, 1:07 a.m.