calc_chi2: Vectorized computation of chi^2 statistic for a 2x2 crosstab...

View source: R/chi.r

calc_chi2R Documentation

Vectorized computation of chi^2 statistic for a 2x2 crosstab containing the values [a, b] [c, d]

Description

Vectorized computation of chi^2 statistic for a 2x2 crosstab containing the values [a, b] [c, d]

Usage

calc_chi2(a, b, c, d, correct = T, cochrans_criteria = F)

Arguments

a

topleft value of the table

b

topright value

c

bottomleft value

d

bottomright value

correct

if TRUE, use yates correction. Can be a vector of length a (i.e. the number of tables)

cochrans_criteria

if TRUE, check if cochrans_criteria indicate that a correction should be used. This overrides the correct parameter


kasperwelbers/tcorpus documentation built on May 10, 2023, 5:10 p.m.