Create Calculated Dimensions in Charts

In your SAP Analytics Cloud chart, create a calculated dimension when you want to concatenate dimensions together, group dimensions, create an account-based dimension, and so on.

You can choose to combine existing dimensions to create your own dimensions.

Create one of the following calculated dimensions to use in your charts:
  • Concatenated dimension

  • Grouped dimension

  • Account-based dimension

Functions, Conditions, and Operators

The following functions, conditions, and operators are available for creating calculated dimensions. For descriptions of each option, see All Formulas and Calculations.

Functions:

IF()

NOT()

ISNULL()

LIKE()

TOTEXT()

TONUMBER()

LENGTH()

CONCAT()

SPLIT()

SUBSTRING()

TRIM()

ENDSWITH()

FINDINDEX()

REPLACE()

LEFT()

RIGHT()

LOWERCASE()

UPPERCASE()

TOTIME()

TODATE()

ISOWEEK()

WEEK()

-

-

Conditions:

AND

OR

> (greater than)

< (less than)

>= (greater than or equal)

<= (less than or equal)

= (equal)

!= (not equal)

Operators:
  • + (addition)

  • - (subtraction)

  • * (multiplication)

  • / (division)

How to Set Up a Calculated Dimension

Use the Calculation Editor to set up your calculated dimension.

  1. In Builder, under Dimensions, select Start of the navigation pathAdd Dimension Next navigation step Add Calculated DimensionEnd of the navigation path.

  2. In the Calculation Editor under Type, select Calculated Dimension.

  3. Provide a name for your calculated dimension.

How to Create a Concatenated Dimension

To create a concatenated dimension, do the following:

  1. In the Edit Formula area, type your formula.

    To concatenate two or more dimensions, use a plus (+) between the values. You can add a space as well:

  2. To close the Calculation Editor, click OK.

The calculated dimension is ready to be used in your chart.

How to Create a Grouped Dimension

You can choose to create your own member groupings for your data. For example, you may want to group sales from specific cities into North America, Europe, and Other regions. Using the Calculation Editor, create your own If, then, else formula.

  1. In the Edit Formula area, type an IF statement with the specific conditions.

  2. To close the Calculation Editor, click OK.

The calculated dimension is ready to be used in your chart.

How to Create an Account-Based or Value-Based Dimension

You can create a calculated dimension based on measure or account values or thresholds. For example, you could create a high/medium/low chart dimension based on your own criteria.

You can also create account-based or value-based dimensions in charts that include the following options:
  • Date dimension

  • Static filter that ignores all other filters

  • Dynamic filter or Input Control

Account-Based Dimension

To create an account-based dimension, do the following:

  1. In Builder, under Dimensions, select Start of the navigation pathAdd Dimension Next navigation step Add Calculated DimensionEnd of the navigation path.

  2. In the Calculation Editor under Type, select Account-Based Dimension.

  3. Provide a Name for the dimension.

  4. In the Properties section, select an account.

  5. Select Use Account values as dimension members.

    This will replace the Member Name field.

    You can set the scale and the number of decimal places for the account values that are converted to dimension members.

  6. Provide a Member Name: for example, high, medium, or low.

    Set the Account Values.

  7. From the Dimension Context, select one or more dimensions.

  8. (Optional) In Filter Context, add story or page filters.

    Story and page filters are not automatically applied to account-based dimensions, which means that some filtering results may not be as expected. This is easy to see when you use account values as dimension members.

  9. (Optional) In Filter Context, add a specific static filter.

    For example, you can use the Date dimension and select a single value such as a year or quarter.

  10. (Optional) In Filter Context, add a Calculation Input Control.
    1. Select a dimension.

    2. From Values or Input Controls, select Create a New Calculation Input Control.

    3. Provide a name for the input control.

    4. In the Input Values area, select your values.

    5. When finished, select OK.

  11. When finished, select OK.

Value-Based Dimension

To create a value-based dimension, do the following:

  1. In Builder, under Dimensions, select Start of the navigation pathAdd Dimension Next navigation step Add Calculated DimensionEnd of the navigation path.

  2. In the Calculation Editor under Type, select Value-Based Dimension.

  3. Provide a Name for the dimension.

  4. In the Properties section, select an account and a measure.

  5. Select Use measure values as dimension members.

    This will replace the Member Name field.

    You can set the scale and the number of decimal places for the measure values that are converted to dimension members.

  6. Provide a Member Name: for example, high, medium, or low.

    Set the Account Values.

  7. From the Dimension Context, select one or more dimensions.

  8. (Optional) In Filter Context, add story or page filters.

    Story and page filters are not automatically applied to value-based dimensions, which means that some filtering results may not be as expected. This is easy to see when you use measure values as dimension members.

  9. (Optional) In Filter Context, add a specific static filter.

    For example, you can use the Date dimension and select a single value such as a year or quarter.

  10. (Optional) In Filter Context, add a Calculation Input Control.
    1. Select a dimension.

    2. From Values or Input Controls, select Create a New Calculation Input Control.

    3. Provide a name for the input control.

    4. In the Input Values area, select your values.

    5. When finished, select OK.

  11. When finished, select OK.

The calculated dimension is ready to be used in your chart.