Support modules contain code that simplifies working with Simulation instances. It also uses routines from numkit.
This module contains classes and functions that combine multiple gromacs.analysis.core.Simulation objects. In this way the same kind of analysis or plotting task can be carried out simultaneously for all simulations in the collection.
Multiple objects (organized as a list).
Methods are applied to all objects in the Collection and returned as new Collection:
>>> from gromacs.analysis.collections import Collection
>>> animals = Collection(['ant', 'boar', 'ape', 'gnu'])
>>> animals.startswith('a')
Collection([True, False, True, False])
Similarly, attributes are returned as a Collection.
Using Collection.save() one can save the whole collection to disk and restore it later with the Collection.load() method
>>> animals.save('zoo')
>>> arc = Collection()
>>> arc.load('zoo')
>>> arc.load('zoo', append=True)
>>> arc
['ant', 'boar', 'ape', 'gnu', 'ant', 'boar', 'ape', 'gnu']