Search code examples
rmarkov-chainspsttraminersequence-analysis

Meaning of lag parameter in PST?


In the pmine() function in PST you can use lags. What is this lag? Does it mean that it ignores the lag first positions in the sequence? Or does it mean that you allow for lags within the subsequences? From the documentation it is hard to understand what is actually meant by lag.


Solution

  • The lag parameter when searching patterns with the pmine() function means that we look only for patterns that are preceded by at least lag elements, i.e., for patterns with a context of length at least equal to lag. The lag first positions will not belong to find patterns, but they could belong to their context. So, they are not ignored.