Before You Begin
Before creating a metric, ensure you have:- An API access token with appropriate permissions
- Created the entity you want to measure
- Created a fact table with the measurements to aggregate
- Determined the aggregation type and time windows
Create an Average Metric
Create an average metric that measures the average sales amount per user:Create a Ratio Metric
Create a ratio metric like conversion rate:Aggregation Types
For average metrics, choose how to aggregate data within units:AGGREGATION_TYPE_SUM: Sum all measurementsAGGREGATION_TYPE_COUNT: Count occurrencesAGGREGATION_TYPE_COUNT_DISTINCT: Count unique valuesAGGREGATION_TYPE_MAX: Maximum valueAGGREGATION_TYPE_MIN: Minimum valueAGGREGATION_TYPE_UNIQUE: Single unique value (fails if multiple values exist)
Time Windows
Aggregation Window
TheaggregationWindow defines how long after exposure to aggregate measurements:
86400s: 1 day604800s: 7 days2592000s: 30 days
Exposure Offset
TheexposureOffset defines how long to wait after exposure before starting measurement:
Variance Reduction (CUPED)
Enable or disable variance reduction to improve statistical power:Enabled (Default)
Disabled
Next Steps
After creating metrics:- Configure experiments to track these metrics
- Analyze experiment results using these metrics
- Create additional metrics to measure different aspects of user behavior

