add_moving_average
Create a rolling moving-average measure over the last N days or months, using a base measure and date column for your Power BI model.
Instructions
Generate a rolling moving-average measure over the last N periods. unit = day | month (default day).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| unit | No | day | month (default day) | |
| table | Yes | home table | |
| periods | Yes | number of periods, e.g. 7 or 3 | |
| dateTable | Yes | date table | |
| sessionId | Yes | ||
| dateColumn | Yes | date column | |
| baseMeasure | Yes | base measure name |