Giter Club home page Giter Club logo

mba-apriori-python's Introduction

A python implementation of apriori algorithm for market basket analysis.

How to use apriori algorithm :

The algorithm is devloped for python 3.

Before using apriori algorithme, you have to clone the repository for instance you can use git clone https://github.com/GuillaumeLe/mba-apriori-python.git or you can download the .zip file and extract them in your project.

Next you have to include apriori in your python project : import apriori.

The apriori function use a liste of transactions, where each transaction is a list of item.

transactions = [
    ['A','B','D','E'],
    ['C','A','D','B','F'],
    ['D','A','H','B','C'],
    ['E','F','B','C']
]

Apriori function use three arguments apriori(transactions):

  • the transactions transactions.
  • the minimum support min_supp which is the minimum number of occurence to considere a case, by default min_supp = 3.
  • the confidence confidence, by default confidence = 0.75

Development :

The librairy is develped with TDD method. To run test use python3 test.py.

mba-apriori-python's People

Contributors

guillaumele avatar okamille avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.