SUBTOTAL
Returns a subtotal in a list or database, ignoring other SUBTOTAL results in the range
Syntax
SUBTOTAL(function_num, ref1, [ref2], ...)
Parameters
- function_num: Required. The number 1-11 or 101-111 specifying which function to use for the subtotal (1/101=AVERAGE, 2/102=COUNT, 3/103=COUNTA, 4/104=MAX, 5/105=MIN, 6/106=PRODUCT, 7/107=STDEV, 8/108=STDEVP, 9/109=SUM, 10/110=VAR, 11/111=VARP. 101-111 ignore manually hidden values)
- ref1: Required. The first named range or reference to the subtotal
- ref2: Optional. Additional ranges, up to 254
Example
=SUBTOTAL(9, A1:A10)