Skip to main content
Subtracts the subtrahend from the minuend and returns the difference as a float.

Validation

Both inputs must be numerical (integer or float). Subtrahend values are matched against minuend dated properties by valid_from and id. Any non-numerical input raises an error.

Nil handling

A nil value on either side is treated as zero.

List behaviour

When the value of a dated property on the minuend is a list, the matching subtrahend value must be either a single number or a list of the same length. Same-length lists are subtracted element-wise; a single number is subtracted from every element. Any other shape raises an error.

Ports