AGGREGATE
Returns an aggregate in a list or database, with options to ignore error values and hidden rows
Syntax
AGGREGATE(function_num, options, ref1, [ref2], ...)
Parameters
- function_num: Required. A number 1-19 specifying which function to use (1=AVERAGE, 2=COUNT, 3=COUNTA, 4=MAX, 5=MIN, 6=PRODUCT, 7=STDEV.S, 8=STDEV.P, 9=SUM, 10=VAR.S, 11=VAR.P, 12=MEDIAN, 13=MODE.SNGL, 14=LARGE, 15=SMALL, 16=PERCENTILE.INC, 17=QUARTILE.INC, 18=PERCENTILE.EXC, 19=QUARTILE.EXC)
- options: Required. A numeric value that determines which values to ignore (0=nested SUBTOTAL and AGGREGATE, 1=hidden rows+nested, 2=errors+nested, 3=hidden+errors+nested, 4=nothing, 5=hidden rows, 6=errors, 7=hidden+errors)
- ref1: Required. The first numeric argument for the function
- ref2: Optional. Additional numeric arguments, 2 to 253
Example
=AGGREGATE(4, 6, A1:A10)