plot {lsirm12pl}R Documentation

Plotting the interaction map or summarizing the parameter estimate of fitted LSIRM with box plot.

Description

plot is used to plot the interaction map of fitted LSIRM or summarizing the parameter estimate of fitted LSIRM with box plot.

Usage

plot(
  object,
  ...,
  option = "interaction",
  rotation = FALSE,
  cluster = NA,
  which.clust = "item",
  interact = FALSE,
  chain.idx = 1
)

Arguments

object

Object of class lsirm.

...

Additional arguments for the corresponding function.

option

Character; If value is "interaction", draw the interaction map that represents interactions between respondents and items. If value is "beta", draw the boxplot for the posterior samples of beta. If value is "theta", draw the distribution of the theta estimates per total test score for the data. If value is "alpha", draw the boxplot for the posterior samples of alpha. The "alpha" is only available for 2PL LSIRM.

rotation

Logical; If TRUE the latent positions are visualized after oblique (oblimin) rotation.

cluster

Character; If value is "neyman" the cluster result are visualized by Point Process Cluster Analysis. If value is "spectral", spectral clustering method applied. Default is NA.

which.clust

Character; Choose which values to clustering. "resp" is the option for respondent and "item" is the option for items. Default is "item".

interact

Logical; If TRUE, draw the interaction map interactively.

chain.idx

Numeric; Index of MCMC chain. Default is 1.

Value

plot returns the interaction map or boxplot for parameter estimate.

Examples



# generate example item response matrix
data     <- matrix(rbinom(500, size = 1, prob = 0.5), ncol=10, nrow=50)
lsirm_result <- lsirm(data ~ lsirm1pl())
plot(lsirm_result)

# use oblique rotation
plot(lsirm_result, rotation = TRUE)

# interaction map interactively
plot(lsirm_result, interact = TRUE)

# clustering the respondents or items
plot(lsirm_result, cluster = TRUE)


[Package lsirm12pl version 1.3.2 Index]