Measures

This page summarizes how the Measures work across the Analytics (ChartsData TablesRollups), including their data dependencies and supported calculations.

Concept

  • Measure – Numeric value you want to analyze (e.g., revenue, margin, volume, discount).

  • Dimension – Field you group or slice by (e.g., customer, product, region, time).

Source of Measures

Datamarts and Data Sources (Measure Flag)

For Money and Number fields in the Data Sources and Datamarts, the Measure property defines how the raw numeric data behaves in analytics:

  • Per Unit – Raw data is per unit; the system multiplies by Quantity to form a sum.

  • Extended – Raw data is already a total (for all quantity). It can be divided by quantity to get per-unit values.

  • Fixed – Values are neither multiplied nor divided by quantity.

These settings are defined when adding fields in Datamarts/Data Sources and are reused everywhere Measures are built.

Measures in Analytics

  • Charts & Data Tables – Measures are configured in the Measures section of each chart type (Bar & Line, Time Series, Scatter, Data Table, etc.).

  • Rollups – Measures are defined per Rollup, each has an aggregation function and optional formula.

Charts always aggregate measures over the chosen dimensions, so formulas defined on granular Rollups are aggregated again when used in charts (potential “double aggregation”). Recommended pattern: keep Rollups for base sums, and build final KPIs via the Expression Editor on top of those sums in the Charts/Rollups.

Measures in Agents

Measures are configured in the Definition Step of an Agent (per Series), alongside Data Sources, Group By, and filters. They are based on Datamart / Data Source fields and Query Expressions, using the same analytical engine as Analytics.

The Expression Editor (Agents) is used to define or edit measure formulas, working only with aggregated values (e.g., SUM(Revenue)SUM(Revenue)/NULLIF(SUM(Quantity),0)).

Measures are also reused in:

  • Detection Rules (conditions such as margins below threshold).

  • Action Definition > Impact Definition, where each impact metric is a selected measure (e.g., Revenue uplift, Profit uplift) and is used for ranking and limiting Actions.

Standard Measure Calculations in Analytics

For numeric variables (Money, Number, Quantity) in the Charts and Data Tables, the following calculation options are supported:

Core Numeric Calculations

  • SUM – Sum of a numeric field across all rows in each group.

  • Per Unit – Using the Quantity field defined in the Datamart (Type > QuantityFunction > Per Unit Basis).

    SUM(measure) / SUM(Quantity)
    
  • Percent (%) – Expressed as a percentage. The Percent Basis field is configured in the Datamart (Function > Percent Basis).

    SUM(measure) / SUM(Percent Basis field)
    
  • Contribution – For each group returns a decimal (share of total).

    SUM(measure in group) / SUM(measure over all groups)
    

Time & Trend–oriented Calculations (Bar & Line, Time Series)

For certain chart types (e.g., Bar & Line, Time Series, Detailed Time Series) additional post-processing options exist:

  • Index – Treats the first record as benchmark and shows each record’s value as a ratio to that benchmark (e.g., Net Margin vs first point).

  • Per Unit Index – Same as Index, but based on per-unit values.

    (SUM(measure)/SUM(Quantity)) / (per-unit value in benchmark)
    
  • Cumulative Sum – Running total: sum of measure up to the current point in the sorted series.

  • Cumulative Contribution – Cumulative version of Contribution: cumulative share of total as you progress through the sorted series.

String & Category Counts

For text dimensions.

  • Count – Number of rows.

  • Count Distinct – Number of unique values (e.g., distinct customer types).

See Also