% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/stop-strategy.R
\name{stop_max_depth}
\alias{stop_max_depth}
\title{Maximum-depth stopping rule.}
\usage{
stop_max_depth(max_depth)
}
\arguments{
\item{max_depth}{Maximum depth (non-negative integer; 0 produces a
root-only stump).}
}
\value{
A \code{stop_strategy} object.
}
\description{
Creates a stopping rule that stops splitting when a node's depth reaches
\code{max_depth}. Depth is zero-based at the root, so \code{max_depth(k)}
allows at most \code{k + 1} levels. Mode-agnostic: useful for bounding
tree complexity in both classification and regression trees.
}
\examples{
stop_max_depth(5)

}
\seealso{
\code{\link{stop_min_size}}, \code{\link{stop_any}}
}
