summary | R Documentation |
Generate concise summary statistics for objects created by the Qval package. The output is a named list tailored to the class of the input:
CDM
contains the original call, dataset dimensions, model fit object, and attribute-pattern distribution.
validation
contains the original call, suggested Q-matrix, and original Q-matrix.
sim.data
contains the original call, dataset dimensions, and attribute-pattern distribution.
fit
contains the original call, relative fit indices and absolute fit indices.
## S3 method for class 'CDM'
summary(object, ...)
## S3 method for class 'validation'
summary(object, ...)
## S3 method for class 'sim.data'
summary(object, ...)
## S3 method for class 'fit'
summary(object, ...)
object |
An object of class |
... |
Currently unused. Additional arguments are ignored. |
A string capturing the original function invocation.
A numeric vector c(N, I, K)
giving the number of examinees (N
),
the number of items (I
), and the number of attributes (K
).
(CDM only) The fitted model object returned by CDM
.
(CDM and sim.data) A data.frame of frequencies (freq
) and proportions
(prop
) of each attribute pattern.
(validation only) Suggested Q-matrix from validation
.
(validation only) Original Q-matrix provided by sim.data
.
(fit only) Relative fit indices provided by fit
.
(fit only) Absolute fit indices provided by fit
.
A named list with class summary.<class>
containing the components above.
summary(CDM)
: Summary method for CDM objects
summary(validation)
: Summary method for validation objects
summary(sim.data)
: Summary method for sim.data objects
summary(fit)
: Summary method for fit objects
set.seed(123)
library(Qval)
################################################################
# Example 1: summary a CDM object #
################################################################
Q <- sim.Q(3, 20)
IQ <- list(P0 = runif(20, 0, 0.2), P1 = runif(20, 0.8, 1))
data.obj <- sim.data(Q, N = 500, IQ = IQ,
model = "GDINA", distribute = "horder")
CDM.obj <- CDM(data.obj$dat, Q, model = "GDINA", method = "EM")
summary(CDM.obj)
################################################################
# Example 2: summary a validation object #
################################################################
MQ <- sim.MQ(Q, 0.1)
CDM.obj2 <- CDM(data.obj$dat, MQ)
val.obj <- validation(data.obj$dat, MQ, CDM.obj2, method = "GDI")
summary(val.obj)
################################################################
# Example 3: summary a sim.data object #
################################################################
data.obj2 <- sim.data(Q = sim.Q(3, 10), N = 1000)
summary(data.obj2)
################################################################
# Example 4: summary a fit object #
################################################################
fit.obj <- fit(data.obj$dat, Q, model="GDINA")
summary(fit.obj)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.