The subgraph pattern or graph pattern is an important application of data mining; this is used for bioinformatics, social network analysis, and so on. Frequent subgraph patterns are patterns that occur frequently in a set of graphs or in a large graph.
The gPLS algorithm
The GraphSig algorithm
The gSpan algorithm
The summarized pseudocode for the gSpan algorithm is as follows:
Rightmost path extensions and their supports
The subgraph isomorphism enumeration algorithm
The canonical checking algorithm
The R implementation
Please take a look at the R codes file ch_09_gspan.R from the bundle of R codes for previously mentioned algorithms. The codes can be tested with the following command: