logOR_compute: Compute Log10 Odds Ratio

Description Usage Arguments Value References Examples

View source: R/collex_logOR.R

Description

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

Usage

1
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

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
# Data from Table 2 in Rajeg and Rajeg (2019:71)
a <- 9
b <- 1
c <- 408
d <- 305

logOR_compute(a, b, c, d)

# 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)

# the above data produces negative log OR
# Expected freq. for cell "a" is larger than the Observed freq.

gederajeg/collogetr documentation built on April 16, 2020, 11:58 a.m.