The cl-association-rules Reference Manual

This is the cl-association-rules Reference Manual, version 0.0.1, generated automatically by Declt version 4.0 beta 2 "William Riker" on Sun Dec 15 04:40:08 2024 GMT+0.

Table of Contents


1 Introduction


2 Systems

The main system appears first, followed by any subsystem dependency.


2.1 cl-association-rules

An implementation of the apriori algorithm to mine association rules in Common Lisp.

Author

Diogo Franco

License

MIT

Version

0.0.1

Source

cl-association-rules.asd.

Child Components

3 Files

Files are sorted by type and then listed depth-first from the systems components trees.


3.1 Lisp


3.1.1 cl-association-rules/cl-association-rules.asd

Source

cl-association-rules.asd.

Parent Component

cl-association-rules (system).

ASDF Systems

cl-association-rules.


3.1.2 cl-association-rules/package.lisp

Source

cl-association-rules.asd.

Parent Component

cl-association-rules (system).

Packages

cl-association-rules.


3.1.3 cl-association-rules/rule.lisp

Dependency

package.lisp (file).

Source

cl-association-rules.asd.

Parent Component

cl-association-rules (system).

Public Interface
Internals

3.1.4 cl-association-rules/apriori.lisp

Dependency

rule.lisp (file).

Source

cl-association-rules.asd.

Parent Component

cl-association-rules (system).

Public Interface

apriori (function).

Internals

4 Packages

Packages are listed by definition order.


4.1 cl-association-rules

Source

package.lisp.

Nickname

rules

Use List

common-lisp.

Public Interface
Internals

5 Definitions

Definitions are sorted by export status, category, package, and then by lexicographic order.


5.1 Public Interface


5.1.1 Ordinary functions

Function: apriori (dataset &key support confidence test)

Calculates the association rules in the dataset using the apriori algorithm. Expects a dataset of the form
((1 2 3 4)
(3 2 7 9)
(9)
(2 3 8)
(2 0)),
where each line is a transaction.
Returns a list of the mined rules.

Package

cl-association-rules.

Source

apriori.lisp.

Function: make-rule (&key pretuple posttuple support confidence)
Package

cl-association-rules.

Source

rule.lisp.

Reader: rule-confidence (instance)
Writer: (setf rule-confidence) (instance)
Package

cl-association-rules.

Source

rule.lisp.

Target Slot

confidence.

Reader: rule-posttuple (instance)
Writer: (setf rule-posttuple) (instance)
Package

cl-association-rules.

Source

rule.lisp.

Target Slot

posttuple.

Reader: rule-pretuple (instance)
Writer: (setf rule-pretuple) (instance)
Package

cl-association-rules.

Source

rule.lisp.

Target Slot

pretuple.

Reader: rule-support (instance)
Writer: (setf rule-support) (instance)
Package

cl-association-rules.

Source

rule.lisp.

Target Slot

support.


5.1.2 Standalone methods

Method: print-object ((object rule) stream)
Source

rule.lisp.


5.2 Internals


5.2.1 Ordinary functions

Function: copy-rule (instance)
Package

cl-association-rules.

Source

rule.lisp.

Function: generate-candidates (frequent-items non-frequent-items all-items test)

Generates the next candidate set, from the previous frequent and non-frequent itemsets.

Package

cl-association-rules.

Source

apriori.lisp.

Function: generate-rules (frequent-itemsets min-confidence num-transactions test)

From the frequent itemsets found by apriori, generate association rules for a given min-confidence.

Package

cl-association-rules.

Source

apriori.lisp.

Function: get-all-items (dataset test)

From a dataset, return the unique items as a list.

Package

cl-association-rules.

Source

apriori.lisp.

Function: get-frequent-items (candidate-set min-support dataset test frequent-items-hash)

From a candidate set and support threshold, return the items that are frequent and non-frequent in the dataset.

Package

cl-association-rules.

Source

apriori.lisp.

Function: rule-p (object)
Package

cl-association-rules.

Source

rule.lisp.

Function: set-equal-p (set-1 set-2 test)

Returns t if two sets of elements are equal

Package

cl-association-rules.

Source

apriori.lisp.


5.2.2 Structures

Structure: rule
Package

cl-association-rules.

Source

rule.lisp.

Direct superclasses

structure-object.

Direct methods

print-object.

Direct slots
Slot: pretuple
Readers

rule-pretuple.

Writers

(setf rule-pretuple).

Slot: posttuple
Readers

rule-posttuple.

Writers

(setf rule-posttuple).

Slot: support
Readers

rule-support.

Writers

(setf rule-support).

Slot: confidence
Readers

rule-confidence.

Writers

(setf rule-confidence).


Appendix A Indexes


A.1 Concepts


A.2 Functions

Jump to:   (  
A   C   F   G   M   P   R   S  
Index Entry  Section

(
(setf rule-confidence): Public ordinary functions
(setf rule-posttuple): Public ordinary functions
(setf rule-pretuple): Public ordinary functions
(setf rule-support): Public ordinary functions

A
apriori: Public ordinary functions

C
copy-rule: Private ordinary functions

F
Function, (setf rule-confidence): Public ordinary functions
Function, (setf rule-posttuple): Public ordinary functions
Function, (setf rule-pretuple): Public ordinary functions
Function, (setf rule-support): Public ordinary functions
Function, apriori: Public ordinary functions
Function, copy-rule: Private ordinary functions
Function, generate-candidates: Private ordinary functions
Function, generate-rules: Private ordinary functions
Function, get-all-items: Private ordinary functions
Function, get-frequent-items: Private ordinary functions
Function, make-rule: Public ordinary functions
Function, rule-confidence: Public ordinary functions
Function, rule-p: Private ordinary functions
Function, rule-posttuple: Public ordinary functions
Function, rule-pretuple: Public ordinary functions
Function, rule-support: Public ordinary functions
Function, set-equal-p: Private ordinary functions

G
generate-candidates: Private ordinary functions
generate-rules: Private ordinary functions
get-all-items: Private ordinary functions
get-frequent-items: Private ordinary functions

M
make-rule: Public ordinary functions
Method, print-object: Public standalone methods

P
print-object: Public standalone methods

R
rule-confidence: Public ordinary functions
rule-p: Private ordinary functions
rule-posttuple: Public ordinary functions
rule-pretuple: Public ordinary functions
rule-support: Public ordinary functions

S
set-equal-p: Private ordinary functions