% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/unsupervised-validation.R
\name{calc_validation_metrics}
\alias{calc_validation_metrics}
\title{Calculate Cluster Validation Metrics}
\usage{
calc_validation_metrics(clusters, data = NULL, dist_mat = NULL)
}
\arguments{
\item{clusters}{Vector of cluster assignments}

\item{data}{Original data frame (for WSS calculation)}

\item{dist_mat}{Distance matrix (for silhouette)}
}
\value{
A single-row tibble with columns \code{k}, \code{min_size},
\code{max_size}, \code{avg_size}, and optionally \code{avg_silhouette},
\code{min_silhouette} (if \code{dist_mat} provided), and \code{total_wss}
(if \code{data} provided).
}
\description{
Comprehensive validation metrics for a clustering result
}
\examples{
\donttest{
km <- kmeans(iris[, 1:4], centers = 3, nstart = 25)
d <- dist(iris[, 1:4])
metrics <- calc_validation_metrics(km$cluster, iris[, 1:4], d)
}

}
