% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/datasets.R
\name{load_mfrmr_data}
\alias{load_mfrmr_data}
\title{Load a packaged simulation dataset}
\usage{
load_mfrmr_data(
  name = c("example_core", "example_bias", "study1", "study2", "combined",
    "study1_itercal", "study2_itercal", "combined_itercal")
)
}
\arguments{
\item{name}{Dataset key. One of values from \code{\link[=list_mfrmr_data]{list_mfrmr_data()}}.}
}
\value{
A data.frame in long format.
}
\description{
Load a packaged simulation dataset
}
\details{
\code{load_mfrmr_data("<key>")} is the canonical loader for the packaged
datasets and the entry point used across the package help and
vignettes. The equivalent base-R alternative
\code{data("mfrmr_<key>", package = "mfrmr")} remains available for users
who prefer the full \code{data()} spelling; both paths return identical
long-format data frames and are supported long-term.

All returned datasets include the core long-format columns
\code{Study}, \code{Person}, \code{Rater}, \code{Criterion}, and \code{Score}.
Some datasets, such as the packaged documentation examples, also include
auxiliary variables like \code{Group} for DIF/bias demonstrations.
}
\section{Interpreting output}{

The return value is a plain long-format \code{data.frame}, ready for direct use
in \code{\link[=fit_mfrm]{fit_mfrm()}} without additional reshaping.
}

\section{Typical workflow}{

\enumerate{
\item list valid names with \code{\link[=list_mfrmr_data]{list_mfrmr_data()}}.
\item load one dataset key with \code{load_mfrmr_data(name)}.
\item fit a model with \code{\link[=fit_mfrm]{fit_mfrm()}} and inspect with \code{summary()} / \code{plot()}.
}
}

\examples{
data("mfrmr_example_core", package = "mfrmr")
head(mfrmr_example_core)

d <- load_mfrmr_data("example_core")
fit <- fit_mfrm(
  data = d,
  person = "Person",
  facets = c("Rater", "Criterion"),
  score = "Score",
  method = "JML",
  maxit = 30
)
summary(fit)
}
\seealso{
\code{\link[=list_mfrmr_data]{list_mfrmr_data()}}, \link{ej2021_data}
}
