SUBTOTAL
Name
SUBTOTAL(functioncode, value1, value2,...)
Definition
This function calculates a subtotal of a list of numbers using a specified built-in function
Syntax
function code- required and type of subtotal to create.Function code can be a value ranging from 1-11
1
isAVERAGE
2
isCOUNT
3
isCOUNTA
4
isMAX
5
isMIN
6
isPRODUCT
7
isSTDEV
8
isSTDEVP
9
isSUM
10
isVAR
11
isVARP
Hidden values can be skipped for any of these codes by prepending
10
(to the single-digit codes) or1
(to the 2-digit codes). e.g. 102 forCOUNT
while skipping hidden cells, and110
forVAR
while doing so.
value 2- optional and the second number used to compare. Assumed zero by default.
- Cells that are hidden due to auto filter criteria are never included in
SUBTOTAL
, irrespective of thefunction_code
used. - Cells within any of the specified
range
arguments that containSUBTOTAL
calls are ignored to prevent double-counting.
- Cells that are hidden due to auto filter criteria are never included in
Step 1 :To begin to use the SUBTOTAL formula, start with the Excellentable you would like to edit.
Step 2 : Then type the SUBTOTAL Formula in the cell you have chosen to display the outcome:
Step 3 : Type in the complete SUBTOTAL formula for a cell as shown below:
Step 4 : Excellentable will generate the outcome when hitting enter.
A
|
B
|
C
|
D
|
|
---|---|---|---|---|
1
|
||||
2
|
||||
3
|
||||
4
|
||||
5
|
||||
6
|
||||
7
|
||||
8
|
||||
9
|
||||
10
|
||||
11
|
||||
12
|
||||
13
|
||||
14
|
||||
15
|
||||
16
|
E
|
F
|
G
|
|
---|---|---|---|
1
|
2
50,645 (131,170)
1,775 (4,597)
7
3
570,641 (1,477,950)
94,743 (245,383)
1
4
113,594 (294,207)
396 (1,026)
9
5
52,035 (134,770)
1,143 (2,960)
4
6
155,779 (403,466)
7,916 (20,502)
53
7
103,642 (268,432)
452 (1,171)
7
8
4,842 (12,541)
701 (1,816)
5
9
1,949 (5,048)
540 (1,399)
1
10
53,625 (138,888)
12,133 (31,424)
27
11
57,513 (148,958)
1,912 (4,950)
14
12
6,423 (16,635)
4,509 (11,678)
2
13
82,643 (214,044)
926 (2,398)
2
14
50,645 (131,170)
1,775 (4,597)
7
15
16