Package s3 :: Module s3grouped :: Class S3GroupAggregate
[frames] | no frames]

Class S3GroupAggregate

source code

object --+
         |
        S3GroupAggregate

Class representing aggregated values

Instance Methods
 
__init__(self, method, key, values)
Constructor
source code

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Class Methods
 
aggregate(cls, items)
Combine sub-aggregates
source code
Properties

Inherited from object: __class__

Method Details

__init__(self, method, key, values)
(Constructor)

source code 

Constructor

Parameters:
  • method - the aggregation method (count, sum, min, max, avg)
  • key - the attribute key
  • values - the attribute values
Overrides: object.__init__

aggregate(cls, items)
Class Method

source code 

Combine sub-aggregates

Parameters:
  • items - iterable of sub-aggregates
Returns:
an S3GroupAggregate instance