| X type | Y type | Describe with | Test with |
|---|---|---|---|
| Categorical | Categorical | Cross-tab, % & bars | Chi-square test |
| Categorical (2 groups) | Numeric | Group means, box plots | t-test |
| Categorical (3+ groups) | Numeric | Group means, box plots | One-way ANOVA |
| Numeric | Numeric | Scatter plot | Correlation / regression |
| Has toilet | No toilet | Total | |
|---|---|---|---|
| Rural | 320 | 280 | 600 |
| Urban | 340 | 60 | 400 |
| Total | 660 | 340 | 1,000 |
| Has toilet | No toilet | Row total | |
|---|---|---|---|
| Rural | 53% | 47% | 100% |
| Urban | 85% | 15% | 100% |
| Has toilet | No toilet | |
|---|---|---|
| Rural | 48% | 82% |
| Urban | 52% | 18% |
| Column total | 100% | 100% |
| Variable pair | Best plot | Shows |
|---|---|---|
| Numeric × numeric | Scatter plot | Direction, strength, shape |
| Categorical × numeric | Box plot by group | Spread & median per group |
| Categorical × numeric | Grouped / clustered bars | Mean per group |
| Categorical × categorical | Stacked / grouped bars | Shares within groups |
| |r| | Rough strength | What the scatter looks like |
|---|---|---|
| 0.0 – 0.1 | Negligible | Shapeless cloud |
| 0.1 – 0.3 | Weak | Faint tilt |
| 0.3 – 0.5 | Moderate | Clear tilt, wide scatter |
| 0.5 – 0.7 | Strong | Tight tilt |
| 0.7 – 1.0 | Very strong | Near a straight line |
| Pearson r | Spearman ρ | |
|---|---|---|
| Measures | Linear association | Monotonic (rank) association |
| Best data | Numeric, roughly symmetric | Ordinal or skewed numeric |
| Outlier-sensitive? | Yes — one point can swing it | No — uses ranks |
| Range | −1 to +1 | −1 to +1 |
| Groups | Y type | Method |
|---|---|---|
| 2 (independent) | Numeric | Two-sample t-test |
| 2 (same units, paired) | Numeric | Paired t-test |
| 3 or more | Numeric | One-way ANOVA |
| 3+, skewed data | Numeric | Kruskal–Wallis |
| Cell | Observed | Expected | Gap |
|---|---|---|---|
| Rural, toilet | 320 | 396 | −76 |
| Rural, no toilet | 280 | 204 | +76 |
| Urban, toilet | 340 | 264 | +76 |
| Urban, no toilet | 60 | 136 | −76 |
| Step | Tool | Answers |
|---|---|---|
| Describe | Cross-tab + % | What does the pattern look like? |
| Test | Chi-square | Is it bigger than chance? |
| Quantify strength | Cramér's V | How strong is it? |
| Small table? | Fisher's exact | Same question, thin cells |
| Tool | Good for | Note |
|---|---|---|
| Excel / Google Sheets | Cross-tabs, scatter, CORREL, t-test | Start here; pivot tables for cross-tabs |
| R | Every test, publication graphics | Free; cor.test, t.test, aov, chisq.test, lm |
| Python (pandas, scipy, statsmodels) | Cleaning + tests + regression | Free, general-purpose |
| Jamovi / JASP | Point-and-click stats | Free, friendly for learners |
| Stata / SPSS | Survey data, weights | Common in research shops |