series_pow function raises each element in a numeric dynamic array (series) to a specified power. This performs element-wise exponentiation across the entire series.
You can use series_pow when you need to apply power transformations to time-series data. This is particularly useful for non-linear data transformations, calculating exponential growth patterns, applying polynomial features in analysis, or emphasizing larger values in your data.
For users of other query languages
If you come from other query languages, this section explains how to adjust your existing queries to achieve the same results in APL.Splunk SPL users
Splunk SPL users
In Splunk SPL, you typically use the 
pow() function within an eval command to calculate powers. In APL, series_pow applies the power operation to every element in an array simultaneously.ANSI SQL users
ANSI SQL users
In SQL, you use the 
POWER() function to raise values to a power on individual rows. In APL, series_pow operates on entire arrays, applying the exponentiation operation element-wise.Usage
Syntax
Parameters
| Parameter | Type | Description | 
|---|---|---|
| array | dynamic | A dynamic array of numeric values (base). | 
| power | real | The exponent to which to raise each element. | 
Returns
A dynamic array where each element is the result of raising the corresponding input element to the specified power.Use case examples
- Log analysis
- OpenTelemetry traces
- Security logs
In log analysis, you can use Run in PlaygroundOutput
This query squares request durations to amplify the differences, making performance anomalies more visible for analysis.
series_pow to emphasize outliers by squaring request durations, making larger values more prominent in analysis.Query| id | durations | squared_durations | 
|---|---|---|
| u123 | [50, 100, 75, 200] | [2500, 10000, 5625, 40000] | 
| u456 | [30, 45, 60, 90] | [900, 2025, 3600, 8100] | 
List of related functions
- series_multiply: Performs element-wise multiplication of two series. Use when you need multiplication between two series instead of raising to a power.
- series_log: Computes the natural logarithm of each element. Use as the inverse operation to exponentials.
- series_abs: Returns the absolute value of each element. Use when you need magnitude without power transformations.
- series_sign: Returns the sign of each element. Useful before applying power operations to handle negative values.