% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/model_layer.R
\name{efa_solution}
\alias{efa_solution}
\title{Estimate an exploratory factor solution}
\usage{
efa_solution(
  data,
  instrument,
  items = NULL,
  scales = NULL,
  nfactors = 1L,
  extraction = c("minres", "pa", "ml"),
  rotation = c("oblimin", "promax", "varimax"),
  min_loading = 0.3,
  cross_loading = 0.3
)
}
\arguments{
\item{data}{A data.frame of responses.}

\item{instrument}{An \code{sframe} object.}

\item{items}{Character vector of item IDs. When \code{NULL}, scale items are used.}

\item{scales}{Optional scale IDs used to select item columns.}

\item{nfactors}{Number of factors.}

\item{extraction}{Extraction method passed to \code{psych::fa()}.}

\item{rotation}{Rotation method passed to \code{psych::fa()}.}

\item{min_loading}{Minimum salient loading.}

\item{cross_loading}{Maximum secondary loading before a warning is raised.}
}
\value{
An object of class \code{sframe_efa_solution}.
}
\description{
Runs \code{psych::fa()} on selected item columns and returns loadings,
communalities, uniqueness, variance summaries, and simple item retention
flags. The \code{psych} package is optional and is only required when this
function is called.
}
