Running Calculation
The 'Running' calculation allows you to express each group aggregate as an accumulation of previous aggregate values in the series. The method of accumulation is specified by the 'Aggregate' menu in the 'Calculation' dialog box. (See Aggregation Options for more about the different methods.)

The 'Reset at' option, available for date fields, allows you to specify the date interval (e.g., year, quarter, week, etc.) at which the accumulation should be cleared.
In this example, you will create a chart that computes total quantities sold by month, and displays these values as a running average. The running average will be reset on a yearly basis. Follow the steps below:
1. Create a new Viewsheet based on the sample 'Sales Explore' Worksheet in the 'Sales' folder.
2. Drag a Chart component onto the Viewsheet grid, and enlarge the Chart as desired by dragging the handles.
3. Click the center of the Chart (or click the 'Edit' button at the top-right). This opens the Chart Editor.
4. In the Chart Editor, from the 'Dimensions' node in the Data Source panel, drag the 'Date' dimension to the 'X' field in the Data panel.
5. From the 'Measures' node in the Data Source panel, drag the 'Quantity Purchased' measure to the 'Y' field in the Data panel.
6. In the Data panel of the Chart Editor, click the 'Edit Dimension' button next to the 'Date' measure. This opens a pop-up panel.
7. From the 'Level' menu select 'Month', and click the green 'Apply' button. This groups the date data (i.e., X-axis labels) by month.

8. In the Data panel of the Chart Editor, click the 'Edit Measure' button next to the 'Quantity Purchased' measure. This opens a pop-up panel.
Note: Leave the 'Aggregate' option in the pop-up panel set to the default 'Sum'.
9. In the 'Calculate' menu of the pop-up panel, select the 'Custom' option.

10. Click the 'Edit' button to open the 'Chart Calculation' dialog box. Make the following settings:
a. From the 'Calculate' menu, select 'Running'.
b. From the 'Aggregate' menu, select 'Average'.
c. From the 'Reset at' menu, select 'Year'.

d. Click 'OK' to close the dialog box.
11. Click the green 'Apply' button in the pop-up panel to apply the change.

The time series now shows a running average for the summed quantity purchase, re-initialized at each new year.
See Also
Sliding Calculation, to accumulate values over a limited sliding range.
| << Change Calculation | © 1996-2013 InetSoft Technology Corporation (v11.4) | Sliding Calculation >> |