Professional Documents
Culture Documents
Subhasis Ray
2023-04-19
. . . . . . . . . . . . . . . . . . . .
. . . . . . . . . . . . . . . . . . . .
. . . . . . . . . . . . . . . . . . . .
. . . . . . . . . . . . . . . . . . . .
P(A∪B)
lift(A, B) = P(A)P(B)
If A and B are independent: lift 1
If A and B are negatively correlated: lift(A, B) < 1
If A and B are positively correlated: lift(A, B) > 1
. . . . . . . . . . . . . . . . . . . .
. . . . . . . . . . . . . . . . . . . .
Transaction database
item1 item2
Lift for A => C
P(A∪C)
1 A C = P(A)P(C)
2 A C 3/7
3 A D = (4/7)(4/7)
4 A C
5 B D = 21/16
6 B C
7 B C
. . . . . . . . . . . . . . . . . . . .
. . . . . . . . . . . . . . . . . . . .
Contingency table
A = a1 A = a2
B = b1 o11 o12 Tb1
B = b2 o21 o22 Tb2
Ta1 Ta2
Compute
∑c ∑r (oij−eij)2
χ2 = i=1 j=1 eij
Degrees of freedom = (r - 1) x (c - 1) where r is the
number of rows and c is the number of columns.
Check significance from table/software for this χ2 value
for this many degrees of freedom.
. . . . . . . . . . . . . . . . . . . .
. . . . . . . . . . . . . . . . . . . .
∑ |X| 2
For any itemset X: χ2 (X) = 2i=1 (oi −eei
i)
References
Charu Aggarwal
Han, Kamber, Pei
Hongbo Du
. . . . . . . . . . . . . . . . . . . .
. . . . . . . . . . . . . . . . . . . .