SparkR (version 2.1.2)

avg: avg

Description

Aggregate function: returns the average of the values in a group.

Usage

avg(x, ...)

# S4 method for Column avg(x)

Arguments

x

Column to compute on or a GroupedData object.

...

additional argument(s) when x is a GroupedData object.

See Also

Other agg_funcs: agg, countDistinct, count, first, kurtosis, last, max, mean, min, sd, skewness, stddev_pop, stddev_samp, sumDistinct, sum, var_pop, var_samp, var

Examples

Run this code
# NOT RUN {
avg(df$c)
# }

Run the code above in your browser using DataLab