pub fn odds_ratio(table: [[u64; 2]; 2], kind: OddsRatioKind) -> OddsRatioResultExpand description
The odds ratio of a 2 × 2 table [[a, b], [c, d]] (SciPy’s odds_ratio). The conditional
estimate solves E_ω[X] = a for the odds ratio ω of Fisher’s noncentral hypergeometric
distribution of X = table[0][0] given all margins; its confidence limits invert that
distribution’s tails (the exact interval that matches Fisher’s exact test). The sample odds
ratio is ad/(bc), with Woolf’s interval exp(log OR ± z √(1/a + 1/b + 1/c + 1/d)).