pattern {DAKS} | R Documentation |
Frequencies of Response Patterns and Knowledge States
Description
pattern
computes the absolute frequencies of the (occurring)
response patterns, and optionally, the absolute frequencies of a
collection of specified knowledge states in a dataset.
Usage
pattern(dataset, n = 5, P = NULL)
Arguments
dataset |
a required data frame or matrix consisting of binary,
|
n |
an optional numeric, with default |
P |
an optional matrix of ones and zeros giving the knowledge
states to be used. The default |
Details
This function can be used to retrieve information about how often
response patterns and knowledge states occur in a dataset. The
argument n
refers to response patterns, not knowledge states,
and in particular is independent of specifications of the argument
P
. If pattern
is called without specifying n
explicitly, the response patterns with the five highest frequencies
are returned (along with their frequencies). If n
is
specified, the response patterns with the n
highest
frequencies are returned (along with their frequencies). If n
is larger than the number of different response patterns in the
dataset, n
is set the number of different response patterns.
The knowledge states are represented as 1
/0
-patterns and
are the rows of the argument matrix P
. The matrix P
must contain only ones and zeros, which encode whether or not an
item belongs to a knowledge state, respectively. If P
is not
specified, pattern
only returns information about response
patterns (as described previously).
The data must contain only ones and zeros, which encode solving or failing to solve an item, respectively.
Value
If the arguments dataset
, n
, and P
are of
required types, pattern
returns a named list consisting of
the following three components:
response.patterns |
an array giving the response patterns (with
the |
states |
a matrix of the knowledge states and their absolute
frequencies in |
n |
a numeric giving the number of response patterns that are returned. |
Note
Although pattern
is intended for use with dichotomous data, it
also works with polytomously scored items.
Author(s)
Anatol Sargin, Ali Uenlue
References
Sargin, A. and Uenlue, A. (2009) Inductive item tree analysis: Corrections, improvements, and comparisons. Mathematical Social Sciences, 58, 376–392.
Uenlue, A. and Sargin, A. (2010) DAKS: An R package for data analysis methods in knowledge space theory. Journal of Statistical Software, 37(2), 1–31. URL http://www.jstatsoft.org/v37/i02/.
See Also
ob_counter
for computation of numbers of
counterexamples; simu
for data simulation tool;
iita
, the interface that provides the three inductive
item tree analysis methods under one umbrella. See also
DAKS-package
for general information about this
package.
Examples
pattern(pisa, n = 3)
pattern(pisa)