Brandon: > I need an dictionary idiom whereby I can find all instances of > a given 'word' with any 'tagB', and then subdivide into all instances > of a given 'tagB'. In both cases I would want the value as a count of > all instances found.
If I have understood you well enough, I think you can do with a dict that has the tuple ('word', 'tagB') as key, and as value has a collections.defaultdict(int) that maps 'tagB' to its count. Bye, bearophile -- http://mail.python.org/mailman/listinfo/python-list