Odds Ratio (2×2) — case-control / cross-sectional

Verified

Advanced & specialized

Independently verified. Every statistic this test reports has been re-derived against an independent reference — never the library the pipeline itself calls — the rendered output was read back in a browser, and the result is locked with a committed regression suite.

Run this test straight away on a free built-in teaching dataset — no data of your own needed — or bring your own. Either opens the guided workspace: variable setup, assumption diagnostics, results with effect sizes and confidence intervals, figures, and APA-ready reporting.

Loading teaching datasets…

Or use your own dataset

Loading your datasets…

2×2 odds ratio with Woolf log-normal 95% CI plus Fisher's exact two-sided p as a small-sample-safe companion.

The key practical advantage of OR over RR: it's valid in prospective, retrospective, cross-sectional, AND case-control designs — RR is biased on case-control data. Under rare outcomes (baseline < 10%) OR ≈ RR; in common-outcome regimes (>30% baseline) the engine surfaces a primary-voice qualifier reminding the reader OR overstates RR there.

Worked example

How much does exposure change the odds of the outcome?

The odds ratio from a 2×2 table compares the odds of the outcome between exposed and unexposed groups.

Result

Exposure roughly doubled the odds (OR = 2.1, 95% CI [1.3, 3.4], p = .003).

How you'd report it (APA)

The 2×2 odds ratio showed exposure was associated with higher odds of the outcome, OR = 2.1, 95% CI [1.3, 3.4], p = .003.

When to use it

  • Case-control study (retrospective)
    An epidemiologist samples 100 lung-cancer cases from a registry and 100 age-matched controls from the same catchment.
  • Cross-sectional binary × binary association
    A workplace survey records remote-work status (yes/no) and self-reported burnout (yes/no) for 800 employees.
  • Logistic regression effect size (single binary predictor)
    Before fitting a logistic regression of treatment response on multiple covariates, the analyst computes the unadjusted 2×2 OR for the primary exposure.

When NOT to — use instead

Hypotheses

H₀: OR = 1 — no association.
Hₐ: OR ≠ 1.

Parameter tested: odds ratio OR

Assumptions (and what to do if they fail)

No zero cells. 0.5 continuity correction applied if any.high

Check: min cell.

If violated: Zero breaks Woolf CI.

OR approximates RR only when the outcome is rare (< 10% in unexposed).low

Check: p_unexposed.

If violated: OR overstates effect magnitude vs RR when outcome is common.

Ready to run a Odds Ratio (2×2) — case-control / cross-sectional on your own data?

Guided setup, automatic assumption checks, effect sizes, figures and an APA write-up.

Run this test →