I am using for my Master's thesis the package for finding sequential patterns using SPADE with BitSet. I'm at a point, where I want to retriev the sequences, which contain a specific pattern. I tried to use the BitSet information in Pattern (pattern.getAppearingIn()), but I cannot menage to find the connection between the sequences (e.g. SequenceDatabase) and the pattern.
I will give you the explanation that may be missing.
Each sequences is identified by an ID starting from 0.
So for example, if you have 4 sequences, they will be numbered 0,1,2, 3.
Now, the method pattern.getAppearingIn() returns the list of sequence ID where the patterns appear.
So for example, if you call pattern.getAppearingIn() and it returns a bitset with 0, 1 and 2 set to true, then it means that the pattern appears in the first, second and the third sequence.
Then if you want to get the sequence with a given ID, it is also not very difficult. For example, if you want to get the sequence with ID 0, then you can use the SequenceDatabase object to do getSequences().get(0) which will return the sequence with ID 0.