HYPOTHESIS TESTING

ANOVA (Analysis of Variance)

One-way ANOVA only with Tukey HSD post-hoc, Levene's test, Shapiro-Wilk by group, eta squared, Cohen's f, and post-hoc power analysis using pwr package.

What Makes This Powerful

Comprehensive Assumptions

Levene's test (car package) for variance homogeneity. Shapiro-Wilk test run separately for each group. Q-Q plot data for residual normality check.

Effect Size & Power

Eta squared (SS_between/SS_total), Cohen's f calculated from eta squared. Post-hoc power analysis using pwr.anova.test with minimum group size.

Tukey HSD Only

Fixed post-hoc method using TukeyHSD function. Pairwise comparisons with diff, lower/upper CI, and adjusted p-values. No other post-hoc methods available.

What You Need to Provide

One-way ANOVA dataset

Provide response (numeric) and group (categorical) columns. Group automatically converted to factor. Covariates parameter ignored (not implemented).

Algorithm uses aov() function, calculates eta squared and Cohen's f, runs Tukey HSD automatically, performs Levene's and Shapiro-Wilk tests, generates residual diagnostics and confidence intervals using t-distribution.

Schema Preview / response, factor[, factor2]

Quick Specs

DesignOne-way only
Post-hocTukey HSD fixed
Packagescar, pwr required
PowerPost-hoc calculation

How We Test and Explain

From checks to post‑hoc clarity

1

Run ANOVA

Convert group to factor, run aov() for one-way ANOVA, extract F-statistic and p-value from summary. Calculate eta squared as SS_between/SS_total.

2

Test Assumptions

Levene's test using car::leveneTest, Shapiro-Wilk test per group, generate Q-Q plot data for residuals, calculate standardized residuals.

3

Post-hoc & Power

Run TukeyHSD for all pairwise comparisons, calculate Cohen's f from eta squared, perform power analysis with pwr.anova.test using minimum group size.

Why This Analysis Matters

One-way ANOVA implementation with comprehensive diagnostics, effect sizes, and automatic Tukey HSD post-hoc comparisons.

Provides F-statistic, eta squared, Cohen's f, and post-hoc power analysis. Includes Levene's test for homogeneity, Shapiro-Wilk per group for normality, and complete residual diagnostics. Group statistics with means, SD, SE, and 95% confidence intervals.

Note: One-way ANOVA only (no two-way or ANCOVA). Post-hoc method fixed to Tukey HSD. No alternatives if assumptions fail. Requires car and pwr packages. Power calculated post-hoc, not a priori.

Ready to Compare Groups?

Test differences with clear, reliable conclusions

Read the article: ANOVA