getScoreAttributes: Retrieve constraints-related scores from solution

View source: R/constraint_functions.R

getScoreAttributesR Documentation

Retrieve constraints-related scores from solution

Description

getScoreAttributes is a helper function for retrieving constraints-related scores from a solution.

Usage

getScoreAttributes(constraints, item_idx, item_resp, item_ncat)

Arguments

constraints

a constraints object.

item_idx

item indices from a solution.

item_resp

item scores for item_idx.

item_ncat

number of score categories for item_idx.

Examples

item_idx <-
  c( 29,  33,  26,  36,  34,
    295, 289, 296, 291, 126,
    133, 124, 134, 129,  38,
     47,  39,  41,  46,  45,
    167, 166, 170, 168, 113,
    116, 119, 117, 118, 114)

item_resp <-
  c( 1, 0, 1, 1, 0,
     0, 1, 1, 0, 0,
     1, 0, 1, 0, 1,
     1, 1, 1, 0, 1,
     0, 1, 1, 1, 1,
     1, 0, 1, 0, 1)

item_ncat <-
  c( 2, 2, 2, 2, 2,
     2, 2, 2, 2, 2,
     2, 2, 2, 2, 2,
     2, 2, 2, 2, 2,
     2, 2, 2, 2, 2,
     2, 2, 2, 2, 2)

getScoreAttributes(constraints_reading, item_idx, item_resp, item_ncat)


TestDesign documentation built on Sept. 11, 2024, 7:12 p.m.