1. A method comprising: identifying, by an apparatus comprising a processing device, a pattern in a graph that has a support value greater than a threshold, wherein: the graph comprises a plurality of weighted nodes coupled to one another by one or more weighted edges, and each of the plurality of nodes is associated with at least one weighted attribute; mining, by the apparatus, a plurality of 0-edge sub-graph patterns in the graph that each comprise an attribute specified in a list; inserting, by the apparatus, the 0-edge sub-graph patterns and respective instances of the 0-edge sub-graph patterns into a first data structure and a second data structure; and inserting, by the apparatus, a string representation of the 0-edge sub-graph patterns into a third data structure.