📊 Descriptive Statistics
Variance: s² = Σ(xᵢ − x̄)² / (n − 1)
Std Dev: s = √s²
Skewness: g₁ = [n/((n−1)(n−2))] · Σ[(xᵢ−x̄)/s]³
IQR: Q3 − Q1 (linear interpolation)
📏 Confidence Intervals
t-critical: t* from Student's t-distribution at df = n−1
Margin of Error: E = t* × SE
Confidence Interval: x̄ ± E = [x̄ − E, x̄ + E]
🎯 One-Sample t-Test
Degrees of freedom: df = n − 1
Cohen's d: d = |x̄ − μ₀| / s
p-value from Student's t-distribution
⚖️ Two-Sample t-Test
Compare means of two independent groups (Welch's t-test, unequal variances).
df ≈ (s₁²/n₁ + s₂²/n₂)² / [(s₁²/n₁)²/(n₁−1) + (s₂²/n₂)²/(n₂−1)]
Cohen's d = |x̄₁ − x̄₂| / sₚ where sₚ = √[((n₁−1)s₁² + (n₂−1)s₂²) / (n₁+n₂−2)]
🔗 Paired t-Test
Compare two related measurements (before/after, matched pairs). Enter paired data — each line has two values separated by comma or tab.
Mean difference: d̄ = Σdᵢ / n
SD of differences: s_d = √[Σ(dᵢ − d̄)² / (n−1)]
t = d̄ / (s_d / √n), df = n − 1
Cohen's d = |d̄| / s_d
📊 Test of Independence
Enter a contingency table. Each row on a new line, values separated by commas. Rows = categories of variable 1, columns = categories of variable 2.
χ² = Σ (Oᵢⱼ − Eᵢⱼ)² / Eᵢⱼ
df = (rows − 1)(cols − 1)
Cramér's V = √(χ² / (n × min(rows−1, cols−1)))
🎯 Goodness of Fit
Compare observed frequencies against expected frequencies (or a uniform distribution).
Enter expected counts, or leave blank to assume equal frequencies across categories.
df = k − 1 (k = number of categories)
p-value from χ² distribution
🔬 One-Way ANOVA
Enter group data. Each line: GroupName: value1, value2, ...
At least 2 groups required.
SSwithin = ΣΣ (xᵢⱼ − x̄ⱼ)² — variation within groups
MS = SS / df, F = MSbetween / MSwithin
η² = SSbetween / SStotal (effect size)
Post-hoc: Bonferroni-corrected pairwise t-tests (α / number of comparisons)
📈 Linear Regression & Correlation
Enter paired (x, y) data. One pair per line, separated by comma or tab.
Intercept: b₀ = ȳ − b₁x̄
Correlation: r = Σ(xᵢ−x̄)(yᵢ−ȳ) / √[Σ(xᵢ−x̄)² · Σ(yᵢ−ȳ)²]
R² = r² (proportion of variance explained)
Sₑ = √[Σ(yᵢ−ŷᵢ)² / (n−2)]
📐 Sample Size & Power
Small: 0.2 · Medium: 0.5 · Large: 0.8
where zα/2 = inverse normal CDF at 1−α/2
zβ = inverse normal CDF at power
d = Cohen's d (effect size in std dev units)