Skip to contents

calculate phi coefficient of two binary variables

Usage

stat_phi(x)

Arguments

x

2x2 matrix or dataframe

Value

phi coefficient

Examples

data <- matrix(c(10, 8, 14, 18), nrow = 2)
stat_phi(data)
#> [1] 0.1134241