Skip to content

FPGrowth based association rule mining implemented with python

Notifications You must be signed in to change notification settings

munhouiani/FPGrowth-python

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 

Repository files navigation

FPGrowth-python

This implementation is based on FP-Growth-Java.

Input File Format

The python script accepts input file with format:

f,c,a,m,p
f,c,b

or

f c a m p
f c a

Use along with IBM Quest Synthetic Data Generator and IBM Data Converter to produce csv file.

How to Use

First make main.py executable.

chmod +x main.py

Run FP-Growth algorithm with

./main input_file minsup minconf

Output

This program first prints frequent patterns:

{ frequent itemset } (support of the frequent item set)

Eg.

{ a } ( 3 )
{ a c } ( 3 )
{ a c f } ( 3 )
{ a f } ( 3 )
...

After that it prints the rules:

{ frequent itemset } => { frequent itemset } ( confidence )

Eg.

{ a } => { c } ( 1.0 )
{ c } => { a } ( 0.75 )
{ a } => { c f } ( 1.0 )
...

About

FPGrowth based association rule mining implemented with python

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages