Checks whether a given Q-matrix satisfies the conditions for strict identifiability and generic identifiability under cognitive diagnosis models (CDMs), including the DINA, DINO, and saturated models, based on theoretical results from Gu & Xu (2021).

This function evaluates both joint strict identifiability and various forms of generic identifiability, including global and local cases, by verifying structural conditions on the Q-matrix.

is.Qident(Q, verbose = TRUE)

Arguments

Q

An \(I \times K\) binary Q-matrix (matrix or data.frame), where each row represents an item and each column an attribute. Entries indicate whether an attribute is required (1) or not (0).

verbose

Logical; if TRUE, prints warning messages during checking process (e.g., insufficient items, missing patterns).

Value

An object of class "is.Qident" — a list containing:

Q.orig

Original input Q-matrix.

Q.reconstructed

Reconstructed Q-matrix sorted by attribute pattern.

arguments

A list containing all input arguments

strictIdentifiability.obj

Results of checking Joint Strict Identifiability under DINA/DINO. Contains:

  • completeness: TRUE if \(K \times K\) identity submatrix exists.

  • distinctness: TRUE if remaining columns are distinct.

  • repetition: TRUE if every attribute appears more than 3 items.

All three must be TRUE for joint strict identifiability.

genericIdentifiability.obj

Results for Joint Generic Identifiability under saturated models. Includes:

  • genericCompleteness: TRUE if two different generic complete \(K \times K\) submatrices exist.

  • genericRepetition: TRUE if at least one '1' exists outside those submatrices.

  • Q1, Q2: Identified generic complete submatrices (if found).

  • Q.star: Remaining part after removing rows in Q1 and Q2.

Both genericCompleteness and genericRepetition must be TRUE.

genericIdentifiability.DINA.obj

Results for Joint Generic Identifiability under DINA/DINO. Includes:

  • locallyGenericIdentifiability: TRUE if local generic identifiability holds.

  • globallyGenericIdentifiability: TRUE if global generic identifiability holds.

  • Q.reconstructed.DINA: Reconstructed Q-matrix with low-frequency attribute moved to first column.

Details

The identifiability of the Q-matrix is essential for valid parameter estimation in CDMs. According to Gu & Xu (2021), identifiability can be categorized into:

Joint Strict Identifiability

Ensures that both the Q-matrix and model parameters can be uniquely determined from the data, currently only applicable under DINA or DINO models. Requires three conditions:

  • Completeness (A): The Q-matrix contains a \(K \times K\) identity submatrix (after row/column permutations).

  • Distinctness (B): All columns of the remaining part (excluding the identity block) are distinct.

  • Repetition (C): Each attribute appears in at least three items (i.e., column sums \(\geq 3\)).

Joint Generic Identifiability (DINA/DINO)

Means uniqueness holds for "almost all" parameter values (except on a set of measure zero). Applies when exactly one attribute has precisely two non-zero entries. The Q-matrix must have the structure: \(\mathbf{Q} = \begin{pmatrix} 1 & \mathbf{0}^\top \\ 1 & \mathbf{v}^\top \\ \mathbf{0} & \mathbf{Q}^* \end{pmatrix}\). Then:

  • If \(\mathbf{v} = \mathbf{0}\), then \(\mathbf{Q}^*\) must satisfy either: (i) Joint Strict Identifiability, or (ii) contain at least two identity submatrices → Globally generically identifiable.

  • If \(\mathbf{v} \neq \mathbf{0}, \mathbf{1}\), then \(\mathbf{Q}^*\) must satisfy Joint Strict Identifiability → Locally generically identifiable.

Joint Generic Identifiability (Saturated Model)

For general saturated models, requires:

  • Generic Completeness (D): Two different \(K \times K\) submatrices exist, each having full rank and containing diagonal ones after permutation (indicating sufficient independent measurement of attributes).

  • Generic Repetition (E): At least one '1' exists outside these two submatrices.

This function first reconstructs the Q-matrix into standard form, then checks each condition accordingly.

References

Gu, Y., & Xu, G. (2021). Sufficient and necessary conditions for the identifiability of the Q-matrix. Statistica Sinica, 31, 449–472. https://www.jstor.org/stable/26969691

Author

Haijiang Qin <Haijiang133@outlook.com>

Examples

library(Qval)
set.seed(123)

# Simulate a 5-attribute, 20-item Q-matrix
Q <- sim.Q(5, 20)

# Check identifiability
result <- is.Qident(Q, verbose = TRUE)

# View summary
print(result)
#> Qval version 1.2.4 (2025-11-20) 
#> ==============================
#> Under DINA or DINO model:
#>      Completeness: TRUE 
#>      Distinctness: TRUE 
#>      Repetition:   TRUE 
#>   therefore, the Q-matrix is Joint Strict Identifiability.
#> ==============================
#> Under DINA or DINO model:
#>      Locally Generic Completeness: TRUE 
#>      Globally Generic Repetition:  TRUE 
#>   therefore, the Q-matrix is Globally Generic Identifiability.
#> ==============================
#> Under saturated model:
#>      Generic Completeness: TRUE 
#>      Generic Repetition:   TRUE 
#>   therefore, the Q-matrix is Joint Generic Identifiability.