CUMULATE function

  • 21 December 2021
  • 0 replies
  • 300 views

Userlevel 3
Badge

 

Description

Cumulates each item of a list using its ordering

 

Syntax

CUMULATE(number, cumulated_dimension, group_dimension, aggregation)

  • first parameter number can be a Metric or a List Property

  • cumulated_dimension, list according to which cumulation is made, should be one of the Dimension of the first parameter

  • group_dimension is a list that resets the accumulation (optional)

  • aggregation SUM, AVG, MIN, MAX (optional)

 

Return type

number

 

Examples

Case

Results

Return Type

CUMULATE(10, 'Month')

cumulates 10 on each month starting from the first period of the calendar (ex. Jan 20: 10, Feb 20: 20, Mar 20: 30, etc.)

number

CUMULATE('Quantity Sold', 'Month')

cumulates the metric Quantity Sold (each month is added to the sum of the previous months whatever the year).

number

CUMULATE('Quantity Sold', 'Month', 'Month'.'Year')

cumulates the metric Quantity Sold (each month is added to the sum of the previous months but restart at each change of year).

number

CUMULATE('Quantity Sold', 'Month', 'Month'.'Year', AVG)

averages the metric Quantity Sold (each month is added to the sum of the previous months but restart at each change of year).

number


Excel equivalent: None

See also: DECUMULATE


0 replies

Be the first to reply!

Reply