% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/sim.data.FCDCM.R
\name{sim.data.FCDCM}
\alias{sim.data.FCDCM}
\title{Simulate Data from the Forced-Choice DCM Model}
\usage{
sim.data.FCDCM(
  N.person = 1000,
  N.block = 10,
  D = 3,
  dcm.type = "DINA",
  control = NULL
)
}
\arguments{
\item{N.person}{Integer; number of persons (default: 1000).}

\item{N.block}{Integer; number of forced-choice block pairs (default: 10).}

\item{D}{Integer; number of attributes (default: 3, must be >= 2).}

\item{dcm.type}{Character; \code{"DINA"} (default) or \code{"DINO"}.}

\item{control}{Optional list with entries \code{Q.matrix}, \code{block.items},
\code{single}, \code{delta1}, \code{delta0},
\code{theta}, \code{alpha}, \code{par}.  If \code{block.items} is
omitted, statements are assembled into cross-Q-vector forced-choice
blocks with balanced first/second positions and diversified attribute
pairs.  \code{par} is a \eqn{B \times 2} matrix with columns
\code{eta0} and \code{etaAB}.}
}
\value{
An object of class \code{"data.FCDCM"} containing \code{data},
\code{response}, \code{theta}, \code{alpha}, \code{zeta}, \code{par},
\code{Q.matrix}, \code{block.items},
\code{prob}, and data-generating arguments.
}
\description{
Generates forced-choice paired-comparison data from a higher-order
cognitive diagnostic model (DINA/DINO). The continuous higher-order
trait governs attribute mastery probabilities via a logistic link;
two-statement blocks produce binary choices based on attribute
mastery patterns. In each block, selecting the first statement has
probability \eqn{\eta_0} when its condensed mastery is lower than the
second statement's, \eqn{0.5} when they are equal, and
\eqn{0.5+\eta_{AB}} when it is higher.
}
\examples{
set.seed(123)
sim <- sim.data.FCDCM(N.person = 20, N.block = 3, D = 2,
                      dcm.type = "DINA")
str(sim$data)
head(sim$response)
head(sim$alpha)

}
\seealso{
\code{\link{fit.FCDCM}}, \code{\link{model.FCDCM}}
}
