Class Itemset
- java.lang.Object
-
- org.processmining.logfiltering.algorithms.SPMF.Itemset
-
public class Itemset extends java.lang.ObjectThis class represents an itemset from a sequence where the itemset is a list of strings ordered by lexical order and does not contain an item twice, and the support of the itemset is not stored.- Author:
- Philippe Fournier-Viger
- See Also:
AbstractOrderedItemsetsAdapter
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddItem(java.lang.Integer value)Add an item to this itemsetItemsetcloneItemSet()This method makes a copy of an itemsetItemsetcloneItemSetMinusItems(java.util.Map<java.lang.Integer,java.util.Set<java.lang.Integer>> mapSequenceID, double relativeMinsup)This methods makes a copy of this itemset but without items having a support lower than minsupbooleancontainsAll(Itemset itemset2)This methods checks if another itemset is contained in this one.java.lang.Integerget(int index)Get an item at a given position in this itemsetjava.util.List<java.lang.Integer>getItems()Get the list of itemsintsize()Get the size of this itemset (the number of items)java.lang.StringtoString()Get this itemset as a string
-
-
-
Method Detail
-
addItem
public void addItem(java.lang.Integer value)
Add an item to this itemset- Parameters:
value- the item
-
getItems
public java.util.List<java.lang.Integer> getItems()
Get the list of items- Returns:
- list of items
-
get
public java.lang.Integer get(int index)
Get an item at a given position in this itemset- Parameters:
index- the position- Returns:
- the item
-
toString
public java.lang.String toString()
Get this itemset as a string- Overrides:
toStringin classjava.lang.Object- Returns:
- this itemset as a string
-
size
public int size()
Get the size of this itemset (the number of items)- Returns:
- the size
-
cloneItemSetMinusItems
public Itemset cloneItemSetMinusItems(java.util.Map<java.lang.Integer,java.util.Set<java.lang.Integer>> mapSequenceID, double relativeMinsup)
This methods makes a copy of this itemset but without items having a support lower than minsup- Parameters:
mapSequenceID- a map indicating the support of each item. key: item value: supportrelativeMinsup- the support expressed as a percentage- Returns:
- the new itemset
-
cloneItemSet
public Itemset cloneItemSet()
This method makes a copy of an itemset- Returns:
- the copy.
-
containsAll
public boolean containsAll(Itemset itemset2)
This methods checks if another itemset is contained in this one.- Parameters:
itemset2- the other itemset- Returns:
- true if it is contained
-
-