Reference Updated March 27, 2026

REDISTRIBUTE

Category: Dimensionality & hierarchies

Overview

Description

Calculates a weighted redistribution of the RedistributionValue following the specified DistributionWeight. The redistribution stays within the boundaries of clusters, which can be specified by the provided ClusterLevels.

Each value is redistributed exclusively on the elements within the same cluster, though not including the distributed element itself.

For example, assume you have a dimension with the levels "Product Category" and "Product". The function allows you to distribute a value for a single product across all other products within the same "Product Category". The value will not be distributed onto any product in a different "Product Category", and it will not be distributed on the product itself.

Use when you want to redistribute values only within defined clusters instead of across the full available detail.

Syntax

`REDISTRIBUTE('RedistributionValue', 'DistributionWeight' [, "ClusterLevels"])`

Parameters

  • RedistributionValue: Input node with values that need to be redistributed, for example 'RedistributionValue'.

  • DistributionWeight: Input node whose value distribution is used to calculate the redistribution, for example 'DistributionWeight'.

  • ClusterLevels: Array of levels used to cluster the redistribution, for example "Category". If no cluster levels are inserted, all values in 'DistributionWeight' will be treated as belonging to a single cluster.

Limitations

  • An error will appear if 'RedistributionValue' and 'DistributionWeight' have different levels.

  • An error will appear if "ClusterLevels" contains levels that are not present in 'RedistributionValue' and therefore in 'DistributionWeight'.

  • An error will appear if "ClusterLevels" contains multiple levels from the same dimension.

  • The result unit will be the same as the 'RedistributionValue' input.


Examples

Redistribute Within a Category Cluster

This example shows redistribution within the same "Category" cluster. Values are only spread to other rows inside that cluster and never to the source row itself.

Input node: 'RedistributionValue'

CategoryTypeValue
LandCar-
LandTruck2
LandMotorbike-
SeaBoat-5

Input node: 'DistributionWeight'

CategoryTypeDistributionWeight
LandCar10
LandTruck20
LandMotorbike30
SeaBoat40

Formula: REDISTRIBUTE('RedistributionValue', 'DistributionWeight', "Category")

CategoryTypeDistribution WeightRedistribute TruckRedistribute Boat→ REDISTRIBUTE Result
LandCar102 * (10 / (10 + 30)) = 0.5-0.5
LandTruck20---
LandMotorbike302 * (30 / (10 + 30)) = 1.5-1.5
SeaBoat40---

Redistribution calculations only need to be performed for Truck and Boat because they are the only rows in 'RedistributionValue' that have non-zero values.

For the Truck redistribution, Boat is not included because it is within a different "Category" value. For the Boat redistribution, there are no calculations because it is the only row within its category cluster.

Without clustering, the same input redistributes across all available rows instead of staying within category boundaries.

Formula: REDISTRIBUTE('RedistributionValue', 'DistributionWeight')

CategoryTypeDistribution WeightRedistribute TruckRedistribute Boat→ REDISTRIBUTE Result
LandCar102 * (10 / (10 + 30 + 40)) = 0.25-5 * (10 / (10 + 20 + 30)) = -0.830.25 + (-0.83) = -0.58
LandTruck20--5 * (20 / (10 + 20 + 30)) = -1.67-1.67
LandMotorbike302 * (30 / (10 + 30 + 40)) = 0.75-5 * (30 / (10 + 20 + 30)) = -2.50.75 + (-2.5) = -1.75
SeaBoat402 * (40 / (10 + 30 + 40)) = 1-1

Note: Cases where there are multiple values for a single line, for example Car, can occur when clustering is in use and there are multiple changes to rows within the same cluster.

Redistribute with Additional Non-Cluster Levels

This example adds a "Colour" level that is not part of the clustering level. The influence of that extra level is removed automatically when building the weight distribution used for the redistribution.

Input node: 'RedistributionValue'

CategoryTypeColourValue
LandCarWhite-
LandCarBlack-
LandTruckWhite2
LandTruckBlack3
LandMotorbikeBlack-
LandMotorbikeWhite-
SeaBoatWhite-5

Input node: 'DistributionWeight'

CategoryTypeColourDistributionWeight
LandCarWhite10
LandCarBlack10
LandTruckWhite10
LandTruckBlack20
LandMotorbikeBlack10
LandMotorbikeWhite5
SeaBoatWhite40

Formula: REDISTRIBUTE('RedistributionValue', 'DistributionWeight', "Category")

Before calculating the redistribution, the function removes the influence of "Colour" from the weighting node and builds the following internal distribution table automatically:

CategoryTypeDistributionWeight
LandCar20
LandTruck30
LandMotorbike15
SeaBoat40

The resulting redistributed values are then calculated as follows.

CategoryTypeColourDistribution WeightRedistribute Truck WhiteRedistribute Truck BlackRedistribute Boat White→ REDISTRIBUTE Result
LandCarWhite102 * (20 / (20 + 15)) = 1.14--1.14
LandCarBlack10-3 * (20 / (20 + 15)) = 1.71-1.71
LandTruckWhite10----
LandTruckBlack20----
LandMotorbikeBlack10-3 * (15 / (20 + 15)) = 1.29-1.29
LandMotorbikeWhite52 * (15 / (20 + 15)) = 0.86--0.86
SeaBoatWhite40----

FunctionWhen to use instead
DISTRIBUTEWhen values should be distributed across the full available detail instead of staying within defined clusters.
REBOOKWhen values should be moved from one level value to another instead of being redistributed using weights.
Was this page helpful?