Package com.imsl.datamining
Class AssociationRule
java.lang.Object
com.imsl.datamining.AssociationRule
- All Implemented Interfaces:
Serializable,Cloneable
Contains association rules discovered by the Apriori algorithm.
Y: \(\{Y_1,\ldots,Y_{n_Y}\}\)
Support of \( Z=X \cap Y \)
Support of X
Support of Y
Confidence measure for \(X \implies Y\)
Lift measure for \(X \implies Y\)
An association rule has the form, \(X \implies Y\),
where X and Y are two disjoint sets of items (or products)
that are represented in a set of occurrences (transactions).
The AssociationRule object contains members:
Y: \(\{Y_1,\ldots,Y_{n_Y}\}\)
Support of \( Z=X \cap Y \)
Support of X
Support of Y
Confidence measure for \(X \implies Y\)
Lift measure for \(X \implies Y\)
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptiondoubleThe confidence measure of the association rule.doublegetLift()The lift measure of the association rule.int[]Support for the Z, X, and Y components of the association rule.int[]getX()The X components of the association rule.int[]getY()The Y components of the association rule.voidprint()Print the member data in this object.static voidprint(AssociationRule[] ar) Print out the association rules inar.
-
Method Details
-
getX
public int[] getX()The X components of the association rule.- Returns:
- an
intarray containing the X components of the association rule.
-
getY
public int[] getY()The Y components of the association rule.- Returns:
- an
intarray containing the Y components of the association rule.
-
getSupport
public int[] getSupport()Support for the Z, X, and Y components of the association rule.- Returns:
- an
intarray containing the Z, X, and Y components of the association rule.
-
getConfidence
public double getConfidence()The confidence measure of the association rule.- Returns:
- a
doublespecifying the confidence measure of the association rule.
-
getLift
public double getLift()The lift measure of the association rule.- Returns:
- a
doublespecifying the lift measure of the association rule.
-
print
public void print()Print the member data in this object.The following is an example of this format:
X = {0} \(\implies\) Y = {2}
supp(X)=27, supp(Y)=33, supp(X and Y)=22
conf= 0.81, lift=1.23 -
print
Print out the association rules inar.- Parameters:
ar- anAssociationRulearray containing the association rules generated from a set of itemsets.
-