Skip to main content
Connecting to databases other than Google Analytics requires an Enterprise plan. Contact Sales for details.

What are Measures?

Measures are aggregated computations performed on specific columns within your model. They are used to derive insightful metrics, often serving as the foundation for more complex analytical structures. Measures can range from simple sums or averages to intricate calculations utilizing various dimensions, conditions, and data transformations.

How to Define Measures

When defining a measure, you should be familiar with several key parameters:

Name

A unique identifier for the measure, distinct across all semantic models in your project.

Description

A human-readable explanation of the calculated measure.

Aggregator

Specifies the aggregation type to be applied (e.g., sum, average, max, etc.).

Expression (expr)

References an existing column or provides a SQL expression for a new/derived column.

How to create and edit a measure

In the Catalog section, select the table for which you want to configure a measure. Then, navigate to the Measures tab.

Specification for Measures

Measures are defined using the following structure:
For example, in a semantic model for transactions:

Supported Aggregations

Darling supports a rich set of aggregation types to cater to diverse data analysis needs:
Basic aggregations provide elementary mathematical operations on data.
  • sum: Total of values.
  • min: Smallest value.
  • max: Largest value.
  • average: Mean of values.

When creating measures, ensure that the data types and SQL functions are compatible with your specific data platform’s capabilities, as these can vary.

Wrapping Up

Measures are pivotal for deriving insights from your data through metrics. By understanding and effectively utilizing measures, you can generate more valuable and accurate metrics for your analyses.
While measures often utilize dimensions for their calculations, they are not strictly dependent on them. However, when applying filters or other conditions based on dimensions, it’s essential to ensure the correct relationships and joins are maintained for accurate results.