# 財務彙總函數

本節說明有關付款和現金流之財務運作的彙總函數。

使用各個函數的下拉式清單，查看各函數的簡短描述及語法。按一下語法描述中的函數名稱以取得更多詳細資料。

## 載入指令碼中的財務彙總函數

[](https://help.qlik.com/en-US/qlikview/Subsystems/Client/Content/QV_QlikView/Scripting/FinancialAggregationFunctions/financial-aggregation-functions-script.htm)

#### IRR

IRR() 會針對由 group by 子句所定義之若干記錄上反覆運算的運算式中數字所代表的一組現金流量，傳回彙總的內部報酬率。

[**IRR**](https://help.qlik.com/zh-TW/qlikview/May2024/Subsystems/Client/Content/QV_QlikView/Scripting/FinancialAggregationFunctions/IRR.htm)(expression)

[](https://help.qlik.com/en-US/qlikview/Subsystems/Client/Content/QV_QlikView/Scripting/FinancialAggregationFunctions/financial-aggregation-functions-script.htm)

#### XIRR

XIRR() 會針對由 group by 子句所定義之若干記錄上反覆運算的配對數字 (以 pmt 和 date 表示) 所代表的現金流量表 (不一定是週期性)，傳回彙總的內部報酬率。 所有支出均按照 1 年 365 天攤算。

[**XIRR**](https://help.qlik.com/zh-TW/qlikview/May2024/Subsystems/Client/Content/QV_QlikView/Scripting/FinancialAggregationFunctions/XIRR.htm)(pmt, date)

[](https://help.qlik.com/en-US/qlikview/Subsystems/Client/Content/QV_QlikView/Scripting/FinancialAggregationFunctions/financial-aggregation-functions-script.htm)

#### NPV

NPV() 會根據由 group by 子句所定義之若干記錄上反覆運算的 value 中數字所代表的各個期間的固定 discount\_rate 以及一系列未來支出 (負值) 和收入 (正值)，傳回投資的彙總淨現值。支出和收入都是假設在各個期間結束時產生。

[**NPV**](https://help.qlik.com/zh-TW/qlikview/May2024/Subsystems/Client/Content/QV_QlikView/Scripting/FinancialAggregationFunctions/NPV.htm)(discount\_rate, value)

[](https://help.qlik.com/en-US/qlikview/Subsystems/Client/Content/QV_QlikView/Scripting/FinancialAggregationFunctions/financial-aggregation-functions-script.htm)

#### XNPV

XNPV() 會針對由 group by 子句所定義之若干記錄上反覆運算的配對數字 (以 pmt 和 date 表示) 所代表的現金流量表 (不一定是週期性)，傳回彙總的淨現值。rate 是各個期間的利率。 所有支出均按照 1 年 365 天攤算。

[**XNPV**](https://help.qlik.com/zh-TW/qlikview/May2024/Subsystems/Client/Content/QV_QlikView/Scripting/FinancialAggregationFunctions/XNPV.htm)(discount\_rate, pmt, date)

## 圖表運算式中的財務彙總函數

這些財務彙總函數可用於圖表中。

[](https://help.qlik.com/en-US/qlikview/Subsystems/Client/Content/QV_QlikView/Scripting/FinancialAggregationFunctions/financial-aggregation-functions-script.htm)

#### IRR

IRR() 會針對圖表維度上反覆運算的數字 (以 value 指定的運算式表示) 所代表的一系列現金流量，傳回彙總的內部報酬率。

[**irr**](https://help.qlik.com/zh-TW/qlikview/May2024/Subsystems/Client/Content/QV_QlikView/ChartFunctions/FinancialAggregationFunctionsInCharts/irr.htm)([TOTAL [&lt;fld {,fld}&gt;]] value)

[](https://help.qlik.com/en-US/qlikview/Subsystems/Client/Content/QV_QlikView/Scripting/FinancialAggregationFunctions/financial-aggregation-functions-script.htm)

#### NPV

NPV() 會根據各個期間的 discount\_rate 以及一系列未來支出 (負值) 和收入 (正值) (以圖表維度上反覆運算的 value 中的數字所表示)，傳回投資的彙總淨現值。支出和收入都是假設在各個期間結束時產生。

[**npv**](https://help.qlik.com/zh-TW/qlikview/May2024/Subsystems/Client/Content/QV_QlikView/ChartFunctions/FinancialAggregationFunctionsInCharts/npv.htm)([TOTAL [&lt;fld {,fld}&gt;]] discount\_rate, value)

[](https://help.qlik.com/en-US/qlikview/Subsystems/Client/Content/QV_QlikView/Scripting/FinancialAggregationFunctions/financial-aggregation-functions-script.htm)

#### XIRR

XIRR() 會針對圖表維度上反覆運算的配對數字 (以 pmt 和 date 指定的運算式表示) 所代表的現金流量表 (不一定是定期)，傳回彙總的內部報酬率。 所有支出均按照 1 年 365 天攤算。

[**xirr**](https://help.qlik.com/zh-TW/qlikview/May2024/Subsystems/Client/Content/QV_QlikView/ChartFunctions/FinancialAggregationFunctionsInCharts/xirr.htm)([TOTAL [&lt;fld {,fld}&gt;]] pmt, date)

[](https://help.qlik.com/en-US/qlikview/Subsystems/Client/Content/QV_QlikView/Scripting/FinancialAggregationFunctions/financial-aggregation-functions-script.htm)

#### XNPV

XNPV() 會針對圖表維度上反覆運算的配對數字 (以 pmt 和 date 指定的運算式表示) 所代表的現金流量表 (不一定是定期)，傳回彙總的淨現值。 所有支出均按照 1 年 365 天攤算。

[**xnpv**](https://help.qlik.com/zh-TW/qlikview/May2024/Subsystems/Client/Content/QV_QlikView/ChartFunctions/FinancialAggregationFunctionsInCharts/xnpv.htm)([TOTAL [&lt;fld{,fld}&gt;]] discount\_rate, pmt, date)