# SUBTOTAL

## Content

이 함수는 지정된 내장 함수 코드를 사용하여 숫자 목록의 부분합(subtotal)을 계산합니다.

## 구문

`SUBTOTAL(functioncode, value1, value2,...)`
`SUBTOTAL(functioncode, array)`

## 인수

*functioncode* 인수는 부분합에 사용할 내장 함수를 나타내는 숫자입니다. 다음 표를 참고하세요.

| 내장 함수 | 함수 코드 (숨겨진 값 포함) | 함수 코드 (숨겨진 값 무시) |
| ----- | ---------------- | ---------------- |
| [AVERAGE](/spreadjs/docs/v18/formulareference/FormulaFunctions/statistical-functions/AVERAGE) | 1 | 101 |
| [COUNT](/spreadjs/docs/v18/formulareference/FormulaFunctions/statistical-functions/COUNT) | 2 | 102 |
| [COUNTA](/spreadjs/docs/v18/formulareference/FormulaFunctions/statistical-functions/COUNTA) | 3 | 103 |
| [MAX](/spreadjs/docs/v18/formulareference/FormulaFunctions/statistical-functions/MAX) | 4 | 104 |
| [MIN](/spreadjs/docs/v18/formulareference/FormulaFunctions/statistical-functions/MIN) | 5 | 105 |
| [PRODUCT](/spreadjs/docs/v18/formulareference/FormulaFunctions/math-trig-functions/PRODUCT) | 6 | 106 |
| [STDEV](/spreadjs/docs/v18/formulareference/FormulaFunctions/compatibility-functions/STDEV) | 7 | 107 |
| [STDEVP](/spreadjs/docs/v18/formulareference/FormulaFunctions/compatibility-functions/STDEVP) | 8 | 108 |
| [SUM](/spreadjs/docs/v18/formulareference/FormulaFunctions/math-trig-functions/SUM) | 9 | 109 |
| [VAR](/spreadjs/docs/v18/formulareference/FormulaFunctions/compatibility-functions/VAR) | 10 | 110 |
| [VARP](/spreadjs/docs/v18/formulareference/FormulaFunctions/compatibility-functions/VARP) | 11 | 111 |

추가 인수는 배정밀도 부동 소수점 값, 정수 값 또는 이들의 배열(셀 범위)이 될 수 있습니다. 최대 255개의 인수를 포함할 수 있습니다. 값 목록 대신 단일 배열(셀 범위)을 사용할 수 있으며, 여러 배열(셀 범위)도 사용할 수 있습니다.

## 참고 사항

SUBTOTAL 함수는 동일 범위 내 다른 SUBTOTAL 함수 결과를 포함하지 않습니다. 행 높이를 0으로 설정하면 값이 숨겨집니다.

## 데이터 유형

모든 인수는 숫자 데이터를 입력받으며, 숫자 데이터를 반환합니다.

## 예제

`SUBTOTAL(8,A1:B7)`