% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/vars-strategy.R
\name{vars_uniform}
\alias{vars_uniform}
\title{Uniform random variable selection strategy.}
\usage{
vars_uniform(n_vars = NULL, p_vars = NULL)
}
\arguments{
\item{n_vars}{The number of variables to consider at each split (integer).
Cannot be used together with \code{p_vars}.}

\item{p_vars}{The proportion of variables to consider at each split
(number between 0 and 1, exclusive). Resolved to an integer count when
the number of features is known. Cannot be used together with \code{n_vars}.}
}
\value{
A \code{vars_strategy} object.
}
\description{
Creates a variable selection strategy that randomly selects a subset
of variables at each split. Used with \code{\link{pprf}} for random forests.
}
\details{
Exactly one of \code{n_vars} or \code{p_vars} may be specified. When
\code{p_vars} is used, it is stored as-is and resolved to an integer count
later by \code{\link{pprf}} once the number of features is known.
}
\examples{
# Select 2 variables at each split
vars_uniform(n_vars = 2)

# Select half the variables at each split
vars_uniform(p_vars = 0.5)

# Use with pprf
pprf(Species ~ ., data = iris, vars = vars_uniform(n_vars = 2))

}
\seealso{
\code{\link{pprf}}, \code{\link{vars_all}}, \code{\link{pp_pda}}, \code{\link{cutpoint_mean_of_means}}
}
