% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/longitree.R
\name{selectionplot}
\alias{selectionplot}
\title{Select Optimal Three-Tree Combination}
\usage{
selectionplot(longitrees, metric, nth)
}
\arguments{
\item{longitrees}{A \code{longitrees} object.}

\item{metric}{\code{"PE"} to select the subset with the smallest
cross-validated prediction error, or \code{"ARI"} to select the subset
with the smallest maximum pairwise ARI (greatest tree diversification).}

\item{nth}{Rank of the tree subset to select (1 = best).}
}
\value{
An object of class \code{"selectionplot"}.  Pass to
\code{\link{threetrees}} to refit and evaluate the selected trees.
}
\description{
Plots the cross-validated prediction error against the maximum pairwise
adjusted Rand index (ARI) for candidate three-tree subsets, and selects
a subset based on either prediction performance or tree diversification.
The selected combination is indicated by a red point on the plot, which
corresponds to the three trees used in the subsequent
\code{\link{threetrees}} step.
}
\references{
Obata, R. and Sugimoto, T. (2026). A decision tree analysis for
longitudinal measurement data and its applications.
\emph{Advances in Data Analysis and Classification}.
\doi{10.1007/s11634-025-00665-2}
}
\seealso{
\code{\link{longitrees}}, \code{\link{threetrees}}
}
