% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/stats_cv_sets_methods.R
\name{.mcBalanced}
\alias{.mcBalanced}
\title{Class-balanced Monte Carlo Cross-Validation (MCCV) splits}
\usage{
.mcBalanced(k, split, stratified)
}
\arguments{
\item{k}{Integer. Number of MCCV training sets to generate.}

\item{split}{Numeric. Fraction of observations per class to include in each training set. Must be between 0 and 1.}

\item{stratified}{List of three elements:
\itemize{
\item{1: } Character. Outcome type: 'R' (regression) or 'DA' (discriminant analysis), optionally with suffix '-mY' for multi-column Y.
\item{2: } Matrix. Response matrix \code{Y}, with \code{ncol(Y) == 1}.
\item{3: } Numeric vector of probabilities used to stratify numeric Y if regression.
}}
}
\value{
A list of length \code{k}, each element containing a vector of row indices for the training set.
}
\description{
Generates class/group-balanced training set indices for each MCCV round.
}
\details{
Each round samples a class-balanced subset without replacement. Useful for high-variance, imbalanced-class modeling.
}
\keyword{internal}
