Filtering Metrics
Learn how to use custom query parameters to filter export data API results for specific metrics and rows.
Using Custom Query Parameters
The API allows you to include additional query parameters to filter results of specific columns based on the metrics
parameter and rows based on the row_filter_column
parameter.
Parameter | Type | Required | Description |
---|---|---|---|
metrics | Array of metric names | Optional | If provided, only returns the specified columns instead of every metric. |
row_filter_column | String | Optional | Controls which rows are returned in the response. |
Note: Details on
row_filter_column
are below.
Value Result Example Use Case Not provided Return all time-series rows Default behavior ”frame” Return a single row where frame=0 For getting the start of the movement. Event column name Return a single row where that column = 0 For getting values at a specific event (ex: peak_event).
Examples of Usage
Here are some examples to demonstrate how to use custom attributes effectively:
-
Filter by metrics only
If you want to retrieve specific metrics such aspeak_event
andpeak_power
: -
Filter by metrics and row_filter_column
You can combine metrics and row_filter_column to refine your search further. For example, if you want to retrieve the row ofpeak_event
andpeak_power
for thecutting
movement at theturn_event
equal to 0:
Important Notes
-
Metrics Availability:
Verify that all requested metrics exist in the dataset before filtering. If any specified metric is not available, the export data job will fail. Check theerrorMessage
in the response for details about any non-existent columns when using themetrics
parameter. -
Row Filter Column:
Ensure the specified row filter column exists in the export data. If the column doesn’t exist, the export data job will fail. The responseerrorMessage
will indicate the column specified in therow_filter_column
parameter is invalid.Note that row filtering only supports values equal to 0. In theory, only a single row is returned for each session. If no rows have a value of 0 for the specified row filter column, the query may return an empty result set.