coef-BlisClass-method: Get Coefficients from a fitted BLIS model

coef,BlisClass-methodR Documentation

Get Coefficients from a fitted BLIS model

Description

Extracts item parameters from fitted BLIS model. For BLIRT parametrization, use IRTpars = TRUE in your function call. Contrary to coef,SingleGroupClass-method, response category labels can be displayed in the output using labels = TRUE. On top of that, as BLIS/BLIRT parametrizations utilize the information of correct response category, you can denote these in the output with mark_correct = TRUE.

Usage

## S4 method for signature 'BlisClass'
coef(
  object,
  ...,
  CI = 0.95,
  printSE = FALSE,
  IRTpars = FALSE,
  simplify = FALSE,
  labels = FALSE,
  mark_correct = labels
)

Arguments

object

object of class BlisClass, model fitted via fit_blis() or blis().

...

Additional arguments. Not utilized at the moment.

CI

numeric, a width of the confidence intervals.

printSE

logical, print standard errors instead of CI? Defaults to FALSE.

IRTpars

logical, convert slope intercept parameters into IRT parameters (i.e. BLIRT)? Defaults to FALSE.

simplify

logical, return coefficients as a matrix, instead of list? Defaults to FALSE. Not implemented yet.

labels

logical, if TRUE, show response labels (e.g. "A", "B", "C") instead of response numeric indices (e.g. 0, 1, 2). Defaults to FALSE.

mark_correct

logical, mark the correct response with an asterisk symbol. Applicable only if labels is TRUE (in which case, mark_correct defaults to TRUE).

Value

List of item coefficients of S3 class blis_coefs, so the resulting output of coef() call is formatted to display only first 3 digits (you can opt for different rounding via the print.blis_coefs method, see the examples). Note that the list-object returned invisibly has the raw coefficients stored in it.

See Also

Other BLIS/BLIRT related: BlisClass-class, fit_blis(), get_orig_levels(), nominal_to_int(), obtain_nrm_def(), print.blis_coefs()

Examples

fitted_blis <- fit_blis(HCItest[, 1:20], HCIkey)

# BLIS coefs
coef(fitted_blis)

# BLIRT coefs
coef(fitted_blis, IRTpars = TRUE)

# store raw coefs
blis_coefs <- coef(fitted_blis)

# print coefs rounded to 2 digits
print(blis_coefs, digits = 2)


patriciamar/ShinyItemAnalysis documentation built on April 25, 2024, 5:15 a.m.