AggregatorAvg Class

Define an aggregator that gets an average based on join keys.

Inheritance
AggregatorAvg

Constructor

AggregatorAvg()

Remarks

Aggregators are typically not instantiated directly. Instead, specify the the type of aggregator when using using an enricher such as the HolidayEnricher object.

The process_public_dataset(env, _public_dataset, cols, join_keys) method gets the average value.

Methods

get_log_property

Get log property tuple, None if no property.

process_public_dataset

Get average based on the input join_keys.

get_log_property

Get log property tuple, None if no property.

get_log_property()

process_public_dataset

Get average based on the input join_keys.

process_public_dataset(env: SparkEnv | PandasEnv, _public_dataset: object, cols: object, join_keys: list)

Parameters

Name Description
env
Required

The runtime environment.

_public_dataset
Required

The input public dataset.

cols
Required

The column name list to retrieve.

join_keys
Required

A list of join key pairs.

Returns

Type Description

An aggregated public dataset.