Added documentation.
Fixed bug which occured when no aggregates where active.