WebFOCUS Online Help > Managed Reporting End User > Analyzing Data in an OLAP Report > Performing a Calculation on a Measure

Performing a Calculation on a Measure

How to:

Reference:

You can perform standard calculations, such as average, percent, and summarize, on the numeric data in measures on an OLAP report.


Top of page

Procedure: How to Apply a Calculation to a Measure
  1. Run the Standard Report.
  2. Open the OLAP Control Panel.
  3. Click a measure in the Measures pane.

    The sort options pane opens. Do not click the Measures check pane, which controls the display of a measure, not its sorting.

  4. Click the arrow under Measure Calculations and select a calculation from the list.

    None is the default value. For details, see Calculations You Can Perform on a Measure.

  5. Click OK.

    The sort pane is replaced by the Measures pane, where the selected calculation appears as a prefix to the measure.

  6. Click Run, and the applied calculation is added to the column title.

Top of page

Reference: Calculations You Can Perform on a Measure

The following table lists the types of calculations in the first column and describes their functions in the second column.

Calculation

Function

Average Sum
of Squares

Computes the average sum of squares for standard deviation in statistical analysis.

Average

Computes the average value of the field.

Count

Counts the number of occurrences of the field.

Count 
Distinct

Counts the number of distinct values within a field when using -REMOTE. For other modes of operation, this behaves like Count.

Maximum 

Generates the maximum value of the field.

Minimum

Generates the minimum value of the field.

Percent

Computes a field's percentage based on the total values for the field. The Percent can be used with detail as well as summary fields.

Percent
Count

Computes a field's percentage based on the number of instances found.

Row

Computes a field's percentage based on the total values for the field across a row.

Summarize

Sums the number of occurrences of the field.

Total

Counts the occurrences of the field for use in a heading (includes footings, subheads, and subfoots).


Top of page

Example: Applying a Percent Calculation to a Measure

The following is an example of applying a percent calculation to a measure.

  1. Run the Standard Report OLAPREP6.

    The report shows Quantity and Line Cost of Goods Sold sorted by plant and product category, with a subtotal at each sort break.

    You want to create a report column that shows the percent of total sales for each plant.

  2. Click the square icon next to PLANT to open the Control Panel as shown in the following report image.

  3. Click Line Cost of Goods Sold in the Control Panel's Measures pane.

    The sort pane opens.

  4. Under Measures Calculations, choose Percent from the drop-down list as shown in the following image, then click OK to see the calculation as a prefix for the measure in the Measures pane.

  5. Click the Run button at the bottom of the Control Panel.

    The report now breaks down sales for each product at each plant by as a percentage of total sales as shown in the following image.

Notice that the subtotals have been removed from the report because the breakdown by plant is no longer suitable for the data.


WebFOCUS