internal function called by collex_logOR to compute Log10 Odds Ratio (Gries 2014).

logOR_compute(a, b, c, d)

Arguments

a

co-occurrence frequency between a given collocate and the nodeword.

b

co-occurrence frequency between the collocate and other words.

c

co-occurrence frequency between the nodeword and the other words.

d

co-occurrence frequency between all other words.

Value

A double-numeric value of Log10 Odds Ratio score

References

Examples

# Data from Table 2 in Rajeg and Rajeg (2019:71) a <- 9 b <- 1 c <- 408 d <- 305 logOR_compute(a, b, c, d)
#> [1] 0.6754515
# the above data produces positive log OR # Observed freq. for cell "a" is larger than the Expected freq. # Data from Table 3 in Rajeg and Rajeg (2019:74) a <- 1 b <- 6 c <- 416 d <- 300 logOR_compute(a, b, c, d)
#> [1] -0.7785926
# the above data produces negative log OR # Expected freq. for cell "a" is larger than the Observed freq.