Documentation Index
Fetch the complete documentation index at: https://private-7c7dfe99-page-updates.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
sumArray
Description
TheArray combinator
can be applied to the sum
function to calculate the sum of all elements in an array, using the sumArray
aggregate combinator function.
The sumArray function is useful when you need to calculate the total sum of
all elements across multiple arrays in a dataset.
Example usage
In this example, we’ll use a sample dataset of daily sales across different product categories to demonstrate howsumArray works. We’ll calculate the total
sales across all categories for each day.
Query
sumArray function will sum up all elements in each category_sales array.
For example, on 2024-01-01, it sums 100 + 200 + 150 = 450. This gives the
same result as arraySum.