反馈已提交

网络繁忙

You are viewing 5.1 help doc. More details are displayed in the latest help doc.

Dynamically calculate the new quantity in a certain period of time

  • Recent Updates: April 25, 2022
  • 1. Overview

    1.1 Expected effect

    For example, you need to dynamically display the number of new stores in different regions every day, as shown in the following figure:

    12.png

    1.2 Implementation ideas

    Use filter components and "detail filtering": The first date filter component controls an indicator field to filter out the number of stores on the day; the second filter component controls an indicator field to filter out the total number of stores on the current day and the previous day.

    Create a calculation indicator and calculate the difference between the two indicator fields.

    2. Operation steps

    Sample data: 

    306.Dynamically calculate the new quantity in a certain period of time.xlsx

    Upload sample data to FineBI.

    2.1 New component

    Select the uploaded sample data and click "Create component", as shown in the figure below:

    1.png

    2.2 Set filter to calculate the number of stores on the day

    Enter the component editing interface and copy the field "Store", as shown in the figure below:

    2.png

    Convert the copied store field into an indicator, as shown in the figure below:

    3.png

    At this time, you get the number of "Stores" that are distinctly counted, that is how many stores there are.

    If you need to dynamically display the number of stores on the day, you need to establish a connection with the date filter component. At this time, you need to enter the dashboard and add "Filter component > Date Interval", as shown in the following figure:

    4.png

    And do not drag fields in from the left, as shown in the following figure:

    5.png

    Enter the component editing interface again to filter the details of the store (distinctly counter) and filter the time field. The filter condition is that the date belongs to the same step of the date interval of the filter component value. In other words, it is consistent with the filter time interval set by the time filter component, as shown in the following figure:

    6.png

    At this time, the optional conditions of the detail filtering condition for the date interval filter are "The last interval of the same step" and "Custom Step".

    2.3 Set the filter to calculate the total number of stores on the day and the previous day

    In the same steps as in section 2.2, copy the "Store" field and convert it into an indicator, and add a date range filter component, as shown in the following figure:

    7.png

    Set detail filtering condition of the "Store11" indicator as the date belongs to the same step of the "Filter component value" date interval, which is consistent with the filter date interval set by the date filter component added in the previous step, as shown in the following figure:

    8.png

    After setting, wait for the subsequent dragging of the fields into the component and setting the filter component data to meet the requirements.

    2.4 Calculate the number of new stores

    Number of new stores = Number of stores of the previous day and the same day - Number of stores in the day.

    Add "Calculation indicator", as shown in the figure below:

    9.png

    2.5 Make a chart

    Drag the corresponding field into the dimensions and indicator column, as shown in the figure below:

    10.png

    2.6 Make filter settings

    Enter the dashboard and set the filter date of "Date Range" to 2020-01-01, and the filter date of "Date Range1" from 2020-01-01 to 2020-01-02. The field "Number of new stores" will automatically display the number of newly added stores on the day after filtering, as shown in the figure below:

    11.png

    2.7 Effect view

    See section 1.2 of this article for details.

    Attachment List


    Theme: Build Charts and Analyze data
    Already the First
    Already the Last
    • Helpful
    • Not helpful
    • Only read

    售前咨询电话

    400-811-8890转1

    在线技术支持

    在线QQ:800049425

    热线电话:400-811-8890转2

    总裁办24H投诉

    热线电话:173-1278-1526

    文 档反 馈

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

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

    不再提示

    10s后关闭