'Return an averaging category, or list of categories.
Parameters
item : str or list of str
Name of the category (comment field in DACQ).
Returns
conds : dict or list of dict, each with following keys:
comment: str
The comment field in DACQ.
state : bool
Whether the category was marked enabled in DACQ.
index : int
The index of the category in DACQ. Indices start from 1.
event : int
DACQ index of the reference event (trigger event, zero time for
the corresponding epochs). Note that the event indices start
from 1.
start : float
Start time of epoch relative to the reference event.
end : float
End time of epoch relative to the reference event.
reqevent : int
Index of the required (conditional) event.
reqwhen : int
Whether the required event is required before (1) or after (2)
the reference event.
reqwithin : float
The time range within which the required event must occur,
before or after the reference event.
display : bool
Whether the category was displayed online in DACQ.
nave : int
Desired number of averages. DACQ stops collecting averages once
this number is reached.
subave : int
Whether to compute normal and alternating subaverages, and
how many epochs to include. See the Elekta data acquisition
manual for details. Currently the class does not offer any
facility for computing subaverages, but it can be done manually
by the user after collecting the epochs.'

def __getitem__(self, item):

    if isinstance(item, str):
        item = [item]
    elif (not isinstance(item, list)):
        raise ValueError('Keys    must    be    category    names')
    cats = list()
    for it in item:
        if (it in self._categories):
            cats.append(self._categories[it])
        else:
            raise KeyError('No    such    category')
    return (cats[0] if (len(cats) == 1) else cats)
