Displaying the Total Value and Maximum Value Using the KPI Card

  • Last update:  2023-09-25
  • Overview

    Expected Effect

    Text statements are often needed in report dashboards to describe or summarize data.

    For example, you want to display the total number and total cost of branches, and the name and cost of the branch with the highest cost in FineBI, as shown in the following figure. In this case, you can use the KPI card.

    Implementation Ideas

    Use the TOTAL function to calculate the number and the total cost of branches.

    Add a filter condition to the Cost field to filter out the branch with the highest cost.

    Procedure

    Sample data: Logistics Profit Data.xlsx

    Calculating the Total Number of Branches

    To calculate the total number of branches and display the result with a KPI card, TOTAL and COUNTD_AGG are needed.

    Select the Logistics Profit Data table and add a component. Click Add Calculation Indicator, set Field Name, and enter the formula TOTAL(COUNTD_AGG(Branch Office),0,"sum"), as shown in the following figure.

    iconNote:
    The Branch Office field needs to be selected from the left column and cannot be entered manually.

    1.png

    Formula explanation:

    The COUNTD_AGG function is used to perform a distinct count on branch names, the result of which is summed up through the TOTAL function as the number of branches.

    Calculating the Total Cost of Branches

    To calculate the total cost and display the result with a KPI card, TOTAL and SUM_AGG are needed.

    Click Add Calculation Indicator, enter Field Name, and enter the formula TOTAL(SUM_AGG(Cost),0,"sum"), as shown in the following figure.

    iconNote:
    The Branch Office field needs to be selected from the left column and cannot be entered manually.

    2.png

    Displaying the Total Number and Total Cost of Branches

    To display the total number and cost of branches with a KPI card, click KPI Indicator Card and drag Number of Branches and Total Cost into the Text bar, as shown in the following figure.

    3.png

    Click Text to modify the data display format, as shown in the following figure.

    4.png

    4-2.png

    The effect is shown in the following figure.

    5.png

    Displaying the Branch with the Highest Cost

    To display the name and cost of the branch with the highest cost, you can add a filter condition.

    Drag Branch Office and Cost into the Text bar. By doing so, the name and total cost of each branch appear in the KPI card component, as shown in the following figure.

    6.png

    To retain only the data of the branch with the highest cost, you can filter the Cost field and set the filter condition to Largest N (N = 1) of Cost, as shown in the following figure.

    7.png

    7-2.png

    Deselect the Secondary Calculation option of Number of Branches and Total Cost, as shown in the following figure.

    Set the text format of the KPI card, as shown in the following figure.

    11.png

    iconNote:
    To display the data generated at a specific interval, add a time filter component. For example, you can add a year-month interval filter component to display the data generated at this interval.

    12.png

    Demonstration

    For the demonstration of this KPI card, see section "Preview."

    Attachment List


    Theme: 高度なデータ分析学習
    前の記事
    次の記事
    • いいね
    • 良くない
    • 閲覧しただけ

    フィードバック

    鼠标选中内容,快速反馈问题

    鼠标选中存在疑惑的内容,即可快速反馈问题,我们将会跟进处理。

    不再提示

    10s后关闭

    反馈已提交

    网络繁忙