0% found this document useful (0 votes)
88 views4 pages

Conditional Pattern Base Analysis

The document contains 3 questions related to association analysis and frequent pattern mining. Question 1 involves constructing a conditional pattern base, conditional tree, and frequent pattern tree for an item and identifying the largest k-itemset. Question 2 involves generating a frequent pattern tree from transaction data and generating association rules for an item. Question 3 involves constructing conditional pattern bases and conditional trees for frequent items from a frequent pattern tree and identifying the largest k-itemset.
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
88 views4 pages

Conditional Pattern Base Analysis

The document contains 3 questions related to association analysis and frequent pattern mining. Question 1 involves constructing a conditional pattern base, conditional tree, and frequent pattern tree for an item and identifying the largest k-itemset. Question 2 involves generating a frequent pattern tree from transaction data and generating association rules for an item. Question 3 involves constructing conditional pattern bases and conditional trees for frequent items from a frequent pattern tree and identifying the largest k-itemset.
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

ITS665 || Data Mining

Tutorial 7 Part 2 – Topic 7 Part 2 (Association Analysis)

Question 1 (2019-06)

Given the following tree:

a) Determine the conditional pattern base, conditional tree and frequent pattern tree
for item T only. Let minimum count = 2 and item N occurs in all transactions.

Item Conditional Pattern Conditional Tree Frequent Pattern Tree


Base
T {N,S,A:2},{N:1} {N:3, S:2, A:2} {N,T:3}
{S,T:2}
{A,T:2}
{N,S,T:2}
{N,A,T:2}
{S,A,T:2}
{N,S,A,T:2}

b) Identify the largest k-itemsets and count the support for that itemset.

k=4
support = 2/5 = 40%
ITS665 || Data Mining

Question 2 (2016-12)

The following table shows a database D = {111, 112, …, 151} at one grocery store
purchased by customers on five different products: P, Q, R, S and T. Let minimum support
= 33.33% and minimum confidence = 80%. The tick () symbol represents the product
bought by the customer.

TID P Q R S T
111  
112  
121   
122   
131   
132  
141   
142    
151   

a) Generate a Frequent Pattern (FP) Tree. Clearly show the steps involved.

TID Items Bought Items Bought (Sorted)


111 P, Q P, Q
112 Q, S Q, S
121 P, Q, T P, Q, T
122 P, Q, S P, Q, S
131 P, R, S P, R, S
132 Q, R Q, R
141 P, R, S P, R, S
142 P, Q, R, T P, Q, R, T
151 P, Q, R P, Q, R

TID P Q R S T
111  
112  
121   
122   
131   
132  
141   
142    
151   
Total 7 7 5 4 2
ITS665 || Data Mining

Count the number of occurrences of each item:

L = {{P:7},{Q:7},{R:5},{S:4},{T:2}}

Minimum support = (33/100) x 9 = 2.97 = 3

Remove T

Therefore L = {{P:7},{Q:7},{R:5},{S:4}}

b) Generate TWO (2) rules for item R and calculate its confidence value.

Item Conditional Pattern Conditional Tree Frequent Pattern Tree


Base
R {P,Q:2}, {P:2},{Q:1} {P:4} {P,R:4}

P  R (Confidence value = 4/7)


R  P (Confidence value = 4/5)
ITS665 || Data Mining

Question 3 (2014-12)

Given the following frequent-pattern (FP) tree with minimum support and threshold=3.

a) For each frequent item, construct its conditional pattern base and conditional FP-
tree.

Item Conditional Pattern Conditional FP-Tree FP Generated


Base
Z {s,d,b,n:2}{d,c:1} {s:2,d:2,b:2,n:2}{d:1,c:1} empty
N {s,d,b:2},{s,d,b,c:1} {s:3,d:3,b:3,c:1} {s,d,b,n}
C {s,d,b:1},{s:1},{d:1} {s:2,d:1,b:1}{d:1} Empty
B {s,d:3} {s:3,d:3} {s,d,b}
D {s:3} {s:3} {s,d}
S empty empty empty

b) What is the largest k-itemset from question (a)

k=4

You might also like