% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/games.howell.R
\name{games.howell}
\alias{games.howell}
\title{Games-Howell Post-Hoc Test}
\usage{
games.howell(samples, groups, conf.level = 0.95)
}
\arguments{
\item{samples}{Numeric vector; the dependent variable.}

\item{groups}{Factor or vector; the grouping variable.}

\item{conf.level}{Numeric; confidence level for confidence intervals (default: 0.95).}
}
\value{
A data frame with columns:
\describe{
  \item{group1}{First group in comparison}
  \item{group2}{Second group in comparison}
  \item{mean_diff}{Difference in means (group1 - group2)}
  \item{se}{Standard error of the difference}
  \item{t}{t-statistic}
  \item{df}{Degrees of freedom (Welch-Satterthwaite)}
  \item{p_value}{Unadjusted p-value}
  \item{p_adj}{Holm-adjusted p-value for multiple comparisons}
  \item{ci_lower}{Lower bound of confidence interval}
  \item{ci_upper}{Upper bound of confidence interval}
  \item{significant}{Logical; TRUE if p_adj < (1 - conf.level)}
}
}
\description{
Performs pairwise comparisons using the Games-Howell test, which does not
assume equal variances or equal sample sizes. This is the appropriate
post-hoc test to use after a significant Welch's ANOVA.
}
\details{
The Games-Howell test uses the Welch-Satterthwaite approximation for
degrees of freedom and does not pool variances. P-values are adjusted
using the Holm method to control family-wise error rate.
}
\examples{
# Convert dose to factor
ToothGrowth$dose <- as.factor(ToothGrowth$dose)

# Perform Games-Howell test
result <- games.howell(ToothGrowth$len, ToothGrowth$dose)
print(result)

}
