Skip to contents

McNemar's test (paired nominal data)

Usage

mcnemar_test(contingency_table, exact = FALSE)

Arguments

contingency_table

2x2 table.

exact

Use exact binomial.

Value

An object of class "morie_test_result".

Examples

tab <- matrix(c(20, 5, 10, 15), nrow = 2)
res <- mcnemar_test(tab)
res
#> McNemar's test
#> --------------
#>   statistic = 1.06667
#>   p-value   = 0.3017
#>   df        = 1
#>   n         = 50