Skip to main content
Skip table of contents

ADDEACH

Category: Math & numeric

Overview

The ADDEACH function adds a numeric value (or the values of another node) to each individual entry of a node before any rollup or aggregation is applied.

Use this function when you need to apply an element-wise adjustment to every value of a node while preserving the node’s dimensionality.

Syntax

ADDEACH(Node, Amount)

Example usage

ADDEACH('Growth Rate', 1)

Parameters

Parameter

Description

Type

Required

Node

The input node, referenced by name in single quotes (e.g. 'Profit')

Node reference

Yes

Amount

A numeric value or another node to add to each entry

Number / Node ref

Yes

Output Shape

Aspect

Behavior

Dimensionality

Preserves the input shape

Row count

Same number of rows as the input node

Calculation

Each value of the node is increased by the specified amount

Watch Out

  • ADDEACH performs element-wise addition before rollups.

  • When using another node as the Amount, the operation matches values across shared dimensions only.


Examples

Convert a percentage to a factor

A growth rate of 5 % is stored as 0.05 in Valsight.
To use it as a multiplication factor (1.05), add 1.

Formula

ADDEACH('Growth Rate', 1)

Year

Growth Rate

→ ADDEACH Result

2024

0.03

1.03

2025

0.05

1.05

2026

0.02

1.02

Reverse a factor back to a percentage

Formula

ADDEACH('Factor', -1)

Year

Factor

→ ADDEACH Result

2024

1.03

0.03

2025

1.05

0.05

Compute the complement (1 − x pattern)

Because

1 - 'Node'

in Valsight is equivalent to

1 - ROLLUP('Node')

use ADDEACH instead for element-wise subtraction.

Formula

ADDEACH('Split' * -1, 1)

This first multiplies each entry by −1 and then adds 1, producing the complementary share.

Product

VarCostSplit

→ ADDEACH Result

A

0.70

0.30

B

0.60

0.40

Variable costs are 70 % / 60 % of total cost
The formula therefore yields the fixed-cost share (30 % / 40 %).

Flip 0/1 helper tables

To invert a binary helper table (1 → 0, 0 → 1), apply the same pattern.

Formula

ADDEACH('Original Values' * -1, 1)

Country

IS_EMEA

→ ADDEACH Result

DE

1

0

US

0

1

Useful when you need the logical opposite of an existing flag, e.g. turning an IS_EMEA flag into a NOT_EMEA flag.

Using a node as amount input

Instead of a fixed number, you can pass a second node.
ADDEACH then adds the values element-wise, matching on shared dimensions.
Rows that exist in only one of the two nodes are excluded from the result.

Node

Year

Measure

2025

10

2026

100

AmountNode

Year

Measure

2024

100

2025

150

2026

200

2027

250

Formula

ADDEACH('Node', 'AmountNode')

Year

→ ADDEACH Result

2025

160

2026

300

Year 2024 and 2027 are absent because they only exist in AmountNode.

The overlapping years are summed element-wise:

10 + 150 = 160

100 + 200 = 300.


Related Functions

Function

When to use instead

ADDITION (+)

Adds two nodes after rollup.

MULTIPLICATION (*) /
MULTIPLY

Element-wise multiplication counterpart.

ROLLUP

Aggregate values after element-wise operations.

EXPAND

Add dimensional detail before applying ADDEACH.

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.