StatsCalculators.com

Games-Howell Test

Created:January 25, 2025
Last Updated:January 25, 2025

This calculator performs the Games-Howell post-hoc test, a robust alternative to Tukey's HSD when your data violates the assumption of equal variances (homogeneity of variance). Unlike Tukey's HSD, the Games-Howell test doesn't require equal variances or equal sample sizes, making it ideal for real-world data where these conditions are rarely perfectly met.

What You'll Get:

  • Complete Pairwise Analysis: Every possible group comparison with adjusted p-values and confidence intervals
  • ANOVA Integration: Welch's ANOVA results (robust to unequal variances) plus detailed post-hoc comparisons
  • Effect Size Metrics: Cohen's d for each comparison to assess practical significance
  • Visual Insights: Significance matrix, group comparison charts, and distribution plots
  • Assumption Validation: Comprehensive normality and variance equality testing
  • Professional Reporting: APA-formatted results ready for publication

💡 When to Use Games-Howell: Use this test when Levene's test or similar variance tests indicate unequal variances across groups. If variances are equal, use ourTukey's HSD Test Calculatorinstead for slightly more power. The Games-Howell test is particularly valuable when group sizes are unequal.

Ready to analyze your groups with unequal variances? Load long format sample or load wide format sample to see how it works, or upload your own data to discover which groups truly differ.

Calculator

1. Load Your Data

2. Select Data Format & Options

Related Calculators

Learn More

Games-Howell Test

Definition

The Games-Howell Test is a post-hoc test used after ANOVA to determine which specific groups differ from each other when the assumption of equal variances is violated. It's particularly robust when group sizes are unequal and doesn't require equal variances across groups.

When to Use Games-Howell vs Tukey's HSD

Use Games-Howell when: Levene's test or similar variance tests indicate unequal variances (heteroscedasticity), or when group sizes are unequal
Use Tukey's HSD when: Variances are equal across groups (homoscedasticity) and preferably when sample sizes are equal

Formula

Test Statistic:

t=xˉi−xˉjsi2ni+sj2njt = \frac{\bar{x}_i - \bar{x}_j}{\sqrt{\frac{s_i^2}{n_i} + \frac{s_j^2}{n_j}}}

Where:

  • xˉi,xˉj\bar{x}_i, \bar{x}_j = means of groups i and j
  • si2,sj2s_i^2, s_j^2 = variances of groups i and j
  • ni,njn_i, n_j = sample sizes of groups i and j

Degrees of Freedom (Welch-Satterthwaite):

df=(si2ni+sj2nj)2(si2/ni)2ni−1+(sj2/nj)2nj−1df = \frac{\left(\frac{s_i^2}{n_i} + \frac{s_j^2}{n_j}\right)^2}{\frac{(s_i^2/n_i)^2}{n_i-1} + \frac{(s_j^2/n_j)^2}{n_j-1}}

Key Assumptions

Independence: Observations must be independent
Normality: Data within each group should be approximately normally distributed
No assumption of equal variances: This is the key advantage over Tukey's HSD - variances can be unequal
No assumption of equal sample sizes: Groups can have different sample sizes

Advantages of Games-Howell

  • Robust to Unequal Variances: Maintains correct Type I error rates even when variances differ substantially
  • Flexible Sample Sizes: Works well with unequal group sizes, unlike Tukey's HSD which assumes equal n
  • Conservative: Generally provides good control of familywise error rate

How to perform Games-Howell Test in R

Use games_howell_test() function from rstatix package or oneway() from userfriendlyscience package.

R
library(tidyverse)
library(rstatix)

# sample data with unequal variances
data <- tibble(
  group = rep(c("A", "B", "C"), each = 10),
  values = c(
    rnorm(10, mean = 25, sd = 3),  # Group A: small variance
    rnorm(10, mean = 50, sd = 2),  # Group B: large variance
    rnorm(10, mean = 32, sd = 5)   # Group C: medium variance
  )
) |>
  mutate(group = as.factor(group))

# Check for homogeneity of variance (should be violated for Games-Howell)
car::leveneTest(values ~ group, data = data)

games_howell_test(data, values ~ group)

How to perform Games-Howell Test in Python

Use posthoc_gameshowell() function from scikit_posthocs package.

Python
import pandas as pd
import numpy as np
from scipy import stats
from scikit_posthocs import posthoc_gameshowell

# Sample data with unequal variances
np.random.seed(42)
group_A = np.random.normal(25, 3, 10)   # Small variance
group_B = np.random.normal(40, 8, 10)   # Large variance
group_C = np.random.normal(32, 5, 10)   # Medium variance

# Create DataFrame
data = pd.DataFrame({
    'values': np.concatenate([group_A, group_B, group_C]),
    'group': ['A']*10 + ['B']*10 + ['C']*10
})

# Check for homogeneity of variance (should be violated)
from scipy.stats import levene
stat, p = levene(group_A, group_B, group_C)
print(f"Levene's test: W = {stat:.4f}, p = {p:.4f}")

# Perform Games-Howell test
gh_result = posthoc_gameshowell(data, val_col='values', group_col='group')
print("\nGames-Howell Test Results:")
print(gh_result)

Verification