You are viewing documentation about an older version (1.3.0). View latest version

snowflake.snowpark.RelationalGroupedDataFrame.agg

RelationalGroupedDataFrame.agg(*exprs: Column | Tuple[ColumnOrName, str] | Dict[str, str]) DataFrame[source] (https://github.com/snowflakedb/snowpark-python/blob/release-v1.3.0/src/snowflake/snowpark/relational_grouped_dataframe.py#L202-L264)

Returns a DataFrame with computed aggregates. See examples in DataFrame.group_by().

Parameters:

exprs

A variable length arguments list where every element is

  • A Column object

  • A tuple where the first element is a column object or a column name and the second element is the name of the aggregate function

  • A list of the above

or a dict maps column names to aggregate function names.

Note

The name of the aggregate function to compute must be a valid Snowflake aggregate function.

语言: 中文